mirror of
https://github.com/serverless/serverless.git
synced 2026-01-18 14:58:43 +00:00
Reconfigure Travis with force abort on failure patch
This commit is contained in:
parent
5b106418bd
commit
4d792fa22e
30
.travis.yml
30
.travis.yml
@ -36,6 +36,11 @@ stages:
|
||||
- name: Deploy
|
||||
if: tag =~ ^v\d+\.\d+\.\d+$
|
||||
|
||||
before_script:
|
||||
# Fail build right after first script fail, unfortunately Travis doesn't do that: https://github.com/travis-ci/travis-ci/issues/1066
|
||||
# More info on below: https://www.davidpashley.com/articles/writing-robust-shell-scripts/#idm5413512
|
||||
- set -e
|
||||
|
||||
jobs:
|
||||
include:
|
||||
# In most cases it's best to configure one job per Platform & Node.js version combination
|
||||
@ -45,20 +50,23 @@ jobs:
|
||||
- name: 'Prettier check updated, Lint updated, Unit Tests - Linux - Node.js v12'
|
||||
if: type = pull_request
|
||||
node_js: 12
|
||||
# Combine with '&&' to not continue on fail
|
||||
script: npm run prettier-check-updated && npm run lint-updated && npm test
|
||||
script:
|
||||
- npm run prettier-check-updated
|
||||
- npm run lint-updated
|
||||
- npm test
|
||||
|
||||
# master branch and version tags
|
||||
- name: 'Lint, Unit Tests - Linux - Node.js v12'
|
||||
if: type != pull_request
|
||||
node_js: 12
|
||||
# Combine with '&&' to not continue on fail
|
||||
script: npm run lint && npm test
|
||||
script:
|
||||
- npm run lint
|
||||
- npm test
|
||||
|
||||
- name: 'Unit Tests - Windows - Node.js v12'
|
||||
os: windows
|
||||
node_js: 12
|
||||
before_script:
|
||||
before_install:
|
||||
# Ensure Python 2 in Windows enviroment (Ruby is already preinstalled)
|
||||
- |
|
||||
if [ $TRAVIS_OS_NAME = windows ]
|
||||
@ -69,13 +77,16 @@ jobs:
|
||||
|
||||
- name: 'Isolated Unit Tests, Package Integration Tests - Linux - Node.js v10'
|
||||
node_js: 10
|
||||
# Combine with '&&' to not continue on fail
|
||||
script: npm run test-isolated && npm run integration-test-run-package
|
||||
script:
|
||||
- npm run test-isolated
|
||||
- npm run integration-test-run-package
|
||||
|
||||
- name: 'Unit Tests, Coverage - Linux - Node.js v8'
|
||||
node_js: 8
|
||||
script: npm run coverage
|
||||
after_success: cat ./coverage/lcov.info | ./node_modules/coveralls/bin/coveralls.js && rm -rf ./coverage
|
||||
after_success:
|
||||
- cat ./coverage/lcov.info | ./node_modules/coveralls/bin/coveralls.js
|
||||
- rm -rf ./coverage
|
||||
|
||||
- name: 'Unit Tests - Linux - Node.js v6'
|
||||
node_js: 6
|
||||
@ -89,7 +100,8 @@ jobs:
|
||||
# AWS_SECRET_ACCESS_KEY
|
||||
- secure: Dgaa5XIsA5Vbw/CYQLUAuVVsDX26C8+f1XYGwsbNmFQKbKvM8iy9lGrHlfrT3jftJkJH6re8tP1RjyZjjzLe25KPk4Tps7grNteCyiIIEDsC2aHhiXHD6zNHsItpxYusaFfyQinFWnK4CAYKWb9ZNIwHIDUIB4vq807QGAhYsnoj1Lg/ajWvtEKBwYjEzDz9OjB91lw7lpCnHtmKKw5A+TNIVGpDDZ/jRBqETsPaePtiXC9UTHZQyM3gFoeVXiJw9KSU/gjIx9REihCaWWPbnuQSeIONGGlVWY9V4DTZIsJr9/uwDcbioeXDD3G1ezGtNPPRSNTtq08QlUtE4mEtKea/+ObpllKZCeZGn6AJhMn+uqMIP95FFlqBB55YzRcLZY+Igi/qm/9LJ9RinAhxRVXiwzeQ+BdVA6jshAAzr+7wklux6lZAa0xGw9pgTv7MI4RP2LJ/LMP1ppFsnv9n/qt93Ax1VEwEu3xHZe3VTYL9tbXOPTZutf6fKjUrW7wSSuy637queESjYnnPKSb1vZcPxjSFlyh+GJvxu/3PurF9aqfiBdiorIBre+pQS4lakLtoft5nsbA+4iYUwrXR58qUPVUqQ7a0A0hedOWlp6g9ixLa6nugUP5aobJzR71T8l/IjqpnY2EEd/iINEb0XfUiZtB5zHaqFWejBtmWwCI=
|
||||
script:
|
||||
- npm run integration-test-run-basic && npm run integration-test-run-all
|
||||
- npm run integration-test-run-basic || { npm run integration-test-cleanup; exit 1; }
|
||||
- npm run integration-test-run-all || { npm run integration-test-cleanup; exit 1; }
|
||||
- npm run integration-test-cleanup
|
||||
|
||||
- stage: Deploy
|
||||
|
||||
Loading…
x
Reference in New Issue
Block a user