summaryrefslogtreecommitdiffstats
path: root/Tests/RunCMake/GeneratorPlatform/TestPlatformToolchain.cmake
diff options
context:
space:
mode:
Diffstat (limited to 'Tests/RunCMake/GeneratorPlatform/TestPlatformToolchain.cmake')
-rw-r--r--Tests/RunCMake/GeneratorPlatform/TestPlatformToolchain.cmake16
1 files changed, 16 insertions, 0 deletions
diff --git a/Tests/RunCMake/GeneratorPlatform/TestPlatformToolchain.cmake b/Tests/RunCMake/GeneratorPlatform/TestPlatformToolchain.cmake
new file mode 100644
index 0000000..c4430a5
--- /dev/null
+++ b/Tests/RunCMake/GeneratorPlatform/TestPlatformToolchain.cmake
@@ -0,0 +1,16 @@
+if("x${CMAKE_GENERATOR_PLATFORM}" STREQUAL "xTest Platform")
+ message(SEND_ERROR "CMAKE_GENERATOR_PLATFORM is \"Test Platform\" as expected.")
+else()
+ message(FATAL_ERROR
+ "CMAKE_GENERATOR_PLATFORM is \"${CMAKE_GENERATOR_PLATFORM}\" "
+ "but should be \"Test Platform\"!")
+endif()
+if(CMAKE_GENERATOR MATCHES "Visual Studio")
+ if("x${CMAKE_VS_PLATFORM_NAME}" STREQUAL "xTest Platform")
+ message(SEND_ERROR "CMAKE_VS_PLATFORM_NAME is \"Test Platform\" as expected.")
+ else()
+ message(FATAL_ERROR
+ "CMAKE_VS_PLATFORM_NAME is \"${CMAKE_VS_PLATFORM_NAME}\" "
+ "but should be \"Test Platform\"!")
+ endif()
+endif()