-
Notifications
You must be signed in to change notification settings - Fork 12.4k
tests: use stages for the travis execution #967
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. Weβll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Changes from 4 commits
0f1286e
b46e610
825c5aa
5354379
bc4a09c
62b6b4d
49005b8
91b16b2
046eb0c
114a16c
8b47d98
545668e
43aea24
e194ac2
2354495
File filter
Filter by extension
Conversations
Jump to
Diff view
Diff view
There are no files selected for viewing
| Original file line number | Diff line number | Diff line change |
|---|---|---|
|
|
@@ -4,24 +4,37 @@ group: beta | |
| language: node_js | ||
| node_js: | ||
| - "8" | ||
|
|
||
| cache: | ||
| directories: | ||
| - node_modules | ||
| env: | ||
| - | ||
| - SOLIDITY_COVERAGE=true | ||
| - SOLC_NIGHTLY=true | ||
| matrix: | ||
|
|
||
| jobs: | ||
| # XXX fast_finish doesn't work with stages yet. See | ||
| # https://github.com/travis-ci/travis-ci/issues/8425 | ||
| # --elopio - 20180531 | ||
| fast_finish: true | ||
| allow_failures: | ||
| - env: SOLIDITY_COVERAGE=true | ||
| - env: SOLC_NIGHTLY=true | ||
| before_script: | ||
| - truffle version | ||
| script: | ||
| - npm run lint | ||
| - npm run lint:sol | ||
| - npm run test | ||
| include: | ||
| # Run the unit test suite three times in parallel. | ||
| # The first one gets results faster and is the only one required to pass. | ||
| # The second one generates the coverage report. | ||
| # The third one is to keep us informed about possible issues with the | ||
| # upcoming solidity release. | ||
| - stage: unit | ||
| script: npm run test | ||
| - stage: unit | ||
| script: npm run test | ||
| env: SOLIDITY_COVERAGE=true | ||
| - stage: unit | ||
| script: npm run test | ||
| env: SOLC_NIGHTLY=true | ||
|
Contributor
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. I'd add a short comment explaining we're running 3 jobs in the unit stage, since Travis' syntax for this is so obscure.
Author
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. Thanks for the review @nventuro! |
||
| # solidity and javascript style tests. | ||
| - stage: static | ||
|
||
| script: npm run lint | ||
|
|
||
| notifications: | ||
| slack: | ||
| rooms: | ||
|
|
||
| Original file line number | Diff line number | Diff line change |
|---|---|---|
|
|
@@ -8,12 +8,12 @@ | |
| ], | ||
| "scripts": { | ||
| "test": "scripts/test.sh", | ||
| "lint": "eslint .", | ||
| "lint:fix": "eslint . --fix", | ||
| "lint:js": "eslint .", | ||
|
Contributor
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. Yay! This was in my mind too.
Contributor
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. If we put this PR on hold we should still do this now. |
||
| "lint:js:fix": "eslint . --fix", | ||
| "lint:sol": "solium -d .", | ||
| "lint:sol:fix": "solium -d . --fix", | ||
| "lint:all": "npm run lint && npm run lint:sol", | ||
| "lint:all:fix": "npm run lint:fix && npm run lint:sol:fix", | ||
| "lint": "npm run lint:js && npm run lint:sol", | ||
| "lint:fix": "npm run lint:js:fix && npm run lint:sol:fix", | ||
| "console": "truffle console", | ||
| "coverage": "scripts/coverage.sh", | ||
| "version": "scripts/version.js" | ||
|
|
||
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
How about "Unit tests" for the stage name?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
sounds good.