diff --git a/Rx.NET/Source/Directory.build.props b/Rx.NET/Source/Directory.build.props index aa122b674e..4ca5fa42a0 100644 --- a/Rx.NET/Source/Directory.build.props +++ b/Rx.NET/Source/Directory.build.props @@ -23,23 +23,5 @@ true latest - - - - - - - - - - - - - - <_Parameter1>CommitHash - <_Parameter2>$(SourceRevisionId) - - - diff --git a/Rx.NET/Source/Directory.build.targets b/Rx.NET/Source/Directory.build.targets index 5a547415a5..8e2d441623 100644 --- a/Rx.NET/Source/Directory.build.targets +++ b/Rx.NET/Source/Directory.build.targets @@ -1,7 +1,7 @@ - $(DefineConstants);HAS_TRACE;HAS_WINRT;PREFER_ASYNC;HAS_TPL46;DESKTOPCLR + $(DefineConstants);HAS_TRACE;HAS_WINRT;HAS_WINFORMS;HAS_DISPATCHER;PREFER_ASYNC;HAS_TPL46;DESKTOPCLR 10.0.16299.0 @@ -11,7 +11,30 @@ $(DefineConstants);HAS_TRACE;HAS_WINRT;PREFER_ASYNC;HAS_TPL46;NO_REMOTING;WINDOWS - + $(DefineConstants);HAS_TRACE;HAS_WINRT;PREFER_ASYNC;HAS_TPL46;NO_REMOTING + + $(DefineConstants);HAS_TRACE;HAS_WINRT;HAS_WINFORMS;HAS_DISPATCHER;PREFER_ASYNC;HAS_TPL46;NO_REMOTING;DESKTOPCLR + + + + + + + + + + + + + + + + <_Parameter1>CommitHash + <_Parameter2>$(SourceRevisionId) + + + + \ No newline at end of file diff --git a/Rx.NET/Source/System.Reactive.sln b/Rx.NET/Source/System.Reactive.sln index 8fa372b2b8..2632264b16 100644 --- a/Rx.NET/Source/System.Reactive.sln +++ b/Rx.NET/Source/System.Reactive.sln @@ -1,7 +1,7 @@  Microsoft Visual Studio Solution File, Format Version 12.00 -# Visual Studio 15 -VisualStudioVersion = 15.0.26606.0 +# Visual Studio Version 16 +VisualStudioVersion = 16.0.28407.52 MinimumVisualStudioVersion = 10.0.40219.1 Project("{9A19103F-16F7-4668-BE54-9A1E7A4F7556}") = "System.Reactive", "src\System.Reactive\System.Reactive.csproj", "{01706A0F-8A63-4FD6-AF45-0BC0BED3C0D9}" EndProject @@ -15,9 +15,7 @@ Project("{FAE04EC0-301F-11D3-BF4B-00C04F79EFBC}") = "Tests.System.Reactive.Uwp.D EndProject Project("{2150E333-8FDC-42A3-9474-1A3956D46DE8}") = "Solution Items", "Solution Items", "{870348D0-C0A0-4352-8A02-E00AB0CCB919}" ProjectSection(SolutionItems) = preProject - ..\..\.vsts.rx-ci.yml = ..\..\.vsts.rx-ci.yml - ..\..\.vsts.rx-pr.yml = ..\..\.vsts.rx-pr.yml - ..\..\.vsts.rx-shared.yml = ..\..\.vsts.rx-shared.yml + ..\..\azure-pipelines.rx.yml = ..\..\azure-pipelines.rx.yml Directory.build.props = Directory.build.props Directory.build.targets = Directory.build.targets global.json = global.json diff --git a/Rx.NET/Source/global.json b/Rx.NET/Source/global.json index f438600dad..0af6548b41 100644 --- a/Rx.NET/Source/global.json +++ b/Rx.NET/Source/global.json @@ -1,5 +1,8 @@ { + "sdk": { + "version": "3.0.100-preview" + }, "msbuild-sdks": { - "MSBuild.Sdk.Extras": "1.6.65" + "MSBuild.Sdk.Extras": "2.0.0-preview.14" } } \ No newline at end of file diff --git a/Rx.NET/Source/src/Microsoft.Reactive.Testing/Microsoft.Reactive.Testing.csproj b/Rx.NET/Source/src/Microsoft.Reactive.Testing/Microsoft.Reactive.Testing.csproj index e40fe6fdda..1b7d7215eb 100644 --- a/Rx.NET/Source/src/Microsoft.Reactive.Testing/Microsoft.Reactive.Testing.csproj +++ b/Rx.NET/Source/src/Microsoft.Reactive.Testing/Microsoft.Reactive.Testing.csproj @@ -1,6 +1,6 @@  - net46;uap10.0;netstandard2.0 + netcoreapp3.0;net46;uap10.0;netstandard2.0 false Reactive Extensions Testing Library containing interfaces and classes providing functionality to test applications and libraries built using Reactive Extensions. Microsoft.Reactive.Testing - Testing Helper Library diff --git a/Rx.NET/Source/src/System.Reactive/System.Reactive.csproj b/Rx.NET/Source/src/System.Reactive/System.Reactive.csproj index 6f5b4ba1fe..191dc7d8e1 100644 --- a/Rx.NET/Source/src/System.Reactive/System.Reactive.csproj +++ b/Rx.NET/Source/src/System.Reactive/System.Reactive.csproj @@ -1,11 +1,16 @@  - netstandard2.0;net46;uap10.0;uap10.0.16299 + netcoreapp3.0;netstandard2.0;net46;uap10.0;uap10.0.16299 false Rx;Reactive;Extensions;Observable;LINQ;Events Reactive Extensions (Rx) for .NET + + true + true + + @@ -34,7 +39,7 @@ - + @@ -45,6 +50,9 @@ + + + diff --git a/Rx.NET/Source/tests/Tests.System.Reactive/DispatcherHelpers.cs b/Rx.NET/Source/tests/Tests.System.Reactive/DispatcherHelpers.cs index 1dad8a61e4..599b6854c3 100644 --- a/Rx.NET/Source/tests/Tests.System.Reactive/DispatcherHelpers.cs +++ b/Rx.NET/Source/tests/Tests.System.Reactive/DispatcherHelpers.cs @@ -2,10 +2,11 @@ // The .NET Foundation licenses this file to you under the Apache 2.0 License. // See the LICENSE file in the project root for more information. -#if NETCOREAPP1_1 || NET46 || NETCOREAPP1_0 +#if NETCOREAPP2_1 || NET46 || NETCOREAPP3_0 using System.Threading; #endif #if HAS_DISPATCHER +using System; using System.Windows.Threading; #endif diff --git a/Rx.NET/Source/tests/Tests.System.Reactive/Tests.System.Reactive.csproj b/Rx.NET/Source/tests/Tests.System.Reactive/Tests.System.Reactive.csproj index 0803528374..359471268c 100644 --- a/Rx.NET/Source/tests/Tests.System.Reactive/Tests.System.Reactive.csproj +++ b/Rx.NET/Source/tests/Tests.System.Reactive/Tests.System.Reactive.csproj @@ -1,23 +1,25 @@ - + - net46;netcoreapp2.0 + netcoreapp3.0;net46;netcoreapp2.1 $(NoWarn);CS0618 - + + + true + true + + + PreserveNewest - - - - - + - - - + + + diff --git a/Rx.NET/Source/tests/Tests.System.Reactive/Tests/Concurrency/SchedulerTest.cs b/Rx.NET/Source/tests/Tests.System.Reactive/Tests/Concurrency/SchedulerTest.cs index edd6e1d3da..48d224c937 100644 --- a/Rx.NET/Source/tests/Tests.System.Reactive/Tests/Concurrency/SchedulerTest.cs +++ b/Rx.NET/Source/tests/Tests.System.Reactive/Tests/Concurrency/SchedulerTest.cs @@ -375,7 +375,7 @@ public void Scheduler_Periodic2() } #endif -#if DESKTOPCLR +#if DESKTOPCLR && NET46 [Fact] public void Scheduler_Periodic_HostLifecycleManagement() { diff --git a/Rx.NET/Source/tests/Tests.System.Reactive/Tests/Linq/Observable/FromEventPatternTest.cs b/Rx.NET/Source/tests/Tests.System.Reactive/Tests/Linq/Observable/FromEventPatternTest.cs index 7db6080eed..253cd44253 100644 --- a/Rx.NET/Source/tests/Tests.System.Reactive/Tests/Linq/Observable/FromEventPatternTest.cs +++ b/Rx.NET/Source/tests/Tests.System.Reactive/Tests/Linq/Observable/FromEventPatternTest.cs @@ -474,7 +474,7 @@ public void FromEventPattern_Reflection_Instance_E3() ); } -#if DESKTOPCLR +#if DESKTOPCLR && NET46 [Fact] public void FromEventPattern_Reflection_Instance_MissingAccessors() { diff --git a/Rx.NET/Source/tests/Tests.System.Reactive/Tests/Linq/Observable/ObserveOnTest.cs b/Rx.NET/Source/tests/Tests.System.Reactive/Tests/Linq/Observable/ObserveOnTest.cs index 8f2a8117b3..2ed2d3ce4a 100644 --- a/Rx.NET/Source/tests/Tests.System.Reactive/Tests/Linq/Observable/ObserveOnTest.cs +++ b/Rx.NET/Source/tests/Tests.System.Reactive/Tests/Linq/Observable/ObserveOnTest.cs @@ -14,6 +14,15 @@ using ReactiveTests.Dummies; using Xunit; +#if HAS_DISPATCHER +using System.Windows.Threading; +#endif + +#if HAS_WINFORMS +using System.Windows.Forms; +#endif + + namespace ReactiveTests.Tests { public class ObserveOnTest : TestBase diff --git a/Rx.NET/Source/tests/Tests.System.Reactive/Tests/Linq/Observable/SubscribeOnTest.cs b/Rx.NET/Source/tests/Tests.System.Reactive/Tests/Linq/Observable/SubscribeOnTest.cs index 1c1c7dfa85..ec3c5f0919 100644 --- a/Rx.NET/Source/tests/Tests.System.Reactive/Tests/Linq/Observable/SubscribeOnTest.cs +++ b/Rx.NET/Source/tests/Tests.System.Reactive/Tests/Linq/Observable/SubscribeOnTest.cs @@ -10,6 +10,18 @@ using ReactiveTests.Dummies; using Xunit; +#if HAS_DISPATCHER +using System.Windows.Threading; +using System.Reactive; +using System.Reactive.Subjects; + +#endif + +#if HAS_WINFORMS +using System.Windows.Forms; +#endif + + namespace ReactiveTests.Tests { public class SubscribeOnTest : TestBase @@ -113,6 +125,28 @@ public void SubscribeOn_ControlScheduler() Application.Exit(); Assert.True(okay); } + + private Label CreateLabel() + { + var loaded = new ManualResetEvent(false); + var lbl = default(Label); + + var t = new Thread(() => + { + lbl = new Label(); + var frm = new Form { Controls = { lbl }, Width = 0, Height = 0, FormBorderStyle = FormBorderStyle.None, ShowInTaskbar = false }; + frm.Load += (_, __) => + { + loaded.Set(); + }; + Application.Run(frm); + }); + t.SetApartmentState(ApartmentState.STA); + t.Start(); + + loaded.WaitOne(); + return lbl; + } #endif #if HAS_DISPATCHER diff --git a/azure-pipelines.rx.yml b/azure-pipelines.rx.yml index 05bf6887b0..b29a116ddf 100644 --- a/azure-pipelines.rx.yml +++ b/azure-pipelines.rx.yml @@ -28,6 +28,10 @@ variables: BuildPlatform: Any CPU steps: +- task: DotNetCoreInstaller@0 + inputs: + version: '3.0.100-preview-009812' + - task: DotNetCoreCLI@2 inputs: command: custom