Skip to content

Commit

Permalink
Merge pull request #422 from ianwalter/fix-skipped-log
Browse files Browse the repository at this point in the history
Fix #420: Dont show skipped tests when running with the --failed flag
  • Loading branch information
ianwalter committed Jun 4, 2021
2 parents a85dc2b + d9419c1 commit ddaf87c
Show file tree
Hide file tree
Showing 4 changed files with 12 additions and 12 deletions.
6 changes: 3 additions & 3 deletions .github/workflows/ci.yml
Original file line number Diff line number Diff line change
Expand Up @@ -28,10 +28,10 @@ jobs:
- name: Lint
run: yarn lint
- name: Test bff
run: cd packages/bff; yarn test:ci
run: cd packages/bff; yarn test.ci
# TODO:
# - name: Test bff-webdriver
# run: npm run test:webdriver
# run: npm run test.webdriver
playwright:
runs-on: ubuntu-latest
container:
Expand All @@ -43,4 +43,4 @@ jobs:
- name: Install
run: yarn
- name: Test bff
run: yarn test:playwright
run: yarn test.playwright
12 changes: 6 additions & 6 deletions package.json
Original file line number Diff line number Diff line change
Expand Up @@ -5,12 +5,12 @@
"license": "SEE LICENSE IN LICENSE",
"scripts": {
"lint": "eslit",
"test:bff": "npm run --prefix packages/bff test:ci",
"test:webdriver": "npm run --prefix packages/bff-webdriver test",
"test:puppeteer": "npm run --prefix packages/bff-puppeteer test",
"test:playwright": "npm run --prefix packages/bff-playwright test",
"docs:dev": "vuepress dev docs",
"docs:build": "vuepress build docs"
"test.bff": "npm run --prefix packages/bff test.ci",
"test.webdriver": "npm run --prefix packages/bff-webdriver test",
"test.puppeteer": "npm run --prefix packages/bff-puppeteer test",
"test.playwright": "npm run --prefix packages/bff-playwright test",
"docs.dev": "vuepress dev docs",
"docs.build": "vuepress build docs"
},
"workspaces": [
"packages/*"
Expand Down
2 changes: 1 addition & 1 deletion packages/bff/index.js
Original file line number Diff line number Diff line change
Expand Up @@ -192,7 +192,7 @@ export async function run (config) {
snapshotState.markSnapshotsAsCheckedForTest(test.name)

const skipViaOnly = hasOnly && !test.only
if (skipViaOnly || test.skip) {
if ((skipViaOnly || test.skip) && !failed) {
// Output the test name and increment the skip count to remind
// the user that some tests are being explicitly skipped.
const msg = `${context.testsRun + 1}. ${test.name}`
Expand Down
4 changes: 2 additions & 2 deletions packages/bff/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -7,8 +7,8 @@
"module": "index.js",
"scripts": {
"test": "./cli.js",
"test:ci": "./cli.js -V tests/bff.js",
"test:out": "./cli.js tests/stdout.js | wc -c"
"test.ci": "./cli.js -V tests/bff.js",
"test.out": "./cli.js tests/stdout.js | wc -c"
},
"bin": {
"bff": "cli.js"
Expand Down

0 comments on commit ddaf87c

Please sign in to comment.