< Summary

Class:PhoneRingScreen
Assembly:Test
File(s):E:/Unity/Unity Project/VR-Room/Assets/_Course Library/Scripts/Test/PhoneRingScreen.cs
Covered lines:13
Uncovered lines:0
Coverable lines:13
Total lines:28
Line coverage:100% (13 of 13)
Covered branches:0
Total branches:0
Covered methods:2
Total methods:2
Method coverage:100% (2 of 2)

Coverage History

Metrics

MethodBranch coverage Crap Score Cyclomatic complexity NPath complexity Sequence coverage
Start()0%000100%
Update()0%000100%

File(s)

E:/Unity/Unity Project/VR-Room/Assets/_Course Library/Scripts/Test/PhoneRingScreen.cs

#LineLine coverage
 1using System.Collections;
 2using System.Collections.Generic;
 3using UnityEngine;
 4
 5public class PhoneRingScreen : MonoBehaviour
 6{
 7    private AudioSource audioSource;
 8    private Material original_material;
 9    // private Renderer renderer;
 10    public Material calling_material;
 11    void Start()
 412    {
 413        audioSource = GetComponent<AudioSource>();
 414        original_material = GetComponent<Renderer>().material;
 415    }
 16
 17    void Update()
 1115818    {
 1115819        if(audioSource.isPlaying)
 163820        {
 163821            GetComponent<Renderer>().material = calling_material;
 163822        }
 23        else
 952024        {
 952025            GetComponent<Renderer>().material = original_material;
 952026        }
 1115827    }
 28}

Methods/Properties

Start()
Update()