aboutsummaryrefslogtreecommitdiff
path: root/tests/ECMAddTests/multi_tests
diff options
context:
space:
mode:
Diffstat (limited to 'tests/ECMAddTests/multi_tests')
-rw-r--r--tests/ECMAddTests/multi_tests/CMakeLists.txt96
-rw-r--r--tests/ECMAddTests/multi_tests/test10.cpp8
-rw-r--r--tests/ECMAddTests/multi_tests/test11.cpp8
3 files changed, 92 insertions, 20 deletions
diff --git a/tests/ECMAddTests/multi_tests/CMakeLists.txt b/tests/ECMAddTests/multi_tests/CMakeLists.txt
index ca434773..bad625b5 100644
--- a/tests/ECMAddTests/multi_tests/CMakeLists.txt
+++ b/tests/ECMAddTests/multi_tests/CMakeLists.txt
@@ -22,6 +22,8 @@ file(REMOVE
"${CMAKE_CURRENT_BINARY_DIR}/test7.txt"
"${CMAKE_CURRENT_BINARY_DIR}/test8.txt"
"${CMAKE_CURRENT_BINARY_DIR}/test9.txt"
+ "${CMAKE_CURRENT_BINARY_DIR}/test10.txt"
+ "${CMAKE_CURRENT_BINARY_DIR}/test11.txt"
)
ecm_add_tests(
@@ -30,14 +32,6 @@ ecm_add_tests(
test3.cpp
LINK_LIBRARIES testhelper
)
-# check targets exist
-get_property(_dummy TARGET test1 PROPERTY TYPE)
-get_property(_dummy TARGET test2 PROPERTY TYPE)
-get_property(_dummy TARGET test3 PROPERTY TYPE)
-# check tests exists
-get_property(_dummy TEST test1 PROPERTY TIMEOUT)
-get_property(_dummy TEST test2 PROPERTY TIMEOUT)
-get_property(_dummy TEST test3 PROPERTY TIMEOUT)
get_property(_is_win32 TARGET test1 PROPERTY WIN32_EXECUTABLE)
if (_is_win32)
message(FATAL_ERROR "test1 is a WIN32 executable when it should not be")
@@ -46,6 +40,9 @@ get_property(_is_bundle TARGET test1 PROPERTY MACOSX_BUNDLE)
if (_is_bundle)
message(FATAL_ERROR "test1 is an OS/X bundle when it should not be")
endif()
+# existence check
+get_property(_dummy TEST test1 PROPERTY TIMEOUT)
+
get_property(_is_win32 TARGET test2 PROPERTY WIN32_EXECUTABLE)
if (_is_win32)
message(FATAL_ERROR "test2 is a WIN32 executable when it should not be")
@@ -54,6 +51,17 @@ get_property(_is_bundle TARGET test2 PROPERTY MACOSX_BUNDLE)
if (_is_bundle)
message(FATAL_ERROR "test2 is an OS/X bundle when it should not be")
endif()
+get_property(_dummy TEST test2 PROPERTY TIMEOUT)
+
+get_property(_is_win32 TARGET test3 PROPERTY WIN32_EXECUTABLE)
+if (_is_win32)
+ message(FATAL_ERROR "test3 is a WIN32 executable when it should not be")
+endif()
+get_property(_is_bundle TARGET test3 PROPERTY MACOSX_BUNDLE)
+if (_is_bundle)
+ message(FATAL_ERROR "test3 is an OS/X bundle when it should not be")
+endif()
+get_property(_dummy TEST test3 PROPERTY TIMEOUT)
ecm_add_tests(
@@ -62,10 +70,6 @@ ecm_add_tests(
LINK_LIBRARIES testhelper
NAME_PREFIX pref_
)
-get_property(_dummy TARGET test4 PROPERTY TYPE)
-get_property(_dummy TARGET test5 PROPERTY TYPE)
-get_property(_dummy TEST pref_test4 PROPERTY TIMEOUT)
-get_property(_dummy TEST pref_test5 PROPERTY TIMEOUT)
get_property(_is_win32 TARGET test4 PROPERTY WIN32_EXECUTABLE)
if (_is_win32)
message(FATAL_ERROR "test4 is a WIN32 executable when it should not be")
@@ -74,6 +78,8 @@ get_property(_is_bundle TARGET test4 PROPERTY MACOSX_BUNDLE)
if (_is_bundle)
message(FATAL_ERROR "test4 is an OS/X bundle when it should not be")
endif()
+get_property(_dummy TEST pref_test4 PROPERTY TIMEOUT)
+
get_property(_is_win32 TARGET test5 PROPERTY WIN32_EXECUTABLE)
if (_is_win32)
message(FATAL_ERROR "test5 is a WIN32 executable when it should not be")
@@ -82,6 +88,7 @@ get_property(_is_bundle TARGET test5 PROPERTY MACOSX_BUNDLE)
if (_is_bundle)
message(FATAL_ERROR "test5 is an OS/X bundle when it should not be")
endif()
+get_property(_dummy TEST pref_test5 PROPERTY TIMEOUT)
ecm_add_tests(
@@ -90,10 +97,6 @@ ecm_add_tests(
LINK_LIBRARIES testhelper
GUI
)
-get_property(_dummy TARGET test6 PROPERTY TYPE)
-get_property(_dummy TARGET test7 PROPERTY TYPE)
-get_property(_dummy TEST test6 PROPERTY TIMEOUT)
-get_property(_dummy TEST test7 PROPERTY TIMEOUT)
get_property(_is_win32 TARGET test6 PROPERTY WIN32_EXECUTABLE)
if (NOT _is_win32)
message(FATAL_ERROR "test6 is not a WIN32 executable when it should be")
@@ -102,6 +105,8 @@ get_property(_is_bundle TARGET test6 PROPERTY MACOSX_BUNDLE)
if (NOT _is_bundle)
message(FATAL_ERROR "test6 is not an OS/X bundle when it should be")
endif()
+get_property(_dummy TEST test6 PROPERTY TIMEOUT)
+
get_property(_is_win32 TARGET test7 PROPERTY WIN32_EXECUTABLE)
if (NOT _is_win32)
message(FATAL_ERROR "test7 is not a WIN32 executable when it should be")
@@ -110,6 +115,7 @@ get_property(_is_bundle TARGET test7 PROPERTY MACOSX_BUNDLE)
if (NOT _is_bundle)
message(FATAL_ERROR "test7 is not an OS/X bundle when it should be")
endif()
+get_property(_dummy TEST test7 PROPERTY TIMEOUT)
ecm_add_tests(
@@ -118,11 +124,9 @@ ecm_add_tests(
LINK_LIBRARIES testhelper
NAME_PREFIX p_
GUI
+ PROPERTIES
+ LABELS "somelabel"
)
-get_property(_dummy TARGET test8 PROPERTY TYPE)
-get_property(_dummy TARGET test9 PROPERTY TYPE)
-get_property(_dummy TEST p_test8 PROPERTY TIMEOUT)
-get_property(_dummy TEST p_test9 PROPERTY TIMEOUT)
get_property(_is_win32 TARGET test8 PROPERTY WIN32_EXECUTABLE)
if (NOT _is_win32)
message(FATAL_ERROR "test8 is not a WIN32 executable when it should be")
@@ -131,6 +135,11 @@ get_property(_is_bundle TARGET test8 PROPERTY MACOSX_BUNDLE)
if (NOT _is_bundle)
message(FATAL_ERROR "test8 is not an OS/X bundle when it should be")
endif()
+get_property(_labels TEST p_test8 PROPERTY LABELS)
+if (NOT _labels STREQUAL "somelabel")
+ message(FATAL_ERROR "p_test8 LABELS property was \"${_labels}\", expected \"somelabel\"")
+endif()
+
get_property(_is_win32 TARGET test9 PROPERTY WIN32_EXECUTABLE)
if (NOT _is_win32)
message(FATAL_ERROR "test9 is not a WIN32 executable when it should be")
@@ -139,4 +148,51 @@ get_property(_is_bundle TARGET test9 PROPERTY MACOSX_BUNDLE)
if (NOT _is_bundle)
message(FATAL_ERROR "test9 is not an OS/X bundle when it should be")
endif()
+get_property(_labels TEST p_test9 PROPERTY LABELS)
+if (NOT _labels STREQUAL "somelabel")
+ message(FATAL_ERROR "p_test9 LABELS property was \"${_labels}\", expected \"somelabel\"")
+endif()
+
+
+ecm_add_tests(
+ test10.cpp
+ test11.cpp
+ LINK_LIBRARIES testhelper
+ PROPERTIES
+ LABELS "somelabel"
+ RUN_SERIAL TRUE
+ )
+get_property(_is_win32 TARGET test10 PROPERTY WIN32_EXECUTABLE)
+if (_is_win32)
+ message(FATAL_ERROR "test10 is a WIN32 executable when it should not be")
+endif()
+get_property(_is_bundle TARGET test10 PROPERTY MACOSX_BUNDLE)
+if (_is_bundle)
+ message(FATAL_ERROR "test10 is an OS/X bundle when it should not be")
+endif()
+get_property(_labels TEST test10 PROPERTY LABELS)
+if (NOT _labels STREQUAL "somelabel")
+ message(FATAL_ERROR "test10 LABELS property was \"${_labels}\", expected \"somelabel\"")
+endif()
+get_property(_run_serial TEST test10 PROPERTY RUN_SERIAL)
+if (NOT _run_serial)
+ message(FATAL_ERROR "test10 LABELS property was \"${_run_serial}\", expected TRUE")
+endif()
+
+get_property(_is_win32 TARGET test11 PROPERTY WIN32_EXECUTABLE)
+if (_is_win32)
+ message(FATAL_ERROR "test11 is a WIN32 executable when it should not be")
+endif()
+get_property(_is_bundle TARGET test11 PROPERTY MACOSX_BUNDLE)
+if (_is_bundle)
+ message(FATAL_ERROR "test11 is an OS/X bundle when it should not be")
+endif()
+get_property(_labels TEST test11 PROPERTY LABELS)
+if (NOT _labels STREQUAL "somelabel")
+ message(FATAL_ERROR "test11 LABELS property was \"${_labels}\", expected \"somelabel\"")
+endif()
+get_property(_run_serial TEST test11 PROPERTY RUN_SERIAL)
+if (NOT _run_serial)
+ message(FATAL_ERROR "test11 LABELS property was \"${_run_serial}\", expected TRUE")
+endif()
diff --git a/tests/ECMAddTests/multi_tests/test10.cpp b/tests/ECMAddTests/multi_tests/test10.cpp
new file mode 100644
index 00000000..a34a39df
--- /dev/null
+++ b/tests/ECMAddTests/multi_tests/test10.cpp
@@ -0,0 +1,8 @@
+#include "testhelper.h"
+
+int main()
+{
+ make_test_file("test10.txt");
+ return 0;
+}
+
diff --git a/tests/ECMAddTests/multi_tests/test11.cpp b/tests/ECMAddTests/multi_tests/test11.cpp
new file mode 100644
index 00000000..82641bbc
--- /dev/null
+++ b/tests/ECMAddTests/multi_tests/test11.cpp
@@ -0,0 +1,8 @@
+#include "testhelper.h"
+
+int main()
+{
+ make_test_file("test11.txt");
+ return 0;
+}
+