< Summary

Class:DCL.Components.WaitForComponentUpdate
Assembly:MainScripts
File(s):/tmp/workspace/unity-renderer/unity-renderer/Assets/Scripts/MainScripts/DCL/WorldRuntime/WaitForComponentUpdate/WaitForComponentUpdate.cs
Covered lines:0
Uncovered lines:3
Coverable lines:3
Total lines:17
Line coverage:0% (0 of 3)
Covered branches:0
Total branches:0

Metrics

MethodBranch coverage Crap Score Cyclomatic complexity NPath complexity Sequence coverage
WaitForComponentUpdate(...)0%2100%
Cleanup()0%2100%

File(s)

/tmp/workspace/unity-renderer/unity-renderer/Assets/Scripts/MainScripts/DCL/WorldRuntime/WaitForComponentUpdate/WaitForComponentUpdate.cs

#LineLine coverage
 1namespace DCL.Components
 2{
 3    /// <summary>
 4    /// Unity is unable to yield a coroutine while is already being yielded by another one.
 5    /// To fix that we wrap the routine in a CustomYieldInstruction.
 6    /// </summary>
 7    public class WaitForComponentUpdate : CleanableYieldInstruction
 8    {
 9        public IDelayedComponent component;
 10
 011        public WaitForComponentUpdate(IDelayedComponent component) { this.component = component; }
 12
 013        public override bool keepWaiting { get { return component.isRoutineRunning; } }
 14
 015        public override void Cleanup() { component.Cleanup(); }
 16    }
 17}