2020-08-26 11:17:29 +00:00
|
|
|
name: windows
|
|
|
|
|
|
|
|
on:
|
|
|
|
push:
|
|
|
|
branches:
|
|
|
|
- dev
|
|
|
|
- 2.x
|
|
|
|
pull_request:
|
|
|
|
branches:
|
|
|
|
- dev
|
|
|
|
- 2.x
|
|
|
|
|
|
|
|
jobs:
|
|
|
|
setup:
|
|
|
|
runs-on: ${{ matrix.os }}
|
|
|
|
if: github.event_name == 'push' || !((github.base_ref == '2.x') && github.head_ref == 'dev')
|
|
|
|
|
|
|
|
strategy:
|
|
|
|
matrix:
|
|
|
|
os: [windows-latest]
|
2021-02-13 10:56:38 +00:00
|
|
|
node: [14]
|
2020-08-26 11:17:29 +00:00
|
|
|
|
|
|
|
steps:
|
2020-12-16 13:44:37 +00:00
|
|
|
- uses: actions/setup-node@v2
|
2020-08-26 11:17:29 +00:00
|
|
|
with:
|
|
|
|
node-version: ${{ matrix.node }}
|
|
|
|
|
|
|
|
- name: checkout
|
|
|
|
uses: actions/checkout@v2
|
|
|
|
|
|
|
|
- name: cache node_modules
|
|
|
|
id: node_modules_cache_id
|
2020-10-29 22:31:28 +00:00
|
|
|
uses: actions/cache@v2
|
2020-08-26 11:17:29 +00:00
|
|
|
with:
|
2020-11-04 14:14:46 +00:00
|
|
|
path: |
|
|
|
|
node_modules
|
|
|
|
packages/*/node_modules
|
|
|
|
distributions/*/node_modules
|
2020-08-26 11:17:29 +00:00
|
|
|
key: ${{ matrix.os }}-node-v${{ matrix.node }}-deps-${{ hashFiles(format('{0}{1}', github.workspace, '/yarn.lock')) }}
|
|
|
|
|
|
|
|
- name: install
|
|
|
|
run: yarn --check-files --frozen-lockfile --non-interactive
|
|
|
|
|
|
|
|
- name: cache workspace
|
2020-10-29 22:31:28 +00:00
|
|
|
uses: actions/cache@v2
|
2020-08-26 11:17:29 +00:00
|
|
|
with:
|
2020-10-29 22:31:28 +00:00
|
|
|
path: |
|
|
|
|
node_modules
|
|
|
|
packages/*/node_modules
|
2020-11-04 14:14:46 +00:00
|
|
|
distributions/*/node_modules
|
2020-10-29 22:31:28 +00:00
|
|
|
packages/*/dist
|
2020-08-26 11:17:29 +00:00
|
|
|
key: ${{ matrix.os }}-node-v${{ matrix.node }}-nuxt-${{ github.sha }}
|
|
|
|
|
|
|
|
|
2020-11-04 13:38:38 +00:00
|
|
|
test-unit:
|
|
|
|
runs-on: ${{ matrix.os }}
|
|
|
|
|
|
|
|
strategy:
|
|
|
|
matrix:
|
|
|
|
os: [windows-latest]
|
2021-02-13 11:18:13 +00:00
|
|
|
node: [14]
|
2020-11-04 13:38:38 +00:00
|
|
|
|
|
|
|
env:
|
|
|
|
NODE_OPTIONS: "--max_old_space_size=4096"
|
|
|
|
|
|
|
|
steps:
|
2020-12-16 13:44:37 +00:00
|
|
|
- uses: actions/setup-node@v2
|
2020-11-04 13:38:38 +00:00
|
|
|
with:
|
|
|
|
node-version: ${{ matrix.node }}
|
|
|
|
|
|
|
|
- name: checkout
|
|
|
|
uses: actions/checkout@master
|
|
|
|
|
|
|
|
- name: restore workspace cache
|
|
|
|
uses: actions/cache@v2
|
|
|
|
with:
|
|
|
|
path: |
|
|
|
|
node_modules
|
|
|
|
packages/*/node_modules
|
2020-11-04 14:14:46 +00:00
|
|
|
distributions/*/node_modules
|
2020-11-04 13:38:38 +00:00
|
|
|
packages/*/dist
|
|
|
|
key: ${{ matrix.os }}-node-v${{ matrix.node }}-nuxt-${{ github.sha }}
|
|
|
|
|
|
|
|
- name: test unit
|
|
|
|
run: yarn test:unit --testPathIgnorePatterns=packages/cli
|
|
|
|
|
|
|
|
needs: setup
|
2020-08-26 11:17:29 +00:00
|
|
|
|
|
|
|
build:
|
|
|
|
runs-on: ${{ matrix.os }}
|
|
|
|
|
|
|
|
strategy:
|
|
|
|
matrix:
|
|
|
|
os: [windows-latest]
|
2021-02-13 11:18:13 +00:00
|
|
|
node: [14]
|
2020-08-26 11:17:29 +00:00
|
|
|
|
|
|
|
env:
|
|
|
|
NODE_OPTIONS: "--max_old_space_size=4096"
|
|
|
|
|
|
|
|
steps:
|
2020-12-16 13:44:37 +00:00
|
|
|
- uses: actions/setup-node@v2
|
2020-08-26 11:17:29 +00:00
|
|
|
with:
|
|
|
|
node-version: ${{ matrix.node }}
|
|
|
|
|
|
|
|
- name: checkout
|
|
|
|
uses: actions/checkout@master
|
|
|
|
|
|
|
|
- name: restore workspace cache
|
2020-10-29 22:31:28 +00:00
|
|
|
uses: actions/cache@v2
|
2020-08-26 11:17:29 +00:00
|
|
|
with:
|
2020-10-29 22:31:28 +00:00
|
|
|
path: |
|
|
|
|
node_modules
|
|
|
|
packages/*/node_modules
|
2020-11-04 14:14:46 +00:00
|
|
|
distributions/*/node_modules
|
2020-10-29 22:31:28 +00:00
|
|
|
packages/*/dist
|
2020-08-26 11:17:29 +00:00
|
|
|
key: ${{ matrix.os }}-node-v${{ matrix.node }}-nuxt-${{ github.sha }}
|
|
|
|
|
|
|
|
- name: build
|
2020-11-04 13:38:38 +00:00
|
|
|
run: yarn test:fixtures
|
2020-08-26 11:17:29 +00:00
|
|
|
|
2021-02-07 22:25:51 +00:00
|
|
|
- name: Save fixtures
|
|
|
|
uses: actions/upload-artifact@v2
|
2020-08-26 11:17:29 +00:00
|
|
|
with:
|
2021-02-07 22:25:51 +00:00
|
|
|
name: fixtures-${{ matrix.os }}-node-v${{ matrix.node }}
|
2020-08-26 11:17:29 +00:00
|
|
|
path: test/fixtures
|
|
|
|
needs: setup
|
|
|
|
|
|
|
|
test-dev:
|
|
|
|
runs-on: ${{ matrix.os }}
|
|
|
|
|
|
|
|
strategy:
|
|
|
|
matrix:
|
|
|
|
os: [windows-latest]
|
2021-02-13 11:18:13 +00:00
|
|
|
node: [14]
|
2020-08-26 11:17:29 +00:00
|
|
|
|
|
|
|
env:
|
|
|
|
NODE_OPTIONS: "--max_old_space_size=4096"
|
|
|
|
|
|
|
|
steps:
|
2020-12-16 13:44:37 +00:00
|
|
|
- uses: actions/setup-node@v2
|
2020-08-26 11:17:29 +00:00
|
|
|
with:
|
|
|
|
node-version: ${{ matrix.node }}
|
|
|
|
|
|
|
|
- name: checkout
|
|
|
|
uses: actions/checkout@master
|
|
|
|
|
|
|
|
- name: restore workspace cache
|
2020-10-29 22:31:28 +00:00
|
|
|
uses: actions/cache@v2
|
2020-08-26 11:17:29 +00:00
|
|
|
with:
|
2020-10-29 22:31:28 +00:00
|
|
|
path: |
|
|
|
|
node_modules
|
|
|
|
packages/*/node_modules
|
2020-11-04 14:14:46 +00:00
|
|
|
distributions/*/node_modules
|
2020-10-29 22:31:28 +00:00
|
|
|
packages/*/dist
|
2020-08-26 11:17:29 +00:00
|
|
|
key: ${{ matrix.os }}-node-v${{ matrix.node }}-nuxt-${{ github.sha }}
|
|
|
|
|
|
|
|
- name: restore fixtures
|
2021-02-07 22:25:51 +00:00
|
|
|
uses: actions/download-artifact@v2
|
2020-08-26 11:17:29 +00:00
|
|
|
with:
|
2021-02-07 22:25:51 +00:00
|
|
|
name: fixtures-${{ matrix.os }}-node-v${{ matrix.node }}
|
2020-08-26 11:17:29 +00:00
|
|
|
path: test/fixtures
|
|
|
|
|
|
|
|
- name: test dev
|
2020-11-04 13:38:38 +00:00
|
|
|
run: yarn test:dev
|
2020-08-26 11:17:29 +00:00
|
|
|
needs: build
|