Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(51)

Unified Diff: webrtc/test/testsupport/gtest_disable.h

Issue 1171033002: Ensures that modules_unittests runs on iOS (Closed) Base URL: https://chromium.googlesource.com/external/webrtc.git@master
Patch Set: rebased Created 5 years, 6 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View side-by-side diff with in-line comments
Download patch
« no previous file with comments | « webrtc/modules/video_processing/main/test/unit_test/video_processing_unittest.cc ('k') | no next file » | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: webrtc/test/testsupport/gtest_disable.h
diff --git a/webrtc/test/testsupport/gtest_disable.h b/webrtc/test/testsupport/gtest_disable.h
index 257d83612193c18184563ea48bcb3d50386fccf8..fdc56acc05b212f3c30430ac80c4f484b3238c8c 100644
--- a/webrtc/test/testsupport/gtest_disable.h
+++ b/webrtc/test/testsupport/gtest_disable.h
@@ -36,10 +36,22 @@
#define DISABLED_ON_WIN(test) test
#endif
+// Using some extra magic here to be able to chain Android and iOS macros.
+// http://stackoverflow.com/questions/8231966/why-do-i-need-double-layer-of-indirection-for-macros
#ifdef WEBRTC_ANDROID
-#define DISABLED_ON_ANDROID(test) DISABLED_##test
+#define DISABLED_ON_ANDROID_HIDDEN(test) DISABLED_##test
+#define DISABLED_ON_ANDROID(test) DISABLED_ON_ANDROID_HIDDEN(test)
#else
-#define DISABLED_ON_ANDROID(test) test
+#define DISABLED_ON_ANDROID_HIDDEN(test) test
+#define DISABLED_ON_ANDROID(test) DISABLED_ON_ANDROID_HIDDEN(test)
+#endif
+
+#ifdef WEBRTC_IOS
+#define DISABLED_ON_IOS_HIDDEN(test) DISABLED_##test
+#define DISABLED_ON_IOS(test) DISABLED_ON_IOS_HIDDEN(test)
+#else
+#define DISABLED_ON_IOS_HIDDEN(test) test
+#define DISABLED_ON_IOS(test) DISABLED_ON_IOS_HIDDEN(test)
#endif
#endif // TEST_TESTSUPPORT_INCLUDE_GTEST_DISABLE_H_
« no previous file with comments | « webrtc/modules/video_processing/main/test/unit_test/video_processing_unittest.cc ('k') | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698