Skip to content

Commit

Permalink
Fixes test runner dependencies.
Browse files Browse the repository at this point in the history
  • Loading branch information
jake-at-work committed Feb 22, 2021
1 parent 26da581 commit edfd3a1
Show file tree
Hide file tree
Showing 7 changed files with 8 additions and 12 deletions.
2 changes: 0 additions & 2 deletions clicache/acceptance-test/CMakeLists.txt
Original file line number Diff line number Diff line change
Expand Up @@ -54,8 +54,6 @@ set_target_properties( ${PROJECT_NAME} PROPERTIES
VS_GLOBAL_TestProjectType UnitTest
VS_GLOBAL_PROJECT_TYPES "{3AC096D0-A1C2-E12C-1390-A8335801FDAB};{FAE04EC0-301F-11D3-BF4B-00C04F79EFBC}"
VS_DOTNET_REFERENCES "System;System.Xml;System.Web;System.Configuration"
VS_DOTNET_REFERENCE_Microsoft.VisualStudio.TestPlatform.TestFramework "${CMAKE_BINARY_DIR}/packages/Microsoft.VisualStudio.TestPlatform.14.0.0.1/lib/net20/Microsoft.VisualStudio.TestPlatform.TestFramework.dll"
VS_DOTNET_REFERENCE_Microsoft.VisualStudio.TestPlatform.TestFramework.Extensions "${CMAKE_BINARY_DIR}/packages/Microsoft.VisualStudio.TestPlatform.14.0.0.1/lib/net20/Microsoft.VisualStudio.TestPlatform.TestFramework.Extensions.dll"
VS_DOTNET_REFERENCE_xunit.core "${CMAKE_BINARY_DIR}/packages/xunit.extensibility.core.2.4.0/lib/netstandard1.1/xunit.core.dll"
VS_DOTNET_REFERENCE_xunit.assert "${CMAKE_BINARY_DIR}/packages/xunit.assert.2.4.0/lib/netstandard1.1/xunit.assert.dll"
VS_DOTNET_REFERENCE_xunit.abstractions "${CMAKE_BINARY_DIR}/packages/xunit.abstractions.2.0.2/lib/net35/xunit.abstractions.dll"
Expand Down
1 change: 0 additions & 1 deletion clicache/acceptance-test/packages.config
Original file line number Diff line number Diff line change
Expand Up @@ -16,7 +16,6 @@
limitations under the License.
-->
<packages>
<package id="Microsoft.VisualStudio.TestPlatform" version="14.0.0.1" targetFramework="net452" />
<package id="xunit" version="2.4.0" targetFramework="net452" />
<package id="xunit.abstractions" version="2.0.2" targetFramework="net35" />
<package id="xunit.analyzers" version="0.10.0" targetFramework="net452" />
Expand Down
2 changes: 0 additions & 2 deletions clicache/integration-test2/CMakeLists.txt
Original file line number Diff line number Diff line change
Expand Up @@ -76,8 +76,6 @@ set_target_properties(Apache.Geode.IntegrationTests2 PROPERTIES
VS_GLOBAL_TestProjectType UnitTest
VS_GLOBAL_PROJECT_TYPES "{3AC096D0-A1C2-E12C-1390-A8335801FDAB};{FAE04EC0-301F-11D3-BF4B-00C04F79EFBC}"
VS_DOTNET_REFERENCES "System;System.Xml;System.Web;System.Configuration"
VS_DOTNET_REFERENCE_Microsoft.VisualStudio.TestPlatform.TestFramework "${CMAKE_BINARY_DIR}/packages/Microsoft.VisualStudio.TestPlatform.14.0.0.1/lib/net20/Microsoft.VisualStudio.TestPlatform.TestFramework.dll"
VS_DOTNET_REFERENCE_Microsoft.VisualStudio.TestPlatform.TestFramework.Extensions "${CMAKE_BINARY_DIR}/packages/Microsoft.VisualStudio.TestPlatform.14.0.0.1/lib/net20/Microsoft.VisualStudio.TestPlatform.TestFramework.Extensions.dll"
VS_DOTNET_REFERENCE_xunit.core "${CMAKE_BINARY_DIR}/packages/xunit.extensibility.core.2.4.0/lib/netstandard1.1/xunit.core.dll"
VS_DOTNET_REFERENCE_xunit.assert "${CMAKE_BINARY_DIR}/packages/xunit.assert.2.4.0/lib/netstandard1.1/xunit.assert.dll"
VS_DOTNET_REFERENCE_xunit.abstractions "${CMAKE_BINARY_DIR}/packages/xunit.abstractions.2.0.2/lib/net35/xunit.abstractions.dll"
Expand Down
1 change: 0 additions & 1 deletion clicache/integration-test2/packages.config
Original file line number Diff line number Diff line change
Expand Up @@ -16,7 +16,6 @@
limitations under the License.
-->
<packages>
<package id="Microsoft.VisualStudio.TestPlatform" version="14.0.0.1" targetFramework="net452" />
<package id="xunit" version="2.4.0" targetFramework="net452" />
<package id="xunit.abstractions" version="2.0.2" targetFramework="net35" />
<package id="xunit.analyzers" version="0.10.0" targetFramework="net452" />
Expand Down
2 changes: 2 additions & 0 deletions clicache/test/CMakeLists.txt
Original file line number Diff line number Diff line change
Expand Up @@ -34,6 +34,7 @@ add_library(Apache.Geode.Test MODULE
native_unique_ptrTests.cpp
TimeUtilsTests.cpp
${CONFIGURE_OUT_FILES}
packages.config
)

set_target_properties(Apache.Geode.Test PROPERTIES
Expand Down Expand Up @@ -67,6 +68,7 @@ target_link_libraries(Apache.Geode.Test

# Makes project only reference, no .lib.
add_dependencies(Apache.Geode.Test Apache.Geode)
add_dependencies(Apache.Geode.Test nuget-restore)

string(REPLACE "/RTC1" "" CMAKE_CXX_FLAGS_DEBUG "${CMAKE_CXX_FLAGS_DEBUG}")
set(CMAKE_MODULE_LINKER_FLAGS "${CMAKE_MODULE_LINKER_FLAGS} ${SHARED_LINKER_FLAGS_STRONG_KEY}")
Expand Down
10 changes: 5 additions & 5 deletions clicache/test2/CMakeLists.txt
Original file line number Diff line number Diff line change
Expand Up @@ -17,6 +17,7 @@ cmake_minimum_required( VERSION 3.9 )
project( Apache.Geode.Tests2 CSharp )

set(CMAKE_CSharp_FLAGS "/langversion:5")
set(vstest_dir ${CMAKE_BINARY_DIR}/packages/Microsoft.TestPlatform.16.8.3/tools/net451/Common7/IDE/Extensions/TestPlatform)

configure_file(${CMAKE_CURRENT_SOURCE_DIR}/packages.config ${CMAKE_CURRENT_BINARY_DIR}/packages.config COPYONLY)

Expand Down Expand Up @@ -44,8 +45,6 @@ set_target_properties(Apache.Geode.Tests2 PROPERTIES
VS_GLOBAL_TestProjectType UnitTest
VS_GLOBAL_PROJECT_TYPES "{3AC096D0-A1C2-E12C-1390-A8335801FDAB};{FAE04EC0-301F-11D3-BF4B-00C04F79EFBC}"
VS_DOTNET_REFERENCES "System;System.Xml;System.Web;System.Configuration"
VS_DOTNET_REFERENCE_Microsoft.VisualStudio.TestPlatform.TestFramework "${CMAKE_BINARY_DIR}/packages/Microsoft.VisualStudio.TestPlatform.14.0.0.1/lib/net20/Microsoft.VisualStudio.TestPlatform.TestFramework.dll"
VS_DOTNET_REFERENCE_Microsoft.VisualStudio.TestPlatform.TestFramework.Extensions "${CMAKE_BINARY_DIR}/packages/Microsoft.VisualStudio.TestPlatform.14.0.0.1/lib/net20/Microsoft.VisualStudio.TestPlatform.TestFramework.Extensions.dll"
VS_DOTNET_REFERENCE_xunit.core "${CMAKE_BINARY_DIR}/packages/xunit.extensibility.core.2.4.0/lib/netstandard1.1/xunit.core.dll"
VS_DOTNET_REFERENCE_xunit.assert "${CMAKE_BINARY_DIR}/packages/xunit.assert.2.4.0/lib/netstandard1.1/xunit.assert.dll"
VS_DOTNET_REFERENCE_xunit.abstractions "${CMAKE_BINARY_DIR}/packages/xunit.abstractions.2.0.2/lib/net35/xunit.abstractions.dll"
Expand All @@ -65,8 +64,9 @@ add_dependencies(Apache.Geode.Tests2 nuget-restore)

enable_testing()

add_test(NAME Apache.Geode.Tests2
COMMAND ${CMAKE_BINARY_DIR}/packages/xunit.runner.console.2.4.0/tools/net452/xunit.console.exe
add_test(NAME Apache.Geode.Tests2
COMMAND ${vstest_dir}/vstest.console.exe
$<SHELL_PATH:$<TARGET_FILE:Apache.Geode.Tests2>>
-nologo -verbose -parallel all
--nologo --platform:x64 --parallel
WORKING_DIRECTORY "$<TARGET_FILE_DIR:Apache.Geode.Tests2>"
)
2 changes: 1 addition & 1 deletion clicache/test2/packages.config
Original file line number Diff line number Diff line change
Expand Up @@ -16,7 +16,7 @@ See the License for the specific language governing permissions and
limitations under the License.
-->
<packages>
<package id="Microsoft.VisualStudio.TestPlatform" version="14.0.0.1" targetFramework="net452" />
<package id="Microsoft.TestPlatform" version="16.8.3" targetFramework="net452" />
<package id="xunit" version="2.4.0" targetFramework="net452" />
<package id="xunit.abstractions" version="2.0.2" targetFramework="net35" />
<package id="xunit.analyzers" version="0.10.0" targetFramework="net452" />
Expand Down

0 comments on commit edfd3a1

Please sign in to comment.