Negative test for FuncParamAttr.
authorDejan Mircevski <deki@google.com>
Tue, 13 Oct 2015 19:30:18 +0000 (15:30 -0400)
committerDavid Neto <dneto@google.com>
Mon, 26 Oct 2015 16:55:33 +0000 (12:55 -0400)
test/TextToBinary.Annotation.cpp

index 89fe2ef..684749b 100644 (file)
@@ -204,6 +204,11 @@ INSTANTIATE_TEST_CASE_P(TextToBinaryDecorateFuncParamAttr, OpDecorateEnumTest,
 #undef CASE
 // clang-format on
 
+TEST_F(OpDecorateEnumTest, WrongFuncParamAttr) {
+  EXPECT_THAT(CompileFailure("OpDecorate %1 FuncParamAttr xxyyzz"),
+              Eq("Invalid function parameter attribute 'xxyyzz'."));
+}
+
 // Test OpDecorate FPRoundingMode
 // clang-format off
 #define CASE(NAME) \