File tree Expand file tree Collapse file tree 4 files changed +44
-0
lines changed Expand file tree Collapse file tree 4 files changed +44
-0
lines changed Original file line number Diff line number Diff line change 1+ name : CI
2+
3+ on :
4+ push :
5+ branches : [main, next, workflow]
6+ pull_request :
7+ branches : [main, next]
8+
9+ jobs :
10+ install :
11+ runs-on : ubuntu-latest
12+ steps :
13+ - uses : actions/checkout@v3
14+ - name : Install yarn (required locally)
15+ run : npm install --global yarn
16+ - uses : actions/setup-node@v3
17+ with :
18+ node-version : " 22"
19+ cache : " yarn"
20+ - name : Install dependencies
21+ run : yarn install --frozen-lockfile
22+
23+ run-unit-tests :
24+ runs-on : ubuntu-latest
25+ needs : install
26+ steps :
27+ - uses : actions/checkout@v3
28+ - name : Install dependencies
29+ run : yarn install --frozen-lockfile
30+ - name : Run unit tests
31+ run : yarn test:ci
32+ - uses : actions/upload-artifact@v4
33+ with :
34+ name : test-results-unit-tests
35+ path : test-result-unit.json
36+ 37+ if : ${{ github.event_name != 'pull_request' || github.event.pull_request.head.repo.full_name == github.repository }}
38+ with :
39+ name : test-results / unit-tests
40+ path : test-result-unit.json
41+ reporter : mocha-json
Original file line number Diff line number Diff line change 11* .sublime-project
22* .sublime-workspace
3+ test * .json
34.DS_STORE
45/.nyc_output
56dev
Original file line number Diff line number Diff line change @@ -17,3 +17,4 @@ Thumbs.db
1717tsconfig.json
1818webpack.config.js
1919yarn-error.log
20+ .github
Original file line number Diff line number Diff line change 2323 "scripts" : {
2424 "dist" : " rm -rf dist; tsdown -f esm -f cjs -f iife --minify; mv dist/index.iife.js dist/jsonPointer.js" ,
2525 "test" : " TS_NODE_PROJECT=./test/tsconfig.json mocha 'test/**/*.test.ts'" ,
26+ "test:ci" : " TS_NODE_PROJECT=./test/tsconfig.json DISABLE_LOG=true mocha -R json 'test/**/*.test.ts' > test-result-unit.json; exit 0" ,
2627 "prepublishOnly" : " yarn test && yarn dist" ,
2728 "lint" : " eslint lib && tsc" ,
2829 "coverage" : " nyc yarn test"
You can’t perform that action at this time.
0 commit comments