[netcore] Simplify runtime and tests synchronization
authorMarek Safar <marek.safar@gmail.com>
Wed, 3 Apr 2019 13:27:48 +0000 (15:27 +0200)
committerMarek Safar <marek.safar@gmail.com>
Wed, 3 Apr 2019 15:35:14 +0000 (17:35 +0200)
Commit migrated from https://github.com/mono/mono/commit/9bdf6c2c6c72e139db5dab5dcb800d1c4a7a2bc2

src/mono/netcore/Makefile.am
src/mono/netcore/excludes-System.Runtime.Tests.rsp

index 4021b31..a9ff1d0 100644 (file)
@@ -1,7 +1,15 @@
+#
+# NETCORETESTS_VERSION and NETCOREAPP_VERSION must be updated in sync, we are using coreclr repo for that but that's fine for now
+#
+
+# Extracted MicrosoftPrivateCoreFxNETCoreAppVersion from https://github.com/dotnet/coreclr/blob/master/eng/Versions.props#L11
+NETCORETESTS_VERSION := 4.6.0-preview4.19202.4
+
+# Extracted MicrosoftNETCoreAppVersion from https://github.com/dotnet/coreclr/blob/master/eng/Versions.props#L13
+NETCOREAPP_VERSION := 3.0.0-preview4-27529-11
 
-NETCORESDK_VERSION=3.0.100-preview4-011024
-NETCORESDK_FILE=dotnet-sdk-$(NETCORESDK_VERSION)-osx-x64.tar.gz
-URL:=https://dotnetcli.blob.core.windows.net/dotnet/Sdk/$(NETCORESDK_VERSION)/$(NETCORESDK_FILE)
+NETCORESDK_FILE := dotnet-runtime-$(NETCOREAPP_VERSION)-osx-x64.tar.gz
+URL := https://dotnetcli.blob.core.windows.net/dotnet/Runtime/$(NETCOREAPP_VERSION)/$(NETCORESDK_FILE)
 
 $(NETCORESDK_FILE):
        curl $(URL) --output $(NETCORESDK_FILE)
@@ -11,11 +19,10 @@ build-sample:
        dotnet build sample/HelloWorld
 
 run-sample:
-       COMPlus_DebugWriteToStdErr=1 ./dotnet --fx-version "$(VERSION)" sample/HelloWorld/bin/Debug/netcoreapp3.0/HelloWorld.dll
+       COMPlus_DebugWriteToStdErr=1 ./dotnet --fx-version "$(NETCOREAPP_VERSION)" sample/HelloWorld/bin/Debug/netcoreapp3.0/HelloWorld.dll
 
 # COREHOST_TRACE=1 
-VERSION:=3.0.0-preview4-27601-05
-SHAREDRUNTIME:=shared/Microsoft.NETCore.App/$(VERSION)
+SHAREDRUNTIME := shared/Microsoft.NETCore.App/$(NETCOREAPP_VERSION)
 
 bcl:
        $(MAKE) -C ../mcs/class/System.Private.CoreLib
@@ -54,13 +61,12 @@ clean:
 # we need COREFX_ROOT only for xunit.console.deps.json and CoreFx.Private.TestUtilities.dll
 xtest-%: prepare check-env dl-test-assets
        echo -n "***************** $* *********************"
-       ln -sf $(CURDIR)/sdk/$(NETCORESDK_VERSION)/System.Text.Encoding.CodePages.dll assets/extracted/$*/
-       ln -sf $(CURDIR)/shared/Microsoft.AspNetCore.App/3.0.0-preview4-19180-01/Newtonsoft.Json.dll assets/extracted/$*/
+       cp $(COREFX_BINDIR)/runtime/netcoreapp-OSX-Debug-x64/Newtonsoft.Json.dll assets/extracted/$*/
        cp $(COREFX_BINDIR)/runtime/netcoreapp-OSX-Debug-x64/xunit.console.deps.json assets/extracted/$*/
        cp $(COREFX_BINDIR)/runtime/netcoreapp-OSX-Debug-x64/CoreFx.Private.TestUtilities.dll assets/extracted/$*/
-       sed -i -e 's/9.9.9/$(VERSION)/g' assets/extracted/$*/*.runtimeconfig.json
+       sed -i -e 's/9.9.9/$(NETCOREAPP_VERSION)/g' assets/extracted/$*/*.runtimeconfig.json
        cd assets/extracted/$* && \
-       COMPlus_DebugWriteToStdErr=1 $(CURDIR)/./dotnet --fx-version "$(VERSION)" xunit.console.dll $*.dll \
+       COMPlus_DebugWriteToStdErr=1 $(CURDIR)/./dotnet --fx-version "$(NETCOREAPP_VERSION)" xunit.console.dll $*.dll \
                -notrait category=outerloop -notrait category=nonosxtests -notrait category=failing \
                -notrait category=nonnetcoreapptests -noappdomain -noshadow -parallel all \
                -html ../../../TestResult-$*.html -nunit ../../TestResult-$*-netcore-xunit.xml \
@@ -83,14 +89,14 @@ PASSING_COREFX_TESTS = \
        System.Runtime.CompilerServices.VisualC.Tests \
        System.Runtime.InteropServices.RuntimeInformation.Tests
 
-xtestall: $(foreach workingtest, $(foreach test, $(wildcard assets/extracted/*), \
+xtestall: dl-test-assets $(foreach workingtest, $(foreach test, $(wildcard assets/extracted/*), \
                $(filter-out $(EXCLUDED_COREFX_TESTS), $(notdir $(test)))), $(addprefix xtest-, $(workingtest)))
 
-xtestpass: $(foreach workingtest, $(foreach test, $(wildcard assets/extracted/*), \
+xtestpass: dl-test-assets $(foreach workingtest, $(foreach test, $(wildcard assets/extracted/*), \
                $(filter $(PASSING_COREFX_TESTS), $(notdir $(test)))), $(addprefix xtest-, $(workingtest)))
 
-FEED_BASE_URL = https://dotnetfeed.blob.core.windows.net/dotnet-core
-TEST_ASSETS_URL = https://dotnetfeed.blob.core.windows.net/dotnet-core/corefx-tests/4.6.0-preview4.19201.9/OSX.x64/netcoreapp/corefx-test-assets.xml
+FEED_BASE_URL := https://dotnetfeed.blob.core.windows.net/dotnet-core
+TEST_ASSETS_URL = $(FEED_BASE_URL)/corefx-tests/$(NETCORETESTS_VERSION)/OSX.x64/netcoreapp/corefx-test-assets.xml
 corefx-test-assets.xml:
        curl $(TEST_ASSETS_URL) --output corefx-test-assets.xml
 
index 59f4c36..a277baf 100644 (file)
@@ -75,5 +75,3 @@
 # causes 'error: Return type can't be a byref type Parameter name: returnType':
 -nomethod System.Tests.Types.VoidTests.IsByRef_Get_ReturnsExpected
 
-# FEATURE_UTF8STRING
--noclass System.Text.Unicode.Tests.Utf8Tests