Skip to content

Commit

Permalink
chore: self mutation (e2e-2of2.diff)
Browse files Browse the repository at this point in the history
Signed-off-by: monada-bot[bot] <[email protected]>
  • Loading branch information
monadabot committed Aug 7, 2024
1 parent d37b19e commit 5aab628
Show file tree
Hide file tree
Showing 2 changed files with 20 additions and 8 deletions.
20 changes: 20 additions & 0 deletions tools/hangar/__snapshots__/invalid.ts.snap
Original file line number Diff line number Diff line change
Expand Up @@ -3303,6 +3303,26 @@ Test Files 1 failed (1)
Duration <DURATION>"
`;

exports[`json_values.test.w 1`] = `
"error: "MutArray<num>" is not a legal JSON value
--> ../../../examples/tests/invalid/json_values.test.w:11:20
|
11 | takeJson({ values: arr });
| ^^^


error: "MutMap<str>" is not a legal JSON value
--> ../../../examples/tests/invalid/json_values.test.w:13:20
|
13 | takeJson({ values: map });
| ^^^

Tests 1 failed (1)
Snapshots 1 skipped
Test Files 1 failed (1)
Duration <DURATION>"
`;

exports[`map_entries.test.w 1`] = `
"error: Expected type to be "str", but got "num" instead
--> ../../../examples/tests/invalid/map_entries.test.w:2:20
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -41,14 +41,6 @@ class $Root extends $stdlib.std.Resource {
(base.concat($macros.__MutArray_copy(false, extra, )));
const base2 = ["foo"];
const obj = ({"first": "ok", "second": (["cool"].concat(base2))});
const arr = [1, 2, 3];
$macros.__MutArray_push(false, arr, 4);
const map = ({["a"]: "1"});
$macros.__MutMap_set(false, map, "b", "2");
const takeJson = ((obj) => {
});
(takeJson(({"values": arr})));
(takeJson(({"values": map})));
}
}
const $APP = $PlatformManager.createApp({ outdir: $outdir, name: "json-types.test", rootConstruct: $Root, isTestEnvironment: $wing_is_test, entrypointDir: process.env['WING_SOURCE_DIR'], rootId: process.env['WING_ROOT_ID'] });
Expand Down

0 comments on commit 5aab628

Please sign in to comment.