public void GetFailingLayerNames_WhenNoResultsAvailable_ReturnsEmptyArray() { var sut = new NimatorResult(DateTime.Now); var result = sut.GetFailingLayerNames(); CollectionAssert.IsEmpty(result); }
public void GetFailingLayerNames_WhenErrorsAvailable_ReturnsLayerNames() { var sut = new NimatorResult(DateTime.Now); sut.LayerResults.Add(TestLayerResult("err", NotificationLevel.Error)); sut.LayerResults.Add(TestLayerResult("crit", NotificationLevel.Critical)); sut.LayerResults.Add(TestLayerResult("warn", NotificationLevel.Warning)); sut.LayerResults.Add(TestLayerResult("ok", NotificationLevel.Okay)); var result = sut.GetFailingLayerNames(); CollectionAssert.AreEquivalent(new[] { "err", "crit" }, result); }