This patch provides TYPED_TEST and TYPED_TEST_F (similar in functionnality to gtest).
This is needed to extensively test building blocks for memory functions.
Example for TYPED_TEST_F:
template <typename T> class LlvmLibcMyTestFixture : public testing::Test {}; using Types = testing::TypeList<char, int, long>; TYPED_TEST_F(LlvmLibcMyTestFixture, Simple, Types) { EXPECT_LE(sizeof(ParamType), 8UL); }
Example for TYPED_TEST:
using Types = testing::TypeList<char, int, long>; TYPED_TEST(LlvmLibcMyTest, Simple, Types) { EXPECT_LE(sizeof(ParamType), 8UL); }
ParamType is displayed as fully qualified canonical type which can be difficult to read, the user can provide a more readable name by using the REGISTER_TYPE_NAME macro.
I noticed that Fuchsia is using its own testing framework. We can either add the same functionality to zxtest or disable them on Fuchsia. WDYT?
clang-tidy: warning: invalid case style for function 'valid_prefix' [readability-identifier-naming]
not useful
clang-tidy: warning: invalid case style for parameter 'lhs' [readability-identifier-naming]
not useful