Skip to content
This repository has been archived by the owner on Aug 7, 2023. It is now read-only.

Commit

Permalink
Tech: déplace les options de Mocha vers des fichiers de configuration
Browse files Browse the repository at this point in the history
  • Loading branch information
ronnix committed Apr 28, 2022
1 parent f731d34 commit bad3e77
Show file tree
Hide file tree
Showing 4 changed files with 29 additions and 3 deletions.
10 changes: 10 additions & 0 deletions .mocharc-integration-ci.json
Original file line number Diff line number Diff line change
@@ -0,0 +1,10 @@
{
"spec": "src/scripts/tests/integration/",
"require": [
"@babel/register"
],
"timeout": 15000,
"retries": 5,
"bail": true,
"color": true
}
9 changes: 9 additions & 0 deletions .mocharc-integration.json
Original file line number Diff line number Diff line change
@@ -0,0 +1,9 @@
{
"spec": "src/scripts/tests/integration/",
"require": [
"@babel/register"
],
"timeout": 0,
"bail": true,
"color": true
}
7 changes: 7 additions & 0 deletions .mocharc.json
Original file line number Diff line number Diff line change
@@ -0,0 +1,7 @@
{
"spec": "src/scripts/tests/unit/",
"require": [
"@babel/register"
],
"color": true
}
6 changes: 3 additions & 3 deletions package.json
Original file line number Diff line number Diff line change
Expand Up @@ -36,10 +36,10 @@
"timeago.js": "4.0.2"
},
"scripts": {
"test": "mocha --color --require @babel/register src/scripts/tests/unit/",
"test": "mocha",
"test:coverage": "nyc npm run test",
"test-integration": "mocha --color --require @babel/register --bail --timeout 0 src/scripts/tests/integration/",
"test-integration:ci": "mocha --color --require @babel/register --bail --timeout 15000 --retries=5 src/scripts/tests/integration/",
"test-integration": "mocha --config .mocharc-integration.json",
"test-integration:ci": "mocha --config .mocharc-integration-ci.json",
"lint": "eslint --color src/scripts/ src/service-worker.js",
"build": "parcel build src/*.html --detailed-report 20 --experimental-scope-hoisting",
"build-dev": "parcel src/*.html --log-level 3 --open"
Expand Down

0 comments on commit bad3e77

Please sign in to comment.