AVA framework
Prerequisites
Lifecycle commands
npx slnodejs start \
--tokenFile ./sltoken.txt --buildSessionIdFile buildSessionId \
--testStage "Unit Tests"
# Run AVA with nyc coverage, converting TAP output to JUnit XML
ENV=test npx nyc --reporter=json ./node_modules/.bin/ava --tap | npx tap-xunit > junit.xml
npx slnodejs nycReport \
--tokenFile ./sltoken.txt --buildSessionIdFile buildSessionId \
--report ./coverage/coverage-final.json
npx slnodejs uploadReports \
--tokenFile ./sltoken.txt --buildSessionIdFile buildSessionId \
--file junit.xml
npx slnodejs end \
--tokenFile ./sltoken.txt --buildSessionIdFile buildSessionId- name: AVA tests with SeaLights
env:
SL_TOKEN: ${{ secrets.SL_TOKEN }}
ENV: test
run: |
npx slnodejs start --token "$SL_TOKEN" --buildSessionIdFile buildSessionId --testStage "Unit Tests"
npx nyc --reporter=json ./node_modules/.bin/ava --tap | npx tap-xunit > junit.xml
npx slnodejs nycReport --token "$SL_TOKEN" --buildSessionIdFile buildSessionId --report ./coverage/coverage-final.json
npx slnodejs uploadReports --token "$SL_TOKEN" --buildSessionIdFile buildSessionId --file junit.xml
npx slnodejs end --token "$SL_TOKEN" --buildSessionIdFile buildSessionIdParameters
Parameter
Purpose
Last updated
Was this helpful?

