This repository has been archived by the owner on Oct 1, 2024. It is now read-only.
-
Notifications
You must be signed in to change notification settings - Fork 222
Parallel CI jobs #1705
Merged
Merged
Parallel CI jobs #1705
Changes from 1 commit
Commits
Show all changes
2 commits
Select commit
Hold shift + click to select a range
File filter
Filter by extension
Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,15 +1,10 @@ | ||
name: Node-CI | ||
|
||
on: | ||
push: | ||
branches: [master] | ||
pull_request: | ||
branches: [master] | ||
on: push | ||
|
||
jobs: | ||
node-tests: | ||
node-lint: | ||
runs-on: ubuntu-latest | ||
|
||
strategy: | ||
matrix: | ||
node-version: [10.x, 12.x, 14.x] | ||
|
@@ -39,16 +34,113 @@ jobs: | |
- name: 📦 Install dependencies | ||
run: yarn --production=false --frozen-lockfile | ||
|
||
- name: 🔨 Build | ||
run: yarn build --verbose | ||
|
||
- name: 💅🏼 Lint | ||
run: | | ||
yarn lint | ||
yarn ci:lint-docs | ||
|
||
node-build: | ||
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 wonder if there's a way to re-use all of this duplication :/ 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. Doesn't seem so - actions/starter-workflows#245. I stumbled across the 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. |
||
runs-on: ubuntu-latest | ||
strategy: | ||
matrix: | ||
node-version: [10.x, 12.x, 14.x] | ||
|
||
steps: | ||
- uses: actions/checkout@v2 | ||
name: Checkout | ||
|
||
- uses: actions/setup-node@v1 | ||
name: Use Node.js ${{ matrix.node-version }} | ||
with: | ||
node-version: ${{ matrix.node-version }} | ||
|
||
- name: Get yarn cache directory | ||
id: yarn-cache-get-dir | ||
run: echo "::set-output name=dir::$(yarn cache dir)" | ||
|
||
- uses: actions/cache@v2 | ||
id: yarn-cache | ||
name: Restore yarn cache | ||
with: | ||
path: ${{ steps.yarn-cache-get-dir.outputs.dir }} | ||
key: ${{ runner.os }}-yarn-${{ hashFiles('**/yarn.lock') }} | ||
restore-keys: | | ||
${{ runner.os }}-yarn- | ||
|
||
- name: 📦 Install dependencies | ||
run: yarn --production=false --frozen-lockfile | ||
|
||
- name: 🔨 Build | ||
run: yarn build --verbose | ||
|
||
node-e2e-tests: | ||
runs-on: ubuntu-latest | ||
strategy: | ||
matrix: | ||
node-version: [10.x, 12.x, 14.x] | ||
|
||
steps: | ||
- uses: actions/checkout@v2 | ||
name: Checkout | ||
|
||
- uses: actions/setup-node@v1 | ||
name: Use Node.js ${{ matrix.node-version }} | ||
with: | ||
node-version: ${{ matrix.node-version }} | ||
|
||
- name: Get yarn cache directory | ||
id: yarn-cache-get-dir | ||
run: echo "::set-output name=dir::$(yarn cache dir)" | ||
|
||
- uses: actions/cache@v2 | ||
id: yarn-cache | ||
name: Restore yarn cache | ||
with: | ||
path: ${{ steps.yarn-cache-get-dir.outputs.dir }} | ||
key: ${{ runner.os }}-yarn-${{ hashFiles('**/yarn.lock') }} | ||
restore-keys: | | ||
${{ runner.os }}-yarn- | ||
|
||
- name: 📦 Install dependencies | ||
run: yarn --production=false --frozen-lockfile | ||
|
||
- name: 🔨 Build | ||
run: yarn build --verbose | ||
|
||
- name: E2E tests | ||
run: yarn test:ci --testPathPattern react-server address | ||
|
||
node-unit-tests: | ||
runs-on: ubuntu-latest | ||
|
||
strategy: | ||
matrix: | ||
node-version: [10.x, 12.x, 14.x] | ||
|
||
steps: | ||
- uses: actions/checkout@v2 | ||
name: Checkout | ||
|
||
- uses: actions/setup-node@v1 | ||
name: Use Node.js ${{ matrix.node-version }} | ||
with: | ||
node-version: ${{ matrix.node-version }} | ||
|
||
- name: Get yarn cache directory | ||
id: yarn-cache-get-dir | ||
run: echo "::set-output name=dir::$(yarn cache dir)" | ||
|
||
- uses: actions/cache@v2 | ||
id: yarn-cache | ||
name: Restore yarn cache | ||
with: | ||
path: ${{ steps.yarn-cache-get-dir.outputs.dir }} | ||
key: ${{ runner.os }}-yarn-${{ hashFiles('**/yarn.lock') }} | ||
restore-keys: | | ||
${{ runner.os }}-yarn- | ||
|
||
- name: 📦 Install dependencies | ||
run: yarn --production=false --frozen-lockfile | ||
|
||
- name: Unit tests | ||
run: yarn test:ci --testPathIgnorePatterns react-server address |
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
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.
This was previously setup just to run CI on pushes to master, not sure why. It now runs CI on all pushes to this repo.