Add a test for meta files attached to Lua scripts

This commit is contained in:
Lucien Greathouse
2019-07-02 16:15:24 -07:00
parent 2a0efe70a5
commit d900887d97
4 changed files with 20 additions and 0 deletions

View File

@@ -24,6 +24,16 @@ fn bad_json_model() {
}
}
#[test]
fn bad_meta_lua_classname() {
let project = Project::load_fuzzy(&TEST_PROJECTS_ROOT.join("bad_meta_lua_classname"))
.expect("Project file didn't load");
if LiveSession::new(Arc::new(project)).is_ok() {
panic!("Project should not have succeeded");
}
}
#[test]
fn bad_meta_rbxmx_properties() {
let project = Project::load_fuzzy(&TEST_PROJECTS_ROOT.join("bad_meta_rbxmx_properties"))

View File

@@ -0,0 +1,6 @@
{
"name": "bad_meta_lua_classname",
"tree": {
"$path": "src"
}
}

View File

@@ -0,0 +1 @@
-- foo.lua

View File

@@ -0,0 +1,3 @@
{
"className": "Script"
}