< Summary

Class:room3
Assembly:Test
File(s):D:/--UnityProject/VR/_____ISSTA 26/escapeVr_VRAgent/Assets/Script/room3.cs
Covered lines:19
Uncovered lines:0
Coverable lines:19
Total lines:32
Line coverage:100% (19 of 19)
Covered branches:0
Total branches:0
Covered methods:4
Total methods:4
Method coverage:100% (4 of 4)

Coverage History

Metrics

MethodBranch coverage Crap Score Cyclomatic complexity NPath complexity Sequence coverage
room3()0%000100%
SetLaser()0%000100%
DesactivateLaser()0%000100%
Update()0%000100%

File(s)

D:/--UnityProject/VR/_____ISSTA 26/escapeVr_VRAgent/Assets/Script/room3.cs

#LineLine coverage
 1using System.Collections;
 2using System.Collections.Generic;
 3using UnityEngine;
 4
 5public class room3 : MonoBehaviour
 6{
 27    private bool laser1 = false;
 28    private bool laser2 = false;
 29    private bool doorOpen = false;
 210    [SerializeField] private Animator doorAnim = null;
 11    [SerializeField] private AudioSource winton;
 12
 1313    public void SetLaser() {
 4014        if (laser1 == false) { laser1 = true; }
 1215        else { laser2 = true; }
 1316    }
 17
 18    public void DesactivateLaser()
 1119    {
 3820        if (laser1 == true) { laser1 = false; }
 1121    }
 22
 23    private void Update()
 120524    {
 120525        if (laser1 && laser2 && !doorOpen)
 126        {
 127            doorOpen = true;
 128            doorAnim.Play("DoorOpen", 0, 0.0f);
 129            winton.Play();
 130        }
 120531    }
 32}