Skip to content

Commit

Permalink
test(jest): Migrate to jest
Browse files Browse the repository at this point in the history
  • Loading branch information
jcowman2 committed Dec 17, 2018
1 parent 5cc51ab commit 16f1c92
Show file tree
Hide file tree
Showing 8 changed files with 4,972 additions and 2,140 deletions.
6 changes: 3 additions & 3 deletions .circleci/config.yml
Original file line number Diff line number Diff line change
Expand Up @@ -34,9 +34,9 @@ jobs:
# run tests!
- run: npm test

# - run:
# name: Publish Test Coverage
# command: npm run publish-coverage
- run:
name: Publish Test Coverage
command: npm run publish-coverage

# - run:
# name: Check Test Coverage
Expand Down
18 changes: 7 additions & 11 deletions .vscode/launch.json
Original file line number Diff line number Diff line change
Expand Up @@ -2,22 +2,18 @@
"version": "0.2.0",
"configurations": [
{
// Thanks https://medium.com/@benlesh/debugging-typescript-mocha-tests-with-vscode-89310051531
"type": "node",
"request": "launch",
"name": "Mocha All",
"program": "${workspaceFolder}\\node_modules\\mocha\\bin\\_mocha",
"name": "Jest All",
"args": [
"-r",
"ts-node/register",
"--timeout",
"999999",
"--colors",
"${workspaceFolder}\\**\\test\\**\\*.test.ts"
"--inspect-brk",
"${workspaceRoot}/node_modules/jest/bin/jest.js",
"--runInBand",
"--coverage",
"false"
],
"console": "integratedTerminal",
"internalConsoleOptions": "neverOpen",
"protocol": "inspector"
"internalConsoleOptions": "neverOpen"
}
]
}
8 changes: 8 additions & 0 deletions jest.config.js
Original file line number Diff line number Diff line change
@@ -0,0 +1,8 @@
module.exports = {
preset: 'ts-jest',
testEnvironment: 'node',
collectCoverage: true,
collectCoverageFrom: [
"src/**"
]
};
Loading

0 comments on commit 16f1c92

Please sign in to comment.