Skip to content

Commit 7c00d11

Browse files
authored
Merge pull request #30 from denco/feature/run-script-os
feature/run script os
2 parents ecf6ac5 + 9048898 commit 7c00d11

File tree

3 files changed

+22
-6
lines changed

3 files changed

+22
-6
lines changed

.github/workflows/ci.yml

Lines changed: 0 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -26,9 +26,5 @@ jobs:
2626
run: npm ci
2727
- name: Run Linting Checks
2828
run: npm run lint
29-
- name: Run Headless Tests
30-
run: xvfb-run --auto-servernum npm run test
31-
if: runner.os == 'Linux'
3229
- name: Run Tests
3330
run: npm run test
34-
if: runner.os != 'Linux'

npm-shrinkwrap.json

Lines changed: 17 additions & 0 deletions
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

package.json

Lines changed: 5 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -126,7 +126,9 @@
126126
"watch": "tsc -watch -p ./",
127127
"pretest": "npm run clean && npm run compile",
128128
"lint": "eslint --cache=true --ext ts,tsx .",
129-
"test": "node ./out/test/runTest.js",
129+
"test": "run-script-os",
130+
"test:linux": "which xvfb-run >/dev/null 2>&1 && xvfb-run --auto-servernum node ./out/test/runTest.js || npm run test:default",
131+
"test:default": "node ./out/test/runTest.js",
130132
"prepackage": "npm run clean && npm run compile",
131133
"package": "vsce package",
132134
"clean": "rimraf -rf ./out",
@@ -145,6 +147,7 @@
145147
"mocha": "^8.3.2",
146148
"ovsx": "^0.1.0-next.a9154dc",
147149
"rimraf": "^3.0.2",
150+
"run-script-os": "^1.1.5",
148151
"source-map-support": "^0.5.12",
149152
"typescript": "^4.2.3",
150153
"vsce": "^1.66.0",
@@ -176,4 +179,4 @@
176179
"__metadata": {
177180
"publisherDisplayName": "denco"
178181
}
179-
}
182+
}

0 commit comments

Comments
 (0)