< Summary

Class:AudioEvent_WithBlockingEvent
Assembly:Audio
File(s):/tmp/workspace/unity-renderer/unity-renderer/Assets/Scripts/MainScripts/DCL/Controllers/Audio/AudioEvent_WithBlockingEvent.cs
Covered lines:3
Uncovered lines:4
Coverable lines:7
Total lines:19
Line coverage:42.8% (3 of 7)
Covered branches:0
Total branches:0

Metrics

MethodBranch coverage Crap Score Cyclomatic complexity NPath complexity Sequence coverage
Play(...)0%6.984042.86%

File(s)

/tmp/workspace/unity-renderer/unity-renderer/Assets/Scripts/MainScripts/DCL/Controllers/Audio/AudioEvent_WithBlockingEvent.cs

#LineLine coverage
 1using UnityEngine;
 2
 3[CreateAssetMenu(fileName = "AudioEventWithBlockingEvent", menuName = "AudioEvents/AudioEvent - With blocking event")]
 4public class AudioEvent_WithBlockingEvent : AudioEvent
 5{
 6    [SerializeField]
 7    AudioEvent blockingEvent;
 8
 9    public override void Play(bool oneShot = false)
 10    {
 19011        if (blockingEvent == null)
 012            return;
 19013        if (blockingEvent.source == null)
 19014            return;
 15
 016        if (!blockingEvent.source.isPlaying)
 017            base.Play(oneShot);
 018    }
 19}

Methods/Properties

Play(System.Boolean)