Просмотр исходного кода

Add support/config for NCrunch

Oren Novotny 8 лет назад
Родитель
Сommit
0f38563c16
20 измененных файлов с 119 добавлено и 46 удалено
  1. 1 0
      .gitignore
  2. 1 0
      Rx.NET/Source/Directory.build.props
  3. 6 0
      Rx.NET/Source/System.Reactive.v3.ncrunchsolution
  4. 6 0
      Rx.NET/Source/facades/System.Reactive.Core/System.Reactive.Core.v3.ncrunchproject
  5. 6 0
      Rx.NET/Source/facades/System.Reactive.Experimental/System.Reactive.Experimental.v3.ncrunchproject
  6. 6 0
      Rx.NET/Source/facades/System.Reactive.Interfaces/System.Reactive.Interfaces.v3.ncrunchproject
  7. 6 0
      Rx.NET/Source/facades/System.Reactive.Linq/System.Reactive.Linq.v3.ncrunchproject
  8. 6 0
      Rx.NET/Source/facades/System.Reactive.PlatformServices/System.Reactive.PlatformServices.v3.ncrunchproject
  9. 6 0
      Rx.NET/Source/facades/System.Reactive.Providers/System.Reactive.Providers.v3.ncrunchproject
  10. 6 0
      Rx.NET/Source/facades/System.Reactive.Runtime.Remoting/System.Reactive.Runtime.Remoting.v3.ncrunchproject
  11. 6 0
      Rx.NET/Source/facades/System.Reactive.Windows.Forms/System.Reactive.Windows.Forms.v3.ncrunchproject
  12. 6 0
      Rx.NET/Source/facades/System.Reactive.Windows.Threading/System.Reactive.Windows.Threading.v3.ncrunchproject
  13. 5 0
      Rx.NET/Source/facades/System.Reactive.WindowsRuntime/System.Reactive.WindowsRuntime.v3.ncrunchproject
  14. 9 0
      Rx.NET/Source/src/Microsoft.Reactive.Testing/Microsoft.Reactive.Testing.v3.ncrunchproject
  15. 10 0
      Rx.NET/Source/src/System.Reactive.Observable.Aliases/System.Reactive.Observable.Aliases.v3.ncrunchproject
  16. 2 1
      Rx.NET/Source/src/System.Reactive/System.Reactive.csproj
  17. 8 0
      Rx.NET/Source/src/System.Reactive/System.Reactive.v3.ncrunchproject
  18. 5 0
      Rx.NET/Source/tests/Tests.System.Reactive.Uwp.DeviceRunner/Tests.System.Reactive.Uwp.DeviceRunner.v3.ncrunchproject
  19. 17 0
      Rx.NET/Source/tests/Tests.System.Reactive/Tests.System.Reactive.v3.ncrunchproject
  20. 1 45
      Rx.NET/Source/tests/Tests.System.Reactive/Tests/DefaultConcurrencyAbstractionLayerTest.cs

+ 1 - 0
.gitignore

@@ -28,6 +28,7 @@ local.properties
 # PDT-specific
 .buildpath
 
+_NCrunch*
 
 #################
 ## Visual Studio

+ 1 - 0
Rx.NET/Source/Directory.build.props

@@ -19,6 +19,7 @@
     <WriteVersionInfoToBuildLog>false</WriteVersionInfoToBuildLog>
     <IncludeSymbols>false</IncludeSymbols>
     <IsTestProject>$(MSBuildProjectName.Contains('Test'))</IsTestProject>
+    <GetVersion Condition=" '$(NCrunch)' != '' ">false</GetVersion>
   </PropertyGroup>
   
   <ItemGroup>

+ 6 - 0
Rx.NET/Source/System.Reactive.v3.ncrunchsolution

@@ -0,0 +1,6 @@
+<SolutionConfiguration>
+  <Settings>
+    <AllowParallelTestExecution>True</AllowParallelTestExecution>
+    <SolutionConfigured>True</SolutionConfigured>
+  </Settings>
+</SolutionConfiguration>

+ 6 - 0
Rx.NET/Source/facades/System.Reactive.Core/System.Reactive.Core.v3.ncrunchproject

@@ -0,0 +1,6 @@
+<ProjectConfiguration>
+  <Settings>
+    <IgnoreThisComponentCompletely>True</IgnoreThisComponentCompletely>
+    <PreviouslyBuiltSuccessfully>True</PreviouslyBuiltSuccessfully>
+  </Settings>
+</ProjectConfiguration>

+ 6 - 0
Rx.NET/Source/facades/System.Reactive.Experimental/System.Reactive.Experimental.v3.ncrunchproject

@@ -0,0 +1,6 @@
+<ProjectConfiguration>
+  <Settings>
+    <IgnoreThisComponentCompletely>True</IgnoreThisComponentCompletely>
+    <PreviouslyBuiltSuccessfully>True</PreviouslyBuiltSuccessfully>
+  </Settings>
+</ProjectConfiguration>

+ 6 - 0
Rx.NET/Source/facades/System.Reactive.Interfaces/System.Reactive.Interfaces.v3.ncrunchproject

@@ -0,0 +1,6 @@
+<ProjectConfiguration>
+  <Settings>
+    <IgnoreThisComponentCompletely>True</IgnoreThisComponentCompletely>
+    <PreviouslyBuiltSuccessfully>True</PreviouslyBuiltSuccessfully>
+  </Settings>
+</ProjectConfiguration>

+ 6 - 0
Rx.NET/Source/facades/System.Reactive.Linq/System.Reactive.Linq.v3.ncrunchproject

@@ -0,0 +1,6 @@
+<ProjectConfiguration>
+  <Settings>
+    <IgnoreThisComponentCompletely>True</IgnoreThisComponentCompletely>
+    <PreviouslyBuiltSuccessfully>True</PreviouslyBuiltSuccessfully>
+  </Settings>
+</ProjectConfiguration>

+ 6 - 0
Rx.NET/Source/facades/System.Reactive.PlatformServices/System.Reactive.PlatformServices.v3.ncrunchproject

@@ -0,0 +1,6 @@
+<ProjectConfiguration>
+  <Settings>
+    <IgnoreThisComponentCompletely>True</IgnoreThisComponentCompletely>
+    <PreviouslyBuiltSuccessfully>True</PreviouslyBuiltSuccessfully>
+  </Settings>
+</ProjectConfiguration>

+ 6 - 0
Rx.NET/Source/facades/System.Reactive.Providers/System.Reactive.Providers.v3.ncrunchproject

@@ -0,0 +1,6 @@
+<ProjectConfiguration>
+  <Settings>
+    <IgnoreThisComponentCompletely>True</IgnoreThisComponentCompletely>
+    <PreviouslyBuiltSuccessfully>True</PreviouslyBuiltSuccessfully>
+  </Settings>
+</ProjectConfiguration>

+ 6 - 0
Rx.NET/Source/facades/System.Reactive.Runtime.Remoting/System.Reactive.Runtime.Remoting.v3.ncrunchproject

@@ -0,0 +1,6 @@
+<ProjectConfiguration>
+  <Settings>
+    <IgnoreThisComponentCompletely>True</IgnoreThisComponentCompletely>
+    <PreviouslyBuiltSuccessfully>True</PreviouslyBuiltSuccessfully>
+  </Settings>
+</ProjectConfiguration>

+ 6 - 0
Rx.NET/Source/facades/System.Reactive.Windows.Forms/System.Reactive.Windows.Forms.v3.ncrunchproject

@@ -0,0 +1,6 @@
+<ProjectConfiguration>
+  <Settings>
+    <IgnoreThisComponentCompletely>True</IgnoreThisComponentCompletely>
+    <PreviouslyBuiltSuccessfully>True</PreviouslyBuiltSuccessfully>
+  </Settings>
+</ProjectConfiguration>

+ 6 - 0
Rx.NET/Source/facades/System.Reactive.Windows.Threading/System.Reactive.Windows.Threading.v3.ncrunchproject

@@ -0,0 +1,6 @@
+<ProjectConfiguration>
+  <Settings>
+    <IgnoreThisComponentCompletely>True</IgnoreThisComponentCompletely>
+    <PreviouslyBuiltSuccessfully>True</PreviouslyBuiltSuccessfully>
+  </Settings>
+</ProjectConfiguration>

+ 5 - 0
Rx.NET/Source/facades/System.Reactive.WindowsRuntime/System.Reactive.WindowsRuntime.v3.ncrunchproject

@@ -0,0 +1,5 @@
+<ProjectConfiguration>
+  <Settings>
+    <IgnoreThisComponentCompletely>True</IgnoreThisComponentCompletely>
+  </Settings>
+</ProjectConfiguration>

+ 9 - 0
Rx.NET/Source/src/Microsoft.Reactive.Testing/Microsoft.Reactive.Testing.v3.ncrunchproject

@@ -0,0 +1,9 @@
+<ProjectConfiguration>
+  <Settings>
+    <CopyReferencedAssembliesToWorkspace>True</CopyReferencedAssembliesToWorkspace>
+    <HiddenComponentWarnings>
+      <Value>CopyReferencedAssembliesToWorkspaceIsOn</Value>
+    </HiddenComponentWarnings>
+    <PreviouslyBuiltSuccessfully>True</PreviouslyBuiltSuccessfully>
+  </Settings>
+</ProjectConfiguration>

+ 10 - 0
Rx.NET/Source/src/System.Reactive.Observable.Aliases/System.Reactive.Observable.Aliases.v3.ncrunchproject

@@ -0,0 +1,10 @@
+<ProjectConfiguration>
+  <Settings>
+    <CopyReferencedAssembliesToWorkspace>True</CopyReferencedAssembliesToWorkspace>
+    <HiddenComponentWarnings>
+      <Value>AllowPartiallyTrustedCallers</Value>
+      <Value>CopyReferencedAssembliesToWorkspaceIsOn</Value>
+    </HiddenComponentWarnings>
+    <PreviouslyBuiltSuccessfully>True</PreviouslyBuiltSuccessfully>
+  </Settings>
+</ProjectConfiguration>

+ 2 - 1
Rx.NET/Source/src/System.Reactive/System.Reactive.csproj

@@ -1,6 +1,7 @@
 <Project Sdk="Microsoft.NET.Sdk">
   <PropertyGroup>
-    <TargetFrameworks>netstandard1.3;net45;net46;uap10.0</TargetFrameworks>
+    <TargetFrameworks Condition="'$(NCrunch)' == '1'">netstandard1.3;net45;net46</TargetFrameworks>
+    <TargetFrameworks Condition="'$(NCrunch)' != '1'">netstandard1.3;net45;net46;uap10.0</TargetFrameworks>
     <CopyLocalLockFileAssemblies>false</CopyLocalLockFileAssemblies>       
     <PackageTags>Rx;Reactive;Extensions;Observable;LINQ;Events</PackageTags>
     <Description>Reactive Extensions (Rx) for .NET</Description>

+ 8 - 0
Rx.NET/Source/src/System.Reactive/System.Reactive.v3.ncrunchproject

@@ -0,0 +1,8 @@
+<ProjectConfiguration>
+  <Settings>
+    <HiddenComponentWarnings>
+      <Value>AllowPartiallyTrustedCallers</Value>
+    </HiddenComponentWarnings>
+    <PreviouslyBuiltSuccessfully>True</PreviouslyBuiltSuccessfully>
+  </Settings>
+</ProjectConfiguration>

+ 5 - 0
Rx.NET/Source/tests/Tests.System.Reactive.Uwp.DeviceRunner/Tests.System.Reactive.Uwp.DeviceRunner.v3.ncrunchproject

@@ -0,0 +1,5 @@
+<ProjectConfiguration>
+  <Settings>
+    <IgnoreThisComponentCompletely>True</IgnoreThisComponentCompletely>
+  </Settings>
+</ProjectConfiguration>

+ 17 - 0
Rx.NET/Source/tests/Tests.System.Reactive/Tests.System.Reactive.v3.ncrunchproject

@@ -0,0 +1,17 @@
+<ProjectConfiguration>
+  <Settings>
+    <AdditionalFilesToIncludeForProject />
+    <CopyReferencedAssembliesToWorkspace>True</CopyReferencedAssembliesToWorkspace>
+    <HiddenComponentWarnings>
+      <Value>CopyReferencedAssembliesToWorkspaceIsOn</Value>
+    </HiddenComponentWarnings>
+    <IgnoredTests>
+      <NamedTestSelector>
+        <TestName>ReactiveTests.Tests.VirtualSchedulerTest.Virtual_ThreadSafety</TestName>
+      </NamedTestSelector>
+    </IgnoredTests>
+    <ImplicitProjectDependencyPathsRelativeToSolutionDirectory />
+    <PreloadReferencedAssemblies>False</PreloadReferencedAssemblies>
+    <PreviouslyBuiltSuccessfully>True</PreviouslyBuiltSuccessfully>
+  </Settings>
+</ProjectConfiguration>

+ 1 - 45
Rx.NET/Source/tests/Tests.System.Reactive/Tests/DefaultConcurrencyAbstractionLayerTest.cs

@@ -23,51 +23,7 @@ namespace ReactiveTests.Tests
         {
             if (_domain == null)
             {
-                var cur = AppDomain.CurrentDomain.BaseDirectory;
-                var sub = Path.Combine(cur, "NoCAL");
-
-                if (!Directory.Exists(sub))
-                {
-                    Directory.CreateDirectory(sub);
-                }
-
-                //
-                // We want to replace the files to make the debugging experience
-                // better. If the directory already exists, a recompilation does
-                // not get rid of it. At some point, we should revisit this whole
-                // directory creation during the test run and try to do away with
-                // it by making it part of the build process.
-                //
-
-                foreach (var file in Directory.GetFiles(cur))
-                {
-                    var fn = Path.GetFileName(file);
-                    if (!file.Contains("PlatformServices"))
-                    {
-                        var dest = Path.Combine(sub, fn);
-
-                        if (File.Exists(dest))
-                        {
-                            try
-                            {
-                                File.Delete(dest);
-                            }
-                            catch (UnauthorizedAccessException)
-                            {
-                                //
-                                // File in use; expected after first pass.
-                                //
-                            }
-                        }
-
-                        if (!File.Exists(dest))
-                        {
-                            File.Copy(Path.Combine(cur, fn), Path.Combine(sub, fn));
-                        }
-                    }
-                }
-
-                _domain = AppDomain.CreateDomain("Default_CAL", null, new AppDomainSetup { ApplicationBase = sub });
+                _domain = AppDomain.CreateDomain("Default_CAL", null, new AppDomainSetup { ApplicationBase = AppDomain.CurrentDomain.BaseDirectory });
             }
         }