Skip to content
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.

Commit 7ad3999

Browse files
committedOct 31, 2024·
archive dist/ dirs only
1 parent cc58f7d commit 7ad3999

File tree

1 file changed

+43
-7
lines changed

1 file changed

+43
-7
lines changed
 

‎.github/workflows/build.yaml

+43-7
Original file line numberDiff line numberDiff line change
@@ -49,21 +49,57 @@ jobs:
4949
- name: install Chrome stable
5050
run: |
5151
npx @puppeteer/browsers install chrome@stable
52-
- name: Test setup and yarn install
52+
- name: Test setup
5353
run: |
5454
cp config/ci.config.json config/project.json
55-
yarn
5655
- name: yarn build
5756
run: yarn build
5857
- name: Archive build
5958
if: ${{ !cancelled() }}
6059
run: |
61-
tar -cf build.tar --exclude=.git .
62-
gzip build.tar
60+
tar -czvf dists.tar.gz $(find packages -name dist -type d)
6361
- name: Upload build archive
6462
if: ${{ !cancelled() }}
6563
uses: actions/upload-artifact@v4
6664
with:
67-
name: build.tar.gz
68-
path: build.tar.gz
69-
retention-days: ${{ env.artifactRetentionDays }}
65+
name: dists.tar.gz
66+
path: dists.tar.gz
67+
retention-days: ${{ env.artifactRetentionDays }}
68+
69+
test-the-rest:
70+
name: (bulk) Node.js and Browser (Chrome) Tests
71+
needs: build
72+
runs-on: ubuntu-latest
73+
steps:
74+
# install Chrome first, so the correct version of webdriver can be installed by chromedriver when setting up the repo
75+
- name: install Chrome stable
76+
run: |
77+
npx @puppeteer/browsers install chrome@stable
78+
- name: Download build archive
79+
uses: actions/download-artifact@v4
80+
with:
81+
name: dists.tar.gz
82+
- name: Unzip build artifact
83+
run: tar xf dists.tar.gz
84+
- uses: actions/setup-node@v4
85+
with:
86+
node-version-file: '.nvmrc'
87+
- name: Restore cached node_modules
88+
uses: actions/cache@v4
89+
id: node_modules
90+
with:
91+
path: "**/node_modules"
92+
key: node_modules-${{ runner.arch }}-${{ runner.os }}-${{ hashFiles('yarn.lock') }}
93+
- run: yarn install --frozen-lockfile
94+
- name: Test setup
95+
run: |
96+
cp config/ci.config.json config/project.json
97+
- name: Set start timestamp env var
98+
run: echo "FIREBASE_CI_TEST_START_TIME=$(date +%s)" >> $GITHUB_ENV
99+
- name: Run unit tests
100+
# Ignore auth and firestore since they're handled in their own separate jobs.
101+
run: |
102+
xvfb-run yarn lerna run --ignore '{firebase-messaging-integration-test,@firebase/auth*,@firebase/firestore*,firebase-firestore-integration-test}' test:ci
103+
node scripts/print_test_logs.js
104+
env:
105+
FIREBASE_TOKEN: ${{ secrets.FIREBASE_CLI_TOKEN }}

0 commit comments

Comments
 (0)
Please sign in to comment.