TestCaseResult
Represents the result of running a single test case.
using NUnit.Framework.Interfaces;
using System;
using System.Collections.Generic;
using System.Runtime.CompilerServices;
namespace NUnit.Framework.Internal
{
[System.Runtime.CompilerServices.NullableContext(1)]
[System.Runtime.CompilerServices.Nullable(0)]
public class TestCaseResult : TestResult
{
public override int FailCount => (base.ResultState.Status == TestStatus.Failed) ? 1 : 0;
public override int TotalCount => 1;
public override int WarningCount => (base.ResultState.Status == TestStatus.Warning) ? 1 : 0;
public override int PassCount => (base.ResultState.Status == TestStatus.Passed) ? 1 : 0;
public override int SkipCount => (base.ResultState.Status == TestStatus.Skipped) ? 1 : 0;
public override int InconclusiveCount => (base.ResultState.Status == TestStatus.Inconclusive) ? 1 : 0;
public override bool HasChildren => false;
public override IEnumerable<ITestResult> Children => Array.Empty<ITestResult>();
public TestCaseResult(TestMethod test)
: base(test)
{
}
}
}