Ben Murdoch | b8a8cc1 | 2014-11-26 15:28:44 +0000 | [diff] [blame] | 1 | // Copyright 2014 the V8 project authors. All rights reserved. |
| 2 | // Use of this source code is governed by a BSD-style license that can be |
| 3 | // found in the LICENSE file. |
| 4 | |
Emily Bernier | d0a1eb7 | 2015-03-24 16:35:39 -0400 | [diff] [blame] | 5 | #ifndef V8_UNITTESTS_COMPILER_COMPILER_TEST_UTILS_H_ |
| 6 | #define V8_UNITTESTS_COMPILER_COMPILER_TEST_UTILS_H_ |
Ben Murdoch | b8a8cc1 | 2014-11-26 15:28:44 +0000 | [diff] [blame] | 7 | |
| 8 | #include "testing/gtest/include/gtest/gtest.h" |
| 9 | |
| 10 | namespace v8 { |
| 11 | namespace internal { |
| 12 | namespace compiler { |
| 13 | |
| 14 | // The TARGET_TEST(Case, Name) macro works just like |
| 15 | // TEST(Case, Name), except that the test is disabled |
| 16 | // if the platform is not a supported TurboFan target. |
Ben Murdoch | b8a8cc1 | 2014-11-26 15:28:44 +0000 | [diff] [blame] | 17 | #define TARGET_TEST(Case, Name) TEST(Case, Name) |
Ben Murdoch | b8a8cc1 | 2014-11-26 15:28:44 +0000 | [diff] [blame] | 18 | |
| 19 | |
| 20 | // The TARGET_TEST_F(Case, Name) macro works just like |
| 21 | // TEST_F(Case, Name), except that the test is disabled |
| 22 | // if the platform is not a supported TurboFan target. |
Ben Murdoch | b8a8cc1 | 2014-11-26 15:28:44 +0000 | [diff] [blame] | 23 | #define TARGET_TEST_F(Case, Name) TEST_F(Case, Name) |
Ben Murdoch | b8a8cc1 | 2014-11-26 15:28:44 +0000 | [diff] [blame] | 24 | |
| 25 | |
| 26 | // The TARGET_TEST_P(Case, Name) macro works just like |
| 27 | // TEST_P(Case, Name), except that the test is disabled |
| 28 | // if the platform is not a supported TurboFan target. |
Ben Murdoch | b8a8cc1 | 2014-11-26 15:28:44 +0000 | [diff] [blame] | 29 | #define TARGET_TEST_P(Case, Name) TEST_P(Case, Name) |
Ben Murdoch | b8a8cc1 | 2014-11-26 15:28:44 +0000 | [diff] [blame] | 30 | |
| 31 | |
| 32 | // The TARGET_TYPED_TEST(Case, Name) macro works just like |
| 33 | // TYPED_TEST(Case, Name), except that the test is disabled |
| 34 | // if the platform is not a supported TurboFan target. |
Ben Murdoch | b8a8cc1 | 2014-11-26 15:28:44 +0000 | [diff] [blame] | 35 | #define TARGET_TYPED_TEST(Case, Name) TYPED_TEST(Case, Name) |
Ben Murdoch | b8a8cc1 | 2014-11-26 15:28:44 +0000 | [diff] [blame] | 36 | |
| 37 | } // namespace compiler |
| 38 | } // namespace internal |
| 39 | } // namespace v8 |
| 40 | |
Emily Bernier | d0a1eb7 | 2015-03-24 16:35:39 -0400 | [diff] [blame] | 41 | #endif // V8_UNITTESTS_COMPILER_COMPILER_TEST_UTILS_H_ |