Skip to content

Commit

Permalink
Add Core tests (#7116)
Browse files Browse the repository at this point in the history
* Add Core tests

* No open RescriptCore

* Fix imports

* Build Core tests

* Fix test

* Run Core tests in CI

* CHANGELOG
  • Loading branch information
cknitt authored Oct 22, 2024
1 parent 411b7b5 commit 4c28fa1
Show file tree
Hide file tree
Showing 56 changed files with 6,204 additions and 2 deletions.
2 changes: 1 addition & 1 deletion CHANGELOG.md
Original file line number Diff line number Diff line change
Expand Up @@ -24,7 +24,7 @@
- Allow spreads of variants in patterns (`| ...someVariant as v => `) when the variant spread is a subtype of the variant matched on. https://github.com/rescript-lang/rescript-compiler/pull/6721
- Fix the issue where dynamic imports are not working for function-defined externals. https://github.com/rescript-lang/rescript-compiler/pull/7060
- Allow pattern matching on dicts. `switch someDict { | dict{"one": 1} => Js.log("one is one") }`. https://github.com/rescript-lang/rescript-compiler/pull/7059
- "ReScript Core" standard library is now included in the `rescript` npm package. https://github.com/rescript-lang/rescript-compiler/pull/7108
- "ReScript Core" standard library is now included in the `rescript` npm package. https://github.com/rescript-lang/rescript-compiler/pull/7108 https://github.com/rescript-lang/rescript-compiler/pull/7116
- Handle absolute filepaths in gentype. https://github.com/rescript-lang/rescript-compiler/pull/7104

#### :bug: Bug fix
Expand Down
12 changes: 11 additions & 1 deletion scripts/test.js
Original file line number Diff line number Diff line change
Expand Up @@ -65,7 +65,17 @@ async function runTests() {
stdio: [0, 1, 2],
});

cp.execSync(`npx mocha -t 10000 tests/tests/**/*_test.mjs`, {
cp.execSync("npx mocha -t 10000 tests/tests/**/*_test.mjs", {
cwd: path.join(__dirname, ".."),
stdio: [0, 1, 2],
});

cp.execSync("node tests/tests/src/core/Core_TestSuite.mjs", {
cwd: path.join(__dirname, ".."),
stdio: [0, 1, 2],
});

cp.execSync("node tests/tests/src/core/Core_TempTests.mjs", {
cwd: path.join(__dirname, ".."),
stdio: [0, 1, 2],
});
Expand Down
Loading

1 comment on commit 4c28fa1

@github-actions
Copy link

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Syntax Benchmarks

Benchmark suite Current: 4c28fa1 Previous: e1b7fb7 Ratio
Parse RedBlackTree.res - time/run 1.2083528533333334 ms 1.2123143266666667 ms 1.00
Parse RedBlackTree.res - allocs/run 199057 words 199057 words 1
Print RedBlackTree.res - time/run 2.31117966 ms 2.3104395133333333 ms 1.00
Print RedBlackTree.res - allocs/run 236403 words 236403 words 1
Print RedBlackTreeNoComments.res - time/run 2.1049251466666665 ms 2.10057036 ms 1.00
Print RedBlackTreeNoComments.res - allocs/run 249186 words 249186 words 1
Parse Napkinscript.res - time/run 38.836408799999994 ms 39.28006235333333 ms 0.99
Parse Napkinscript.res - allocs/run 8670066 words 8670066 words 1
Print Napkinscript.res - time/run 72.13010803333333 ms 77.00100409999999 ms 0.94
Print Napkinscript.res - allocs/run 9776327 words 9776327 words 1
Parse HeroGraphic.res - time/run 5.110011233333333 ms 5.13472718 ms 1.00
Parse HeroGraphic.res - allocs/run 1219326 words 1219326 words 1
Print HeroGraphic.res - time/run 8.64938426 ms 8.775952553333333 ms 0.99
Print HeroGraphic.res - allocs/run 1396466 words 1396466 words 1

This comment was automatically generated by workflow using github-action-benchmark.

Please sign in to comment.