MCPcopy Create free account
hub / github.com/GDRETools/gdsdecomp / test_script

Function test_script

tests/test_bytecode.h:215–226  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

213}
214
215inline void test_script(const String &helper_script_path, int revision, bool helper_script, bool no_text_equality_check) {
216 // tests are located in modules/gdsdecomp/helpers
217 auto da = DirAccess::create_for_path(helper_script_path);
218 CHECK(da.is_valid());
219 CHECK(da->file_exists(helper_script_path));
220 Error err;
221 auto helper_script_text = FileAccess::get_file_as_string(helper_script_path, &err);
222 CHECK(err == OK);
223 CHECK(helper_script_text != "");
224 auto script_name = helper_script_path.get_file().get_basename();
225 test_script_text(script_name, helper_script_text, revision, helper_script, no_text_equality_check);
226}
227
228TEST_CASE("[GDSDecomp][Bytecode] GDScriptTokenizer outputs bytecode_version == LATEST_GDSCRIPT_VERSION") {
229 auto buf = GDScriptTokenizerBuffer::parse_code_string("", GDScriptTokenizerBuffer::CompressMode::COMPRESS_NONE);

Callers 1

test_bytecode.hFile · 0.85

Calls 4

test_script_textFunction · 0.85
is_validMethod · 0.45
file_existsMethod · 0.45
get_fileMethod · 0.45

Tested by

no test coverage detected