Browse Source

Revert Task, use Thread as before; set test to release

Oren Novotny 9 năm trước cách đây
mục cha
commit
586f655e0e

+ 2 - 3
Rx.NET/Source/Tests.System.Reactive/TestLongRunningScheduler.cs

@@ -4,7 +4,6 @@ using System;
 using System.Reactive.Concurrency;
 using System.Reactive.Disposables;
 using System.Threading;
-using System.Threading.Tasks;
 
 namespace ReactiveTests
 {
@@ -56,7 +55,7 @@ namespace ReactiveTests
             var ee = new ManualResetEvent(false);
             _setEnd(ee);
 
-            Task.Run(() =>
+            new Thread(() =>
             {
                 eb.Set();
                 try
@@ -74,7 +73,7 @@ namespace ReactiveTests
                 {
                     ee.Set();
                 }
-            });
+            }).Start();
 
             return d;
         }

+ 3 - 2
Rx.NET/Source/Tests.System.Reactive/xunit.runner.json

@@ -1,4 +1,5 @@
 {
-    "diagnosticMessages": true,
-    "methodDisplay": "classAndMethod"
+  "diagnosticMessages": true,
+  "methodDisplay": "classAndMethod",
+  "maxParallelThreads": 2
 }

+ 1 - 2
Rx.NET/Source/build-new.ps1

@@ -29,7 +29,6 @@ $projects = gci $scriptPath -Directory `
 
 foreach ($project in $projects) {
   dotnet build -c "$configuration" $project
-  dotnet build $project
 }
 
 $nuspecDir = Join-Path $scriptPath "NuSpecs"
@@ -45,5 +44,5 @@ foreach ($nuspec in $nuspecs) {
 
 Write-Host "Running tests" -Foreground Green
 $testDirectory = Join-Path $scriptPath "Tests.System.Reactive"
-dotnet test $testDirectory 
+dotnet test $testDirectory -c "$configuration"