mirror of
https://github.com/KhronosGroup/SPIRV-Tools
synced 2024-10-18 11:10:05 +00:00
Negative test for FunctionControl.
This commit is contained in:
parent
2fc334c701
commit
cc936dc613
@ -65,7 +65,7 @@ INSTANTIATE_TEST_CASE_P(TextToBinaryFunctionTest, OpFunctionControlTest,
|
||||
#undef CASE
|
||||
// clang-format on
|
||||
|
||||
TEST_F(TextToBinaryTest, CombinedFunctionControlMask) {
|
||||
TEST_F(OpFunctionControlTest, CombinedFunctionControlMask) {
|
||||
// Sample a single combination. This ensures we've integrated
|
||||
// the instruction parsing logic with spvTextParseMask.
|
||||
const std::string input =
|
||||
@ -77,6 +77,11 @@ TEST_F(TextToBinaryTest, CombinedFunctionControlMask) {
|
||||
Eq(MakeInstruction(spv::OpFunction, {1, 2, expected_mask, 3})));
|
||||
}
|
||||
|
||||
TEST_F(OpFunctionControlTest, WrongFunctionControl) {
|
||||
EXPECT_THAT(CompileFailure("%r = OpFunction %t Inline|Unroll %ft"),
|
||||
Eq("Invalid function control 'Inline|Unroll'."));
|
||||
}
|
||||
|
||||
// TODO(dneto): OpFunctionParameter
|
||||
// TODO(dneto): OpFunctionEnd
|
||||
// TODO(dneto): OpFunctionCall
|
||||
|
Loading…
Reference in New Issue
Block a user