Skip to content

Commit

Permalink
Merge pull request #441 from moonbitlang/rynco/fix-coverage-driver
Browse files Browse the repository at this point in the history
  • Loading branch information
lynzrand authored Nov 5, 2024
2 parents 62b13a6 + 0327480 commit c8c4bcf
Show file tree
Hide file tree
Showing 11 changed files with 126 additions and 97 deletions.
18 changes: 18 additions & 0 deletions .github/workflows/ci.yml
Original file line number Diff line number Diff line change
Expand Up @@ -162,6 +162,14 @@ jobs:

- name: Build
run: cargo build

- name: Set built binary to PATH (Unix)
if: ${{ matrix.os != 'windows-latest' }}
run: echo "$GITHUB_WORKSPACE/target/debug" >> $GITHUB_PATH
- name: Set built binary to PATH (Windows)
if: ${{ matrix.os == 'windows-latest' }}
run: Add-Content $env:GITHUB_PATH "$env:GITHUB_WORKSPACE\target\debug"

- name: Versions
run: cargo run --bin moon version --all
- name: Bundle core (Unix)
Expand Down Expand Up @@ -240,6 +248,14 @@ jobs:

- name: Build
run: cargo build

- name: Set built binary to PATH (Unix)
if: ${{ matrix.os != 'windows-latest' }}
run: echo "$GITHUB_WORKSPACE/target/debug" >> $GITHUB_PATH
- name: Set built binary to PATH (Windows)
if: ${{ matrix.os == 'windows-latest' }}
run: Add-Content $env:GITHUB_PATH "$env:GITHUB_WORKSPACE\target\debug"

- name: Versions
run: cargo run --bin moon version --all
- name: Bundle core (Unix)
Expand Down Expand Up @@ -316,6 +332,8 @@ jobs:
- name: Build
run: cargo build
- name: Set built binary to PATH (Unix)
run: echo "$GITHUB_WORKSPACE/target/debug" >> $GITHUB_PATH
- name: Versions
run: cargo run --bin moon version --all
- name: Bundle core (Unix)
Expand Down
4 changes: 2 additions & 2 deletions crates/moon/tests/test_cases/cond_comp.in/moon.test
Original file line number Diff line number Diff line change
Expand Up @@ -42,10 +42,10 @@
moon generate-test-driver --source-dir . --target-dir ./target --package username/hello/lib --sort-input --target js --driver-kind blackbox
moonc build-package ./src/lib/all.mbt ./src/lib/js_or_wasm.mbt ./src/lib/only_debug.mbt ./src/lib/only_js.mbt ./src/lib/wasm_release_or_js_debug.mbt -o ./target/js/debug/test/lib/lib.core -pkg username/hello/lib -pkg-sources username/hello/lib:./src/lib -target js -g
moonc build-package ./src/lib/hello_test.mbt ./src/lib/js_only_test.mbt ./target/js/debug/test/lib/__generated_driver_for_blackbox_test.mbt -o ./target/js/debug/test/lib/lib.blackbox_test.core -pkg username/hello/lib_blackbox_test -is-main -i ./target/js/debug/test/lib/lib.mi:lib -pkg-sources username/hello/lib_blackbox_test:./src/lib -target js -g -blackbox-test
moonc link-core ./target/js/debug/test/lib/lib.core ./target/js/debug/test/lib/lib.blackbox_test.core -main username/hello/lib_blackbox_test -o ./target/js/debug/test/lib/lib.blackbox_test.js -test-mode -pkg-config-path ./src/lib/moon.pkg.json -pkg-sources username/hello/lib:./src/lib -pkg-sources username/hello/lib_blackbox_test:./src/lib -exported_functions moonbit_test_driver_internal_execute -js-format cjs -target js -g
moonc link-core ./target/js/debug/test/lib/lib.core ./target/js/debug/test/lib/lib.blackbox_test.core -main username/hello/lib_blackbox_test -o ./target/js/debug/test/lib/lib.blackbox_test.js -test-mode -pkg-config-path ./src/lib/moon.pkg.json -pkg-sources username/hello/lib:./src/lib -pkg-sources username/hello/lib_blackbox_test:./src/lib -exported_functions moonbit_test_driver_internal_execute,moonbit_test_driver_finish -js-format cjs -target js -g
moon generate-test-driver --source-dir . --target-dir ./target --package username/hello/lib --sort-input --target js --driver-kind internal
moonc build-package ./src/lib/all.mbt ./src/lib/js_or_wasm.mbt ./src/lib/only_debug.mbt ./src/lib/only_js.mbt ./src/lib/wasm_release_or_js_debug.mbt ./target/js/debug/test/lib/__generated_driver_for_internal_test.mbt -o ./target/js/debug/test/lib/lib.internal_test.core -pkg username/hello/lib -is-main -pkg-sources username/hello/lib:./src/lib -target js -g
moonc link-core ./target/js/debug/test/lib/lib.internal_test.core -main username/hello/lib -o ./target/js/debug/test/lib/lib.internal_test.js -test-mode -pkg-config-path ./src/lib/moon.pkg.json -pkg-sources username/hello/lib:./src/lib -exported_functions moonbit_test_driver_internal_execute -js-format cjs -target js -g
moonc link-core ./target/js/debug/test/lib/lib.internal_test.core -main username/hello/lib -o ./target/js/debug/test/lib/lib.internal_test.js -test-mode -pkg-config-path ./src/lib/moon.pkg.json -pkg-sources username/hello/lib:./src/lib -exported_functions moonbit_test_driver_internal_execute,moonbit_test_driver_finish -js-format cjs -target js -g

$ moon bundle --dry-run --target js --sort-input --nostd
moonc build-package ./src/lib/all.mbt ./src/lib/js_and_release.mbt ./src/lib/js_or_wasm.mbt ./src/lib/only_js.mbt ./src/lib/wasm_release_or_js_debug.mbt -o ./target/js/release/bundle/lib/lib.core -pkg username/hello/lib -pkg-sources username/hello/lib:./lib -target js
Expand Down
Loading

0 comments on commit c8c4bcf

Please sign in to comment.