You've already forked linux-packaging-mono
Imported Upstream version 5.12.0.220
Former-commit-id: c477e03582759447177c6d4bf412cd2355aad476
This commit is contained in:
parent
8bd104cef2
commit
8fc30896db
@@ -20,9 +20,15 @@ TEST_RUNTIME_WRAPPERS_PATH = $(shell dirname $(RUNTIME))/_tmpinst/bin
|
||||
ifndef NO_TEST
|
||||
|
||||
test_nunit_lib = nunitlite.dll
|
||||
xunit_core := xunit.core xunit.abstractions xunit.assert Xunit.NetCore.Extensions
|
||||
xunit_core := xunit.core xunit.execution.desktop xunit.abstractions xunit.assert Xunit.NetCore.Extensions
|
||||
xunit_deps := System.Runtime
|
||||
xunit_src := $(patsubst %,$(topdir)/../external/xunit-binaries/%,BenchmarkAttribute.cs BenchmarkDiscover.cs) $(topdir)/../mcs/class/test-helpers/PlatformDetection.cs
|
||||
|
||||
ifeq ($(USE_XTEST_REMOTE_EXECUTOR), YES)
|
||||
XTEST_REMOTE_EXECUTOR = $(xunit_test_lib)_RemoteExecuter.exe
|
||||
xunit_src += $(topdir)/../mcs/class/test-helpers/AdminHelper.cs $(topdir)/../mcs/class/test-helpers/RemoteExecutorTestBase.Mono.cs $(topdir)/../external/corefx/src/CoreFx.Private.TestUtilities/src/System/IO/FileCleanupTestBase.cs $(topdir)/../external/corefx/src/CoreFx.Private.TestUtilities/src/System/Diagnostics/RemoteExecutorTestBase.Process.cs $(topdir)/../external/corefx/src/CoreFx.Private.TestUtilities/src/System/Diagnostics/RemoteExecutorTestBase.cs $(topdir)/../external/corefx/src/Common/src/System/PasteArguments.cs
|
||||
endif
|
||||
|
||||
xunit_class_deps :=
|
||||
|
||||
xunit_libs_ref = $(patsubst %,-r:$(topdir)/../external/xunit-binaries/%.dll,$(xunit_core))
|
||||
@@ -54,6 +60,7 @@ test_makefrag = $(depsdir)/$(test_lib).makefrag
|
||||
test_flags = $(test_nunit_ref) $(TEST_MCS_FLAGS) $(TEST_LIB_MCS_FLAGS)
|
||||
ifndef NO_BUILD
|
||||
test_flags += -r:$(the_assembly)
|
||||
test_assembly_dep = $(the_assembly)
|
||||
endif
|
||||
tests_CLEAN_FILES += $(ASSEMBLY:$(ASSEMBLY_EXT)=_test*.dll) $(ASSEMBLY:$(ASSEMBLY_EXT)=_test*.pdb) $(test_response) $(test_makefrag)
|
||||
|
||||
@@ -64,7 +71,7 @@ xunit_test_lib = $(PROFILE)_$(ASSEMBLY:$(ASSEMBLY_EXT)=_xunit-test.dll)
|
||||
|
||||
xtest_response = $(depsdir)/$(xunit_test_lib).response
|
||||
xtest_makefrag = $(depsdir)/$(xunit_test_lib).makefrag
|
||||
xtest_flags = -r:$(the_assembly) $(xunit_libs_ref) $(XTEST_MCS_FLAGS) $(XTEST_LIB_MCS_FLAGS)
|
||||
xtest_flags = -r:$(the_assembly) $(xunit_libs_ref) $(XTEST_MCS_FLAGS) $(XTEST_LIB_MCS_FLAGS) /unsafe
|
||||
|
||||
ifeq ($(wildcard $(xtest_sourcefile)),)
|
||||
xtest_sourcefile = $(ASSEMBLY:$(ASSEMBLY_EXT)=_xtest.dll.sources)
|
||||
@@ -108,7 +115,7 @@ run-test-local: run-test-lib
|
||||
run-test-ondotnet-local: run-test-ondotnet-lib
|
||||
|
||||
ifdef TEST_WITH_INTERPRETER
|
||||
TEST_HARNESS_EXCLUDES = -exclude=$(PLATFORM_TEST_HARNESS_EXCLUDES)$(PROFILE_TEST_HARNESS_EXCLUDES)NotWorking,InterpreterNotWorking,CAS
|
||||
TEST_HARNESS_EXCLUDES = -exclude=$(PLATFORM_TEST_HARNESS_EXCLUDES)$(PROFILE_TEST_HARNESS_EXCLUDES)NotWorking,NotWorkingRuntimeInterpreter,CAS
|
||||
else
|
||||
TEST_HARNESS_EXCLUDES = -exclude=$(PLATFORM_TEST_HARNESS_EXCLUDES)$(PROFILE_TEST_HARNESS_EXCLUDES)NotWorking,CAS
|
||||
endif
|
||||
@@ -224,7 +231,7 @@ ifdef HAVE_CS_TESTS
|
||||
$(test_lib_dir):
|
||||
mkdir -p $@
|
||||
|
||||
$(test_lib_output): $(the_assembly) $(test_response) $(test_nunit_dep) $(test_lib_dir)
|
||||
$(test_lib_output): $(test_assembly_dep) $(test_response) $(test_nunit_dep) $(test_lib_dir)
|
||||
$(TEST_COMPILE) $(LIBRARY_FLAGS) -target:library -out:$@ $(test_flags) $(LOCAL_TEST_COMPILER_ONDOTNET_FLAGS) @$(test_response)
|
||||
|
||||
test_response_preprocessed = $(test_response)_preprocessed
|
||||
@@ -270,18 +277,21 @@ XTEST_COVERAGE_FLAGS = -O=-aot --profile=coverage:output=$(topdir)/class/lib/$(P
|
||||
endif
|
||||
|
||||
check: run-xunit-test-local
|
||||
run-xunit-test: run-xunit-test-local
|
||||
xunit-test-local: $(xunit_test_lib)
|
||||
run-xunit-test-local: run-xunit-test-lib
|
||||
|
||||
# cp -rf is a HACK for xunit runner to require xunit.execution.desktop.dll file in local folder on .net only
|
||||
run-xunit-test-lib: xunit-test-local
|
||||
run-xunit-test-lib: xunit-test-local $(XTEST_REMOTE_EXECUTOR)
|
||||
@cp -rf $(XTEST_HARNESS_PATH)/xunit.execution.desktop.dll xunit.execution.desktop.dll
|
||||
ok=:; \
|
||||
PATH="$(TEST_RUNTIME_WRAPPERS_PATH):$(PATH)" $(TEST_RUNTIME) $(TEST_RUNTIME_FLAGS) $(XTEST_COVERAGE_FLAGS) $(AOT_RUN_FLAGS) $(XTEST_HARNESS) $(xunit_test_lib) $(XTEST_HARNESS_FLAGS) $(XTEST_TRAIT) || ok=false; \
|
||||
$$ok
|
||||
@rm -f xunit.execution.desktop.dll
|
||||
|
||||
# Some xunit tests want to be executed in a separate process (see RemoteExecutorTestBase)
|
||||
$(XTEST_REMOTE_EXECUTOR): $(topdir)/../mcs/class/test-helpers/RemoteExecutorConsoleApp.cs
|
||||
$(TEST_COMPILE) $(topdir)/../mcs/class/test-helpers/RemoteExecutorConsoleApp.cs -r:$(xunit_test_lib) $(xtest_flags) /debug-
|
||||
|
||||
$(xunit_test_lib): $(the_assembly) $(xtest_response) $(xunit_libs_dep) $(xunit_src)
|
||||
$(TEST_COMPILE) $(LIBRARY_FLAGS) $(XTEST_LIB_FLAGS) -target:library -out:$@ $(xtest_flags) @$(xtest_response) $(xunit_src)
|
||||
|
||||
|
||||
Reference in New Issue
Block a user