@@ -212,8 +212,61 @@ jobs:
212212 run : echo "C:\Program Files\Git\bin" >> $GITHUB_PATH
213213 shell : bash
214214
215- - name : Run rewatch tests
216- run : ./rewatch/tests/suite.sh rewatch/target/release/rescript
215+ - name : Run OCaml rewatch parity tests
216+ timeout-minutes : 20
217+ run : |
218+ bash rewatch-ocaml/tests/check_rust_test_coverage.sh --require-complete
219+ bash rewatch-ocaml/tests/check_canonical_test_coverage.sh
220+ bash rewatch-ocaml/tests/check_config_acceptance.sh \
221+ packages/@rescript/${{ matrix.node-target }}/bin/rescript-rust.exe \
222+ packages/@rescript/${{ matrix.node-target }}/bin/rescript.exe
223+ bash rewatch-ocaml/tests/check_command_validation.sh \
224+ packages/@rescript/${{ matrix.node-target }}/bin/rescript-rust.exe \
225+ packages/@rescript/${{ matrix.node-target }}/bin/rescript.exe
226+ shell : bash
227+
228+ - name : Run OCaml rewatch interactive output tests
229+ # Terminal rendering depends on the host OS, not the CPU architecture.
230+ # Use the faster ARM runners for one Linux and one macOS check. Windows
231+ # does not provide a reliable native equivalent of the `script` PTY.
232+ if : matrix.node-target == 'linux-arm64' || matrix.node-target == 'darwin-arm64'
233+ timeout-minutes : 15
234+ run : |
235+ bash rewatch-ocaml/tests/check_interactive_output.sh \
236+ packages/@rescript/${{ matrix.node-target }}/bin/rescript-rust.exe \
237+ packages/@rescript/${{ matrix.node-target }}/bin/rescript.exe
238+ shell : bash
239+
240+ - name : Run OCaml rewatch verbose output tests
241+ timeout-minutes : 10
242+ run : |
243+ bash rewatch-ocaml/tests/check_verbose_output.sh \
244+ packages/@rescript/${{ matrix.node-target }}/bin/rescript-rust.exe \
245+ packages/@rescript/${{ matrix.node-target }}/bin/rescript.exe
246+ shell : bash
247+
248+ - name : Run OCaml rewatch unit tests
249+ timeout-minutes : 10
250+ run : |
251+ opam exec -- dune build tests/rewatch_ounit_tests/rewatch_ounit_tests_main.exe
252+ # Run the executable directly so a stuck test leaves live progress;
253+ # dune otherwise buffers the test output until the action exits.
254+ opam exec -- ./_build/default/tests/rewatch_ounit_tests/rewatch_ounit_tests_main.exe -runner sequential
255+ shell : bash
256+
257+ - name : Run OCaml rewatch focused integration tests
258+ timeout-minutes : 30
259+ run : |
260+ sh rewatch-ocaml/tests/run.sh packages/@rescript/${{ matrix.node-target }}/bin/rescript.exe
261+ shell : bash
262+
263+ - name : Run OCaml rewatch canonical tests
264+ run : ./rewatch/tests/suite.sh packages/@rescript/${{ matrix.node-target }}/bin/rescript.exe
265+ shell : bash
266+
267+ - name : Run Rust rewatch reference tests on Windows
268+ if : runner.os == 'Windows'
269+ run : ./rewatch/tests/suite.sh packages/@rescript/${{ matrix.node-target }}/bin/rescript-rust.exe
217270 shell : bash
218271
219272 - name : Run syntax benchmarks
@@ -623,6 +676,10 @@ jobs:
623676 shell : bash
624677 working-directory : rewatch/testrepo
625678
626- - name : Run rewatch integration tests
679+ - name : Run installed default OCaml rewatch integration tests
627680 run : ./rewatch/tests/suite.sh rewatch/testrepo/node_modules/.bin/rescript
628681 shell : bash
682+
683+ - name : Run installed Rust rewatch reference integration tests
684+ run : ./rewatch/tests/suite.sh rewatch/testrepo/node_modules/.bin/rescript-rust
685+ shell : bash
0 commit comments