Skip to content

Commit

Permalink
fix(ci): coverage reporting
Browse files Browse the repository at this point in the history
  • Loading branch information
cameri committed Oct 30, 2022
1 parent 1506afb commit e9f33c8
Show file tree
Hide file tree
Showing 5 changed files with 10 additions and 10 deletions.
1 change: 0 additions & 1 deletion .dockerignore
Original file line number Diff line number Diff line change
Expand Up @@ -7,7 +7,6 @@ seeds
test
!test/integration
.eslint*
.mocha*
.nvmrc
.nyc_output
docker-compose.yml
Expand Down
1 change: 1 addition & 0 deletions .github/workflows/checks.yml
Original file line number Diff line number Diff line change
Expand Up @@ -57,6 +57,7 @@ jobs:
test-integrations-and-cover:
name: Integration Tests and Coverage
runs-on: ubuntu-latest
environment: test
needs:
- lint
- build-check
Expand Down
2 changes: 1 addition & 1 deletion Dockerfile.test
Original file line number Diff line number Diff line change
Expand Up @@ -10,7 +10,7 @@ ENV DB_MAX_POOL_SIZE=2

WORKDIR /code

COPY ["package.json", "package-lock.json", "cucumber.js", "tsconfig.json", "knexfile.js", "./"]
COPY ["package.json", "package-lock.json", ".nycrc.json", ".mocharc.js", "cucumber.js", "tsconfig.json", "knexfile.js", "./"]

RUN npm install --quiet

Expand Down
1 change: 1 addition & 0 deletions cucumber.js
Original file line number Diff line number Diff line change
Expand Up @@ -3,6 +3,7 @@ const base = [
'--require-module ts-node/register',
'--require test/integration/features/**/*.ts',
'--require test/integration/features/*.ts',
'--publish-quiet',
].join(' ')

const config = [
Expand Down
15 changes: 7 additions & 8 deletions package.json
Original file line number Diff line number Diff line change
Expand Up @@ -30,21 +30,20 @@
"pretest:unit": "mkdir -p .test-reports/unit",
"test:unit": "mocha 'test/**/*.spec.ts'",
"test:unit:watch": "npm run test:unit -- --min --watch --watch-files src/**/*,test/**/*",
"cover:unit": "nyc --report-dir .coverage/unit npm run --ignore-scripts test:unit",
"cover:unit": "nyc --report-dir .coverage/unit npm run test:unit",
"docker:build": "docker build -t nostr-ts-relay .",
"pretest:integration": "mkdir -p .test-reports/integration",
"test:integration": "cucumber-js",
"cover:integration": "nyc --report-dir .coverage/integration npm run --ignore-scripts test:integration",
"cover:integration": "nyc --report-dir .coverage/integration npm run test:integration -- -p cover",
"predocker:compose:up": "[ -d \"$HOME/.nostr\" ] || mkdir -p $HOME/.nostr",
"docker:compose:start": "docker compose up --build",
"docker:compose:stop": "docker compose down",
"docker:compose:clean": "docker compose rm",
"predocker:test:integration": "docker compose -f ./test/integration/docker-compose.yml up -d --quiet-pull --build",
"docker:test:integration": "docker compose -f ./test/integration/docker-compose.yml run tests npm run test:integration",
"postdocker:test:integration": "docker compose -f ./test/integration/docker-compose.yml down",
"predocker:cover:integration": "docker compose -f ./test/integration/docker-compose.yml up -d --quiet-pull --build",
"docker:cover:integration": "docker compose -f ./test/integration/docker-compose.yml run tests npm run cover:integration",
"postdocker:cover:integration": "docker compose -f ./test/integration/docker-compose.yml down"
"predocker:integration:run": "docker compose -f ./test/integration/docker-compose.yml up -d --quiet-pull --build",
"docker:integration:run": "docker compose -f ./test/integration/docker-compose.yml run tests",
"postdocker:integration:run": "docker compose -f ./test/integration/docker-compose.yml down",
"docker:test:integration": "npm run docker:integration:run -- npm run test:integration",
"docker:cover:integration": "npm run docker:integration:run -- npm run cover:integration"
},
"repository": {
"type": "git",
Expand Down

0 comments on commit e9f33c8

Please sign in to comment.