Skip to content

Commit

Permalink
Supress code execution on 'With statement with global' test (fails YYC)
Browse files Browse the repository at this point in the history
  • Loading branch information
Francisco Dias committed Jan 21, 2025
1 parent f753b53 commit 7519b6a
Show file tree
Hide file tree
Showing 3 changed files with 7 additions and 4 deletions.
2 changes: 2 additions & 0 deletions projects/xUnit/objects/objRunner/Create_0.gml
Original file line number Diff line number Diff line change
Expand Up @@ -40,9 +40,11 @@ testFramework.addSuite(BasicRoomTestSuite);
testFramework.addSuite(BasicScriptTestSuite);
testFramework.addSuite(BasicShaderTestSuite);
testFramework.addSuite(BasicShaderUniformsTestSuite);
testFramework.addSuite(BasicStatementExpressionsTestSuite);
testFramework.addSuite(BasicStringTestSuite);
testFramework.addSuite(BasicSurfaceTestSuite);
testFramework.addSuite(BasicTilemapTestSuite);
testFramework.addSuite(BasicUnaryUpdateExpressions);
testFramework.addSuite(BasicVariableTestSuite);
testFramework.addSuite(BasicWeakRefsTestSuite);
testFramework.addSuite(ResourceAudioBuffersTestSuite);
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -1044,9 +1044,10 @@ function BasicStatementExpressionsTestSuite() : TestSuite() constructor {
addFact("With statement with global", function() {
global.x = 50;

with (global) {
x += 50; // Should modify the global scope
}
assert_true(false, "The block of code below should be uncommented after a YYC fix for using with (global).");
//with (global) {
// x += 50; // Should modify the global scope
//}

// Assertions
assert_equals(global.x, 100, "With statement with global failed.");
Expand Down
2 changes: 1 addition & 1 deletion projects/xUnit/xUnit.yyp

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

0 comments on commit 7519b6a

Please sign in to comment.