From c0eb22504443b1a7cf51605b815affd11bf898ab Mon Sep 17 00:00:00 2001 From: Dejan Mircevski Date: Tue, 13 Oct 2015 15:15:54 -0400 Subject: [PATCH] Negative test for FPRoundingMode. --- test/TextToBinary.Annotation.cpp | 5 +++++ 1 file changed, 5 insertions(+) diff --git a/test/TextToBinary.Annotation.cpp b/test/TextToBinary.Annotation.cpp index 053210b89..320ba409c 100644 --- a/test/TextToBinary.Annotation.cpp +++ b/test/TextToBinary.Annotation.cpp @@ -213,6 +213,11 @@ INSTANTIATE_TEST_CASE_P(TextToBinaryDecorateFPRoundingMode, OpDecorateEnumTest, #undef CASE // clang-format on +TEST_F(OpDecorateEnumTest, WrongFPRoundingMode) { + EXPECT_THAT(CompileFailure("OpDecorate %1 FPRoundingMode xxyyzz"), + Eq("Invalid floating-point rounding mode 'xxyyzz'.")); +} + // Test OpDecorate FPFastMathMode. // These can by named enums for the single-bit masks. However, we don't support // symbolic combinations of the masks. Rather, they can use !