Minor tweaks: it's called the *TestSuite
now, and removed a redundant type annotation.
#31
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
name: JavaScript Transpilation Tests | |
on: | |
workflow_dispatch: | |
pull_request: | |
types: [opened, synchronize] | |
jobs: | |
run-tests-js: | |
runs-on: ubuntu-latest | |
steps: | |
- name: 'Check out Asbyrgi' | |
uses: actions/checkout@v3 | |
with: | |
path: asbyrgi | |
ref: ${{ github.ref }} | |
- name: 'Use `node.js`' | |
uses: actions/setup-node@v3 | |
- name: 'Run `npm i`' | |
run: | | |
(cd asbyrgi; npm i) | |
- name: 'Build the Asbyrgi container' | |
id: asbyrgi_container | |
run: | | |
(cd asbyrgi; docker build .) | |
echo ::set-output name=ASBYRGI_CONTAINER_ID::$(cd asbyrgi; docker build -q .) | |
- name: 'Generate all `golden`-s' | |
run: | | |
export ASBYRGI_CONTAINER_ID=${{ steps.asbyrgi_container.outputs.ASBYRGI_CONTAINER_ID }} | |
(cd asbyrgi; ./scripts/gen_all_goldens.sh) | |
- name: 'Generate all JavaScript policies' | |
run: | | |
export ASBYRGI_CONTAINER_ID=${{ steps.asbyrgi_container.outputs.ASBYRGI_CONTAINER_ID }} | |
(cd asbyrgi; ./scripts/gen_all_js.sh) | |
- name: 'Generate all the tests.' | |
run: | | |
export ASBYRGI_CONTAINER_ID=${{ steps.asbyrgi_container.outputs.ASBYRGI_CONTAINER_ID }} | |
(cd asbyrgi; ./scripts/gen_all_js_tests.sh) | |
- name: 'RUN ALL JAVASCRIPT TESTS' | |
run: | | |
(cd asbyrgi; ./node_modules/mocha/bin/mocha.js js_test/all_tests.js) |