Skip to content

Commit

Permalink
Minor refactoring
Browse files Browse the repository at this point in the history
No functional changes.
  • Loading branch information
Pieter12345 committed Dec 1, 2024
1 parent c64b616 commit 2da11c0
Showing 1 changed file with 4 additions and 4 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -238,15 +238,15 @@ public void testExecute3() {
= "[";
MethodScriptCompiler.execute(MethodScriptCompiler.compile(MethodScriptCompiler.lex(script, null, null, true), null, envs), env, null, null);
fail("Test passed, but wasn't supposed to");
} catch (ConfigCompileException | ConfigCompileGroupException ex) {
} catch (AbstractCompileException ex) {
//Passed
}
try {
String script
= "]";
MethodScriptCompiler.execute(MethodScriptCompiler.compile(MethodScriptCompiler.lex(script, null, null, true), null, envs), env, null, null);
fail("Test passed, but wasn't supposed to");
} catch (ConfigCompileException | ConfigCompileGroupException ex) {
} catch (AbstractCompileException ex) {
//Passed
}
}
Expand Down Expand Up @@ -450,7 +450,7 @@ public void testCompile1() {
String config = "/cmd [$p] $q = msg('')";
MethodScriptCompiler.preprocess(MethodScriptCompiler.lex(config, null, null, false), envs).get(0).compile(env);
fail("Test passed, but wasn't supposed to");
} catch (ConfigCompileException | ConfigCompileGroupException ex) {
} catch (AbstractCompileException ex) {
//Passed
}
}
Expand Down Expand Up @@ -495,7 +495,7 @@ public void testCompile2() {
String config = "/cmd [$p=player()] = msg('')";
MethodScriptCompiler.preprocess(MethodScriptCompiler.lex(config, null, null, false), envs).get(0).compile(env);
fail("Test passed, but wasn't supposed to");
} catch (ConfigCompileException | ConfigCompileGroupException ex) {
} catch (AbstractCompileException ex) {
//Passed
}
}
Expand Down

0 comments on commit 2da11c0

Please sign in to comment.