Skip to content

Commit 59e9ce1

Browse files
committed
[temp]
1 parent 509dfab commit 59e9ce1

File tree

1 file changed

+15
-4
lines changed

1 file changed

+15
-4
lines changed

tools/ExampleTester/ExampleTests.cs

Lines changed: 15 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,6 @@
11
using NUnit.Framework;
2+
using NUnit.Framework.Interfaces;
3+
using NUnit.Framework.Internal;
24
using Utilities;
35

46
[assembly: Parallelizable(ParallelScope.Children)]
@@ -7,12 +9,18 @@ namespace ExampleTester;
79

810
public static class ExampleTests
911
{
10-
private static TesterConfiguration TesterConfiguration { get; } = new(FindTmpDirectory());
11-
12+
//private static TesterConfiguration TesterConfiguration { get; } = new(FindTmpDirectory());
13+
/*
1214
public static IEnumerable<object[]> LoadExamples() =>
1315
from example in GeneratedExample.LoadAllExamples(TesterConfiguration.ExtractedOutputDirectory)
1416
select new object[] { example };
15-
17+
*/
18+
[Test]
19+
public static void Temp()
20+
{
21+
TestContext.WriteLine("Found: " + FindTmpDirectory());
22+
}
23+
/*
1624
[TestCaseSource(nameof(LoadExamples))]
1725
public static async Task ExamplePasses(GeneratedExample example)
1826
{
@@ -21,11 +29,14 @@ public static async Task ExamplePasses(GeneratedExample example)
2129
if (!await example.Test(TesterConfiguration, logger))
2230
Assert.Fail("There were one or more failures. See the logged output for details.");
2331
}
24-
32+
*/
2533
private static string FindTmpDirectory()
2634
{
2735
for (string? current = AppDomain.CurrentDomain.BaseDirectory; current != null; current = Path.GetDirectoryName(current))
2836
{
37+
TestExecutionContext.CurrentContext.CurrentResult.RecordAssertion(AssertionStatus.Inconclusive,
38+
$"Trying directory '{current}' containing {string.Join(", ", Directory.GetFileSystemEntries(current).Select(Path.GetFileName))}");
39+
2940
string testPath = Path.Join(current, "tmp");
3041
if (Directory.Exists(testPath))
3142
return testPath;

0 commit comments

Comments
 (0)