You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@mesos.apache.org by jo...@apache.org on 2016/12/10 02:02:16 UTC

[09/12] mesos git commit: Windows: Added temporary disabled TEST_P macro.

Windows: Added temporary disabled TEST_P macro.

This patch adds an additional temporary test macro
for Windows: TEST_P_TEMP_DISABLED_ON_WINDOWS.

Macros like this exist because the global test filters in
`tests/environment.cpp` are not available for stout and libprocess.
Tests that require this macro are not ported to Windows yet.

Review: https://reviews.apache.org/r/52938/


Project: http://git-wip-us.apache.org/repos/asf/mesos/repo
Commit: http://git-wip-us.apache.org/repos/asf/mesos/commit/b531b010
Tree: http://git-wip-us.apache.org/repos/asf/mesos/tree/b531b010
Diff: http://git-wip-us.apache.org/repos/asf/mesos/diff/b531b010

Branch: refs/heads/master
Commit: b531b0105b99c1fd433071d89043bcb06573539f
Parents: ff5bef9
Author: Greg Mann <gr...@mesosphere.io>
Authored: Fri Dec 9 16:37:47 2016 -0800
Committer: Joseph Wu <jo...@apache.org>
Committed: Fri Dec 9 18:01:32 2016 -0800

----------------------------------------------------------------------
 3rdparty/stout/include/stout/gtest.hpp | 12 ++++++++++++
 1 file changed, 12 insertions(+)
----------------------------------------------------------------------


http://git-wip-us.apache.org/repos/asf/mesos/blob/b531b010/3rdparty/stout/include/stout/gtest.hpp
----------------------------------------------------------------------
diff --git a/3rdparty/stout/include/stout/gtest.hpp b/3rdparty/stout/include/stout/gtest.hpp
index 5b4d677..a004a37 100644
--- a/3rdparty/stout/include/stout/gtest.hpp
+++ b/3rdparty/stout/include/stout/gtest.hpp
@@ -205,6 +205,18 @@ template <typename T1, typename T2>
 #endif // __WINDOWS__
 
 
+// Creates a gtest `TEST_P` that is disabled on Windows.
+// TODO(greggomann): Remove after temporarily-disabled tests are fixed on
+// Windows. See MESOS-6392.
+#ifndef __WINDOWS__
+#define TEST_P_TEMP_DISABLED_ON_WINDOWS(test_case_name, test_name) \
+  TEST_P(test_case_name, test_name)
+#else
+#define TEST_P_TEMP_DISABLED_ON_WINDOWS(test_case_name, test_name) \
+  TEST_P(test_case_name, DISABLED_##test_name)
+#endif // __WINDOWS__
+
+
 // NOTE: On Windows, the closest equivalent to `sleep` is `timeout`.
 // Unfortunately, `timeout` requires an interactive terminal, otherwise
 // it errors out immediately. Instead, we use `ping` against localhost