Skip to content

Commit 1e68152

Browse files
Merge pull request #735 from nodejs/test-travis-ci-config
Test Travis CI config and template consistency
2 parents 7d97c98 + 54b51b3 commit 1e68152

File tree

3 files changed

+20
-3
lines changed

3 files changed

+20
-3
lines changed

.travis.yml

Lines changed: 9 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -58,12 +58,21 @@ jobs:
5858
- TEST: Shell Check
5959
script: shellcheck *.sh
6060

61+
- stage: Test
62+
env:
63+
- TEST: .travis.yml and travis.yml.template consistency
64+
language: generic
65+
script:
66+
- ./update.sh
67+
- git diff --stat --exit-code .travis.yml
68+
6169
- stage: Deploy
6270
script: ./generate-stackbrew-pr.sh
6371
env:
6472
secure: "HkgYgawkr/hkg2vURHGOb/JmF6U1e71QQsd0HXJ1UJh6WBiFJOrjomCMHZGHnpyopdRna++up8dISBqM2X+EiLAr9yWdRXy72oMP9X42M0ccnja/3E5KYYXMkETS50JnUhMCOt2xRZW5/ojqrHukqRo0YIjIu+P0U0VsZ4QIsng="
6573

6674
# Docker Build #
75+
6776
- stage: Build
6877
env:
6978
- NODE_VERSION: "10"

travis.yml.template

Lines changed: 8 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -56,6 +56,14 @@ jobs:
5656
- TEST: Shell Check
5757
script: shellcheck *.sh
5858

59+
- stage: Test
60+
env:
61+
- TEST: .travis.yml and travis.yml.template consistency
62+
language: generic
63+
script:
64+
- ./update.sh
65+
- git diff --stat --exit-code .travis.yml
66+
5967
- stage: Deploy
6068
script: ./generate-stackbrew-pr.sh
6169
env:

update.sh

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -77,11 +77,11 @@ function add_stage() {
7777
local variant=$1
7878
shift
7979

80-
echo ' - stage: Build
80+
echo '
81+
- stage: Build
8182
env:
8283
- NODE_VERSION: "'"$version"'"
83-
- VARIANT: "'"$variant"'"
84-
' >>.travis.yml
84+
- VARIANT: "'"$variant"'"' >>.travis.yml
8585
}
8686

8787
echo '#### DO NOT MODIFY. THIS FILE IS AUTOGENERATED ####

0 commit comments

Comments
 (0)