Skip to content

Commit 55efe1c

Browse files
Test hanging issue (dotnet#4724)
* set max thread to unlimited, see if deadlock cause test host process hanging * skip TensorFlowImageClassification test as this test is hanging the test host process * make auto ml test inherient from base test class to identify which test hangs test host process * undo automl test change, enable diagnostic log * add new line at end * undo unnecessary change
1 parent 7fd93e6 commit 55efe1c

34 files changed

+183
-7
lines changed

test/Microsoft.Extensions.ML.Tests/Microsoft.Extensions.ML.Tests.csproj

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -19,6 +19,9 @@
1919
<None Update="testdata.txt">
2020
<CopyToOutputDirectory>Always</CopyToOutputDirectory>
2121
</None>
22+
<None Update="xunit.runner.json">
23+
<CopyToOutputDirectory>PreserveNewest</CopyToOutputDirectory>
24+
</None>
2225
</ItemGroup>
2326

2427
</Project>
Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,5 @@
1+
{
2+
"$schema": "https://xunit.net/schema/current/xunit.runner.schema.json",
3+
"longRunningTestSeconds": 120,
4+
"diagnosticMessages": true
5+
}

test/Microsoft.ML.AutoML.Tests/Microsoft.ML.AutoML.Tests.csproj

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -26,6 +26,9 @@
2626
<None Update="TestData\TrivialMulticlassDataset.txt">
2727
<CopyToOutputDirectory>PreserveNewest</CopyToOutputDirectory>
2828
</None>
29+
<None Update="xunit.runner.json">
30+
<CopyToOutputDirectory>PreserveNewest</CopyToOutputDirectory>
31+
</None>
2932
</ItemGroup>
3033

3134
<ItemGroup>
Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,5 @@
1+
{
2+
"$schema": "https://xunit.net/schema/current/xunit.runner.schema.json",
3+
"longRunningTestSeconds": 120,
4+
"diagnosticMessages": true
5+
}

test/Microsoft.ML.Benchmarks.Tests/Microsoft.ML.Benchmarks.Tests.csproj

Lines changed: 6 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -5,4 +5,10 @@
55

66
<NativeAssemblyReference Include="CpuMathNative" />
77
</ItemGroup>
8+
9+
<ItemGroup>
10+
<None Update="xunit.runner.json">
11+
<CopyToOutputDirectory>PreserveNewest</CopyToOutputDirectory>
12+
</None>
13+
</ItemGroup>
814
</Project>
Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,5 @@
1+
{
2+
"$schema": "https://xunit.net/schema/current/xunit.runner.schema.json",
3+
"longRunningTestSeconds": 120,
4+
"diagnosticMessages": true
5+
}

test/Microsoft.ML.CodeAnalyzer.Tests/Microsoft.ML.CodeAnalyzer.Tests.csproj

Lines changed: 6 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -40,4 +40,10 @@
4040
<ProjectReference Include="..\Microsoft.ML.TestFramework\Microsoft.ML.TestFramework.csproj" />
4141
</ItemGroup>
4242

43+
<ItemGroup>
44+
<None Update="xunit.runner.json">
45+
<CopyToOutputDirectory>PreserveNewest</CopyToOutputDirectory>
46+
</None>
47+
</ItemGroup>
48+
4349
</Project>
Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,5 @@
1+
{
2+
"$schema": "https://xunit.net/schema/current/xunit.runner.schema.json",
3+
"longRunningTestSeconds": 120,
4+
"diagnosticMessages": true
5+
}

test/Microsoft.ML.CodeGenerator.Tests/Microsoft.ML.CodeGenerator.Tests.csproj

Lines changed: 6 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -9,4 +9,10 @@
99
<ProjectReference Include="..\..\src\Microsoft.ML.AutoML\Microsoft.ML.AutoML.csproj" />
1010
</ItemGroup>
1111

12+
<ItemGroup>
13+
<None Update="xunit.runner.json">
14+
<CopyToOutputDirectory>PreserveNewest</CopyToOutputDirectory>
15+
</None>
16+
</ItemGroup>
17+
1218
</Project>
Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,5 @@
1+
{
2+
"$schema": "https://xunit.net/schema/current/xunit.runner.schema.json",
3+
"longRunningTestSeconds": 120,
4+
"diagnosticMessages": true
5+
}

test/Microsoft.ML.Core.Tests/Microsoft.ML.Core.Tests.csproj

Lines changed: 6 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -37,4 +37,10 @@
3737
<NativeAssemblyReference Condition="'$(OS)' == 'Windows_NT'" Include="libiomp5md" />
3838
</ItemGroup>
3939

40+
<ItemGroup>
41+
<None Update="xunit.runner.json">
42+
<CopyToOutputDirectory>PreserveNewest</CopyToOutputDirectory>
43+
</None>
44+
</ItemGroup>
45+
4046
</Project>
Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,5 @@
1+
{
2+
"$schema": "https://xunit.net/schema/current/xunit.runner.schema.json",
3+
"longRunningTestSeconds": 120,
4+
"diagnosticMessages": true
5+
}

test/Microsoft.ML.CpuMath.PerformanceTests/Microsoft.ML.CpuMath.PerformanceTests.csproj

Lines changed: 6 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -29,4 +29,10 @@
2929
<ItemGroup>
3030
<NativeAssemblyReference Include="CpuMathNative" />
3131
</ItemGroup>
32+
33+
<ItemGroup>
34+
<None Update="xunit.runner.json">
35+
<CopyToOutputDirectory>PreserveNewest</CopyToOutputDirectory>
36+
</None>
37+
</ItemGroup>
3238
</Project>
Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,5 @@
1+
{
2+
"$schema": "https://xunit.net/schema/current/xunit.runner.schema.json",
3+
"longRunningTestSeconds": 120,
4+
"diagnosticMessages": true
5+
}

test/Microsoft.ML.CpuMath.UnitTests/Microsoft.ML.CpuMath.UnitTests.csproj

Lines changed: 6 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -9,4 +9,10 @@
99
<NativeAssemblyReference Include="CpuMathNative" />
1010
</ItemGroup>
1111

12+
<ItemGroup>
13+
<None Update="xunit.runner.json">
14+
<CopyToOutputDirectory>PreserveNewest</CopyToOutputDirectory>
15+
</None>
16+
</ItemGroup>
17+
1218
</Project>
Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,5 @@
1+
{
2+
"$schema": "https://xunit.net/schema/current/xunit.runner.schema.json",
3+
"longRunningTestSeconds": 120,
4+
"diagnosticMessages": true
5+
}

test/Microsoft.ML.FSharp.Tests/Microsoft.ML.FSharp.Tests.fsproj

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -8,6 +8,9 @@
88
</PropertyGroup>
99

1010
<ItemGroup>
11+
<None Include="xunit.runner.json">
12+
<CopyToOutputDirectory>PreserveNewest</CopyToOutputDirectory>
13+
</None>
1114
<Compile Include="SmokeTests.fs" />
1215
</ItemGroup>
1316

Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,5 @@
1+
{
2+
"$schema": "https://xunit.net/schema/current/xunit.runner.schema.json",
3+
"longRunningTestSeconds": 120,
4+
"diagnosticMessages": true
5+
}

test/Microsoft.ML.Functional.Tests/Microsoft.ML.Functional.Tests.csproj

Lines changed: 6 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -41,4 +41,10 @@
4141
<ItemGroup>
4242
<PackageReference Include="Microsoft.ML.Onnx.TestModels" Version="$(MicrosoftMLOnnxTestModelsVersion)" />
4343
</ItemGroup>
44+
45+
<ItemGroup>
46+
<None Update="xunit.runner.json">
47+
<CopyToOutputDirectory>PreserveNewest</CopyToOutputDirectory>
48+
</None>
49+
</ItemGroup>
4450
</Project>
Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,5 @@
1+
{
2+
"$schema": "https://xunit.net/schema/current/xunit.runner.schema.json",
3+
"longRunningTestSeconds": 120,
4+
"diagnosticMessages": true
5+
}

test/Microsoft.ML.OnnxTransformerTest/Microsoft.ML.OnnxTransformerTest.csproj

Lines changed: 6 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -32,4 +32,10 @@
3232
<NativeAssemblyReference Condition="'$(OS)' == 'Windows_NT'" Include="libiomp5md" />
3333
</ItemGroup>
3434

35+
<ItemGroup>
36+
<None Update="xunit.runner.json">
37+
<CopyToOutputDirectory>PreserveNewest</CopyToOutputDirectory>
38+
</None>
39+
</ItemGroup>
40+
3541
</Project>
Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,5 @@
1+
{
2+
"$schema": "https://xunit.net/schema/current/xunit.runner.schema.json",
3+
"longRunningTestSeconds": 120,
4+
"diagnosticMessages": true
5+
}

test/Microsoft.ML.Predictor.Tests/Microsoft.ML.Predictor.Tests.csproj

Lines changed: 7 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -20,7 +20,13 @@
2020
<NativeAssemblyReference Include="CpuMathNative" />
2121
<NativeAssemblyReference Include="SymSgdNative" />
2222
<NativeAssemblyReference Include="MklImports" />
23-
<NativeAssemblyReference Condition="'$(OS)' == 'Windows_NT'" Include="libiomp5md"/>
23+
<NativeAssemblyReference Condition="'$(OS)' == 'Windows_NT'" Include="libiomp5md" />
24+
</ItemGroup>
25+
26+
<ItemGroup>
27+
<None Update="xunit.runner.json">
28+
<CopyToOutputDirectory>PreserveNewest</CopyToOutputDirectory>
29+
</None>
2430
</ItemGroup>
2531

2632
</Project>
Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,5 @@
1+
{
2+
"$schema": "https://xunit.net/schema/current/xunit.runner.schema.json",
3+
"longRunningTestSeconds": 120,
4+
"diagnosticMessages": true
5+
}

test/Microsoft.ML.Sweeper.Tests/Microsoft.ML.Sweeper.Tests.csproj

Lines changed: 6 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -10,6 +10,11 @@
1010
<NativeAssemblyReference Include="FastTreeNative" />
1111
<NativeAssemblyReference Include="CpuMathNative" />
1212
<NativeAssemblyReference Include="MklImports" />
13-
<NativeAssemblyReference Condition="'$(OS)' == 'Windows_NT'" Include="libiomp5md"/>
13+
<NativeAssemblyReference Condition="'$(OS)' == 'Windows_NT'" Include="libiomp5md" />
14+
</ItemGroup>
15+
<ItemGroup>
16+
<None Update="xunit.runner.json">
17+
<CopyToOutputDirectory>PreserveNewest</CopyToOutputDirectory>
18+
</None>
1419
</ItemGroup>
1520
</Project>
Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,5 @@
1+
{
2+
"$schema": "https://xunit.net/schema/current/xunit.runner.schema.json",
3+
"longRunningTestSeconds": 120,
4+
"diagnosticMessages": true
5+
}

test/Microsoft.ML.TestFramework/Microsoft.ML.TestFramework.csproj

Lines changed: 6 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -25,4 +25,10 @@
2525
<NativeAssemblyReference Include="MklImports" />
2626
<NativeAssemblyReference Condition="'$(OS)' == 'Windows_NT'" Include="libiomp5md" />
2727
</ItemGroup>
28+
29+
<ItemGroup>
30+
<None Update="xunit.runner.json">
31+
<CopyToOutputDirectory>PreserveNewest</CopyToOutputDirectory>
32+
</None>
33+
</ItemGroup>
2834
</Project>
Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,5 @@
1+
{
2+
"$schema": "https://xunit.net/schema/current/xunit.runner.schema.json",
3+
"longRunningTestSeconds": 120,
4+
"diagnosticMessages": true
5+
}

test/Microsoft.ML.TestFrameworkCommon/Microsoft.ML.TestFrameworkCommon.csproj

Lines changed: 6 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -2,4 +2,10 @@
22

33
<Import Project="..\TestFrameworkDependency.props" />
44

5+
<ItemGroup>
6+
<None Update="xunit.runner.json">
7+
<CopyToOutputDirectory>PreserveNewest</CopyToOutputDirectory>
8+
</None>
9+
</ItemGroup>
10+
511
</Project>
Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,5 @@
1+
{
2+
"$schema": "https://xunit.net/schema/current/xunit.runner.schema.json",
3+
"longRunningTestSeconds": 120,
4+
"diagnosticMessages": true
5+
}

test/Microsoft.ML.Tests/Microsoft.ML.Tests.csproj

Lines changed: 11 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -52,10 +52,16 @@
5252
</ItemGroup>
5353

5454
<ItemGroup>
55-
<EmbeddedResource Include="ExpressionLanguageTests\TestData\ExprBindExInput.txt"/>
56-
<EmbeddedResource Include="ExpressionLanguageTests\TestData\ExprBindInput.txt"/>
57-
<EmbeddedResource Include="ExpressionLanguageTests\TestData\ExprCodeGenInput.txt"/>
58-
<EmbeddedResource Include="ExpressionLanguageTests\TestData\ExprEvalInput.txt"/>
59-
<EmbeddedResource Include="ExpressionLanguageTests\TestData\ExprParseInput.txt"/>
55+
<EmbeddedResource Include="ExpressionLanguageTests\TestData\ExprBindExInput.txt" />
56+
<EmbeddedResource Include="ExpressionLanguageTests\TestData\ExprBindInput.txt" />
57+
<EmbeddedResource Include="ExpressionLanguageTests\TestData\ExprCodeGenInput.txt" />
58+
<EmbeddedResource Include="ExpressionLanguageTests\TestData\ExprEvalInput.txt" />
59+
<EmbeddedResource Include="ExpressionLanguageTests\TestData\ExprParseInput.txt" />
60+
</ItemGroup>
61+
62+
<ItemGroup>
63+
<None Update="xunit.runner.json">
64+
<CopyToOutputDirectory>PreserveNewest</CopyToOutputDirectory>
65+
</None>
6066
</ItemGroup>
6167
</Project>
Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,5 @@
1+
{
2+
"$schema": "https://xunit.net/schema/current/xunit.runner.schema.json",
3+
"longRunningTestSeconds": 120,
4+
"diagnosticMessages": true
5+
}

test/Microsoft.ML.TimeSeries.Tests/Microsoft.ML.TimeSeries.Tests.csproj

Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -14,4 +14,9 @@
1414
<NativeAssemblyReference Include="MklImports" />
1515
<NativeAssemblyReference Condition="'$(OS)' == 'Windows_NT'" Include="libiomp5md" />
1616
</ItemGroup>
17+
<ItemGroup>
18+
<None Update="xunit.runner.json">
19+
<CopyToOutputDirectory>PreserveNewest</CopyToOutputDirectory>
20+
</None>
21+
</ItemGroup>
1722
</Project>
Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,5 @@
1+
{
2+
"$schema": "https://xunit.net/schema/current/xunit.runner.schema.json",
3+
"longRunningTestSeconds": 120,
4+
"diagnosticMessages": true
5+
}

0 commit comments

Comments
 (0)