forked from facebook/create-react-app
-
Notifications
You must be signed in to change notification settings - Fork 3
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Migrate from Azure Pipelines to GitHub Actions (facebook#13222)
Beyond just a pure migration, this also: - Drops Node 14 usage from CI (which also removes the need for explicit npm 8 installs) - Removes the "old node" test, which just checked that installing on old node failed. We shouldn't need to test that - Consolidates the build & test workflows so we don't end up with a proliferation of workflows.
- Loading branch information
Showing
8 changed files
with
115 additions
and
177 deletions.
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 |
---|---|---|
@@ -0,0 +1,76 @@ | ||
name: 'Build & Test' | ||
|
||
on: | ||
push: | ||
branches: | ||
- main | ||
pull_request: | ||
branches: | ||
- main | ||
|
||
jobs: | ||
build: | ||
name: 'Build (${{ matrix.os }}, Node ${{ matrix.node }})' | ||
runs-on: ${{ matrix.os }} | ||
strategy: | ||
fail-fast: false | ||
matrix: | ||
os: | ||
- 'ubuntu-latest' | ||
node: | ||
- '16' | ||
steps: | ||
- uses: actions/checkout@v3 | ||
- uses: actions/setup-node@v3 | ||
with: | ||
node-version: ${{ matrix.node }} | ||
cache: 'npm' | ||
- name: Install dependencies | ||
run: npm ci --prefer-offline | ||
- name: Build | ||
run: npm run build | ||
|
||
integration: | ||
name: 'Integration Tests (${{ matrix.os }}, Node ${{ matrix.node }})' | ||
runs-on: ${{ matrix.os }} | ||
strategy: | ||
fail-fast: false | ||
matrix: | ||
os: | ||
- 'ubuntu-latest' | ||
- 'macos-latest' | ||
- 'windows-latest' | ||
node: | ||
- '16' | ||
steps: | ||
- uses: actions/checkout@v3 | ||
- name: Setup node | ||
uses: actions/setup-node@v3 | ||
with: | ||
node-version: ${{ matrix.node }} | ||
cache: 'npm' | ||
- name: Install dependencies | ||
run: npm ci --prefer-offline | ||
# The integration tests are run with yarn, so we need to install it. | ||
- name: Install yarn | ||
run: npm i -g yarn | ||
- name: Run integration tests | ||
run: npm run test:integration | ||
|
||
e2e-simple: | ||
name: E2E Simple | ||
uses: ./.github/workflows/e2e-base.yml | ||
with: | ||
testScript: 'tasks/e2e-simple.sh' | ||
|
||
e2e-installs: | ||
name: E2E Installs | ||
uses: ./.github/workflows/e2e-base.yml | ||
with: | ||
testScript: 'tasks/e2e-installs.sh' | ||
|
||
e2e-kitchensink: | ||
name: E2E Kitchensink | ||
uses: ./.github/workflows/e2e-base.yml | ||
with: | ||
testScript: 'tasks/e2e-kitchensink.sh' |
This file was deleted.
Oops, something went wrong.
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 |
---|---|---|
@@ -0,0 +1,35 @@ | ||
on: | ||
workflow_call: | ||
inputs: | ||
testScript: | ||
required: true | ||
type: string | ||
|
||
name: E2E | ||
|
||
jobs: | ||
test: | ||
name: 'Test (${{ matrix.os }}, Node ${{ matrix.node }})' | ||
runs-on: ${{ matrix.os }} | ||
strategy: | ||
fail-fast: false | ||
matrix: | ||
os: | ||
- 'ubuntu-latest' | ||
node: | ||
- '16' | ||
steps: | ||
- uses: actions/checkout@v3 | ||
- uses: actions/setup-node@v3 | ||
with: | ||
node-version: ${{ matrix.node }} | ||
cache: 'npm' | ||
- name: Install | ||
run: npm ci --prefer-offline | ||
- name: Initialize Global Git config | ||
run: | | ||
git config --global core.autocrlf false | ||
git config --global user.name "Create React App" | ||
git config --global user.email "[email protected]" | ||
- name: Run tests | ||
run: ${{ inputs.testScript }} |
This file was deleted.
Oops, something went wrong.
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
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
This file was deleted.
Oops, something went wrong.
This file was deleted.
Oops, something went wrong.