浏览代码

Fixing some tests wreaked by newline issues. Commenting out renderdoc code to get semantic segmentation tests to compile in players.

/aisv647_visualizations
Jon Hogins 4 年前
当前提交
8aa3e48e
共有 2 个文件被更改,包括 4 次插入4 次删除
  1. 4
      com.unity.perception/Tests/Runtime/GroundTruthTests/DatasetCaptureTests.cs
  2. 4
      com.unity.perception/Tests/Runtime/GroundTruthTests/SegmentationGroundTruthTests.cs

4
com.unity.perception/Tests/Runtime/GroundTruthTests/DatasetCaptureTests.cs


AssertJsonFileEquals(annotationDefinitionsJsonExpected, annotationDefinitionsPath);
FileAssert.Exists(capturesPath);
StringAssert.Contains(annotationsJsonExpected, EscapeGuids(File.ReadAllText(capturesPath)));
StringAssert.Contains(TestHelper.NormalizeJson(annotationsJsonExpected), EscapeGuids(File.ReadAllText(capturesPath)));
}
[Test]

var capturesPath = Path.Combine(DatasetCapture.OutputDirectory, "captures_000.json");
FileAssert.Exists(capturesPath);
StringAssert.Contains(expectedAnnotation, EscapeGuids(File.ReadAllText(capturesPath)));
StringAssert.Contains(TestHelper.NormalizeJson(expectedAnnotation), EscapeGuids(File.ReadAllText(capturesPath)));
}
[Test]

4
com.unity.perception/Tests/Runtime/GroundTruthTests/SegmentationGroundTruthTests.cs


var cameraObject = SetupCameraSemanticSegmentation(a => OnSegmentationImageReceived(a.data), showVisualizations);
TestHelper.LoadAndStartRenderDocCapture(out var gameView);
//TestHelper.LoadAndStartRenderDocCapture(out var gameView);
yield return null;
var segLabeler = (SemanticSegmentationLabeler)cameraObject.GetComponent<PerceptionCamera>().labelers[0];
var request = AsyncGPUReadback.Request(segLabeler.targetTexture, callback: r =>

AsyncGPUReadback.WaitAllRequests();
RenderDoc.EndCaptureRenderDoc(gameView);
//RenderDoc.EndCaptureRenderDoc(gameView);
//request.WaitForCompletion();
Assert.IsTrue(request.done);

正在加载...
取消
保存