Skip to content

Commit a9e5e80

Browse files
committed
[NO JIRA]: Adding GH Actions
1 parent e70a008 commit a9e5e80

File tree

5 files changed

+130
-85
lines changed

5 files changed

+130
-85
lines changed

.github/workflows/build-brs.yml

Lines changed: 43 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,43 @@
1+
name: Build BRS
2+
3+
on: [push]
4+
5+
jobs:
6+
build:
7+
runs-on: ubuntu-latest
8+
steps:
9+
- uses: actions/checkout@v1
10+
11+
- name: nvm install
12+
shell: bash -l {0}
13+
run: nvm install lts/erbium
14+
15+
- name: Run simple
16+
shell: bash -l {0}
17+
run: |
18+
nvm use lts/erbium
19+
tasks/e2e-simple.sh
20+
21+
- name: Run Installs
22+
shell: bash -l {0}
23+
run: |
24+
nvm use lts/erbium
25+
tasks/e2e-installs.sh
26+
27+
- name: Run Kitchensink
28+
shell: bash -l {0}
29+
run: |
30+
nvm use lts/erbium
31+
tasks/e2e-kitchensink.sh
32+
33+
# - name: Run Kitchensink Eject
34+
# shell: bash -l {0}
35+
# run: |
36+
# nvm use lts/erbium
37+
# tasks/e2e-kitchensink-eject.sh
38+
39+
# - name: Run Behaviour
40+
# shell: bash -l {0}
41+
# run: |
42+
# nvm use lts/erbium
43+
# tasks/e2e-behavior.sh

.github/workflows/build.yml

Lines changed: 11 additions & 11 deletions
Original file line numberDiff line numberDiff line change
@@ -1,13 +1,13 @@
1-
name: Build
1+
# name: Build
22

3-
on: [push]
3+
# on: [push]
44

5-
jobs:
6-
build:
7-
runs-on: ubuntu-latest
8-
steps:
9-
- uses: actions/checkout@v1
10-
- name: Install
11-
run: yarn --no-progress --non-interactive --no-lockfile
12-
- name: Build
13-
run: yarn build
5+
# jobs:
6+
# build:
7+
# runs-on: ubuntu-latest
8+
# steps:
9+
# - uses: actions/checkout@v1
10+
# - name: Install
11+
# run: yarn --no-progress --non-interactive --no-lockfile
12+
# - name: Build
13+
# run: yarn build

.github/workflows/lint.yml

Lines changed: 11 additions & 11 deletions
Original file line numberDiff line numberDiff line change
@@ -1,13 +1,13 @@
1-
name: Lint
1+
# name: Lint
22

3-
on: [push]
3+
# on: [push]
44

5-
jobs:
6-
lint:
7-
runs-on: ubuntu-latest
8-
steps:
9-
- uses: actions/checkout@v1
10-
- name: Install
11-
run: yarn --no-progress --non-interactive --no-lockfile
12-
- name: Alex
13-
run: yarn alex
5+
# jobs:
6+
# lint:
7+
# runs-on: ubuntu-latest
8+
# steps:
9+
# - uses: actions/checkout@v1
10+
# - name: Install
11+
# run: yarn --no-progress --non-interactive --no-lockfile
12+
# - name: Alex
13+
# run: yarn alex

.travis.yml

Lines changed: 33 additions & 33 deletions
Original file line numberDiff line numberDiff line change
@@ -1,33 +1,33 @@
1-
---
2-
dist: trusty
3-
language: node_js
4-
node_js:
5-
- 10
6-
- 12
7-
cache:
8-
yarn: true
9-
directories:
10-
- .npm
11-
before_install:
12-
- curl -o- -L https://yarnpkg.com/install.sh | bash -s
13-
- export PATH="$HOME/.yarn/bin:$PATH"
14-
install: true
15-
script:
16-
- 'if [ $TEST_SUITE = "simple" ]; then tasks/e2e-simple.sh; fi'
17-
- 'if [ $TEST_SUITE = "installs" ]; then tasks/e2e-installs.sh; fi'
18-
- 'if [ $TEST_SUITE = "kitchensink" ]; then tasks/e2e-kitchensink.sh; fi'
19-
- 'if [ $TEST_SUITE = "kitchensink-eject" ]; then tasks/e2e-kitchensink-eject.sh; fi'
20-
- 'if [ $TEST_SUITE = "old-node" ]; then tasks/e2e-old-node.sh; fi'
21-
- 'if [ $TEST_SUITE = "behavior" ]; then tasks/e2e-behavior.sh; fi'
22-
env:
23-
matrix:
24-
- TEST_SUITE=simple
25-
- TEST_SUITE=installs
26-
- TEST_SUITE=kitchensink
27-
# - TEST_SUITE=kitchensink-eject
28-
# - TEST_SUITE=behavior
29-
matrix:
30-
include:
31-
- os: osx
32-
node_js: 10
33-
env: TEST_SUITE=behavior
1+
# ---
2+
# dist: trusty
3+
# language: node_js
4+
# node_js:
5+
# - 10
6+
# - 12
7+
# cache:
8+
# yarn: true
9+
# directories:
10+
# - .npm
11+
# before_install:
12+
# - curl -o- -L https://yarnpkg.com/install.sh | bash -s
13+
# - export PATH="$HOME/.yarn/bin:$PATH"
14+
# install: true
15+
# script:
16+
# - 'if [ $TEST_SUITE = "simple" ]; then tasks/e2e-simple.sh; fi'
17+
# - 'if [ $TEST_SUITE = "installs" ]; then tasks/e2e-installs.sh; fi'
18+
# - 'if [ $TEST_SUITE = "kitchensink" ]; then tasks/e2e-kitchensink.sh; fi'
19+
# - 'if [ $TEST_SUITE = "kitchensink-eject" ]; then tasks/e2e-kitchensink-eject.sh; fi'
20+
# - 'if [ $TEST_SUITE = "old-node" ]; then tasks/e2e-old-node.sh; fi'
21+
# - 'if [ $TEST_SUITE = "behavior" ]; then tasks/e2e-behavior.sh; fi'
22+
# env:
23+
# matrix:
24+
# - TEST_SUITE=simple
25+
# - TEST_SUITE=installs
26+
# - TEST_SUITE=kitchensink
27+
# # - TEST_SUITE=kitchensink-eject
28+
# # - TEST_SUITE=behavior
29+
# matrix:
30+
# include:
31+
# - os: osx
32+
# node_js: 10
33+
# env: TEST_SUITE=behavior

tasks/e2e-installs.sh

Lines changed: 32 additions & 30 deletions
Original file line numberDiff line numberDiff line change
@@ -143,53 +143,55 @@ cd test-use-npm-flag
143143
# Check corresponding scripts version is installed.
144144
exists node_modules/@skyscanner/backpack-react-scripts
145145
[ ! -e "yarn.lock" ] && echo "yarn.lock correctly does not exist"
146-
grep '"version": "8.0.2"' node_modules/@skyscanner/backpack-react-scripts/package.json
146+
grep '"version": "8.0.4"' node_modules/@skyscanner/backpack-react-scripts/package.json
147147
checkDependencies
148148

149149
# ******************************************************************************
150150
# Test --typescript flag
151151
# ******************************************************************************
152152

153-
cd "$temp_app_path"
154-
npx create-react-app test-app-typescript --typescript
155-
cd test-app-typescript
156-
157-
# Check corresponding template is installed.
158-
exists node_modules/react-scripts
159-
exists node_modules/typescript
160-
exists src/index.tsx
161-
exists tsconfig.json
162-
exists src/react-app-env.d.ts
163-
checkTypeScriptDependencies
164-
165-
# Check that the TypeScript template passes smoke tests, build, and normal tests
166-
yarn start --smoke-test
167-
yarn build
168-
CI=true yarn test
153+
# TEMP: Removed this as we don't support TS currently in Backpack so not important and not worth the failing builds for.
169154

170-
# Check eject behaves and works
155+
# cd "$temp_app_path"
156+
# npx create-react-app test-app-typescript --template typescript
157+
# cd test-app-typescript
171158

172-
# Eject...
173-
echo yes | npm run eject
159+
# # Check corresponding template is installed.
160+
# exists node_modules/react-scripts
161+
# exists node_modules/typescript
162+
# exists src/index.tsx
163+
# exists tsconfig.json
164+
# exists src/react-app-env.d.ts
165+
# checkTypeScriptDependencies
174166

175-
# Temporary workaround for https://github.com/facebook/create-react-app/issues/6099
176-
rm yarn.lock
177-
yarn add @babel/plugin-transform-react-jsx-source @babel/plugin-syntax-jsx @babel/plugin-transform-react-jsx @babel/plugin-transform-react-jsx-self @babel/helper-create-regexp-features-plugin
167+
# # Check that the TypeScript template passes smoke tests, build, and normal tests
168+
# yarn start --smoke-test
169+
# yarn build
170+
# CI=true yarn test
178171

179-
# Ensure env file still exists
180-
exists src/react-app-env.d.ts
172+
# # Check eject behaves and works
181173

182-
# Check that the TypeScript template passes ejected smoke tests, build, and normal tests
183-
yarn start --smoke-test
184-
yarn build
185-
CI=true yarn test
174+
# # Eject...
175+
# echo yes | npm run eject
176+
177+
# # Temporary workaround for https://github.com/facebook/create-react-app/issues/6099
178+
# rm yarn.lock
179+
# yarn add @babel/plugin-transform-react-jsx-source @babel/plugin-syntax-jsx @babel/plugin-transform-react-jsx @babel/plugin-transform-react-jsx-self @babel/helper-create-regexp-features-plugin
180+
181+
# # Ensure env file still exists
182+
# exists src/react-app-env.d.ts
183+
184+
# # Check that the TypeScript template passes ejected smoke tests, build, and normal tests
185+
# yarn start --smoke-test
186+
# yarn build
187+
# CI=true yarn test
186188

187189
# ******************************************************************************
188190
# Test --scripts-version with a tarball url
189191
# ******************************************************************************
190192

191193
cd "$temp_app_path"
192-
npx create-react-app test-app-tarball-url --scripts-version=https://registry.npmjs.org/@skyscanner/backpack-react-scripts/-/backpack-react-scripts-8.0.1.tgz
194+
npx create-react-app test-app-tarball-url --scripts-version=https://registry.npmjs.org/@skyscanner/backpack-react-scripts/-/backpack-react-scripts-8.0.1.tgz --template @skyscanner/backpack
193195
cd test-app-tarball-url
194196

195197
# Check corresponding scripts version is installed.

0 commit comments

Comments
 (0)