| 251 | ~CxxBinaryParseTest() override { spvDiagnosticDestroy(diagnostic_); } |
| 252 | |
| 253 | void Parse(const SpirvVector& words, bool expected_result, |
| 254 | bool flip_words = false, |
| 255 | spv_target_env env = SPV_ENV_UNIVERSAL_1_0) { |
| 256 | SpirvVector flipped_words(words); |
| 257 | MaybeFlipWords(flip_words, flipped_words.begin(), flipped_words.end()); |
| 258 | spvtools::SpirvTools tools(env); |
| 259 | EXPECT_EQ(expected_result, tools.Parse(flipped_words, header_parser_, |
| 260 | instruction_parser_, &diagnostic_)); |
| 261 | } |
| 262 | |
| 263 | spv_diagnostic diagnostic_ = nullptr; |
| 264 | MockParseClient client_; |