2424 CHROMEDRIVER_CDNURL : https://googlechromelabs.github.io/
2525 CHROMEDRIVER_CDNBINARIESURL : https://storage.googleapis.com/chrome-for-testing-public
2626 CHROME_VALIDATED_VERSION : linux-120.0.6099.71
27+ artifactRetentionDays : 14
2728 # Bump Node memory limit
2829 NODE_OPTIONS : " --max_old_space_size=4096"
2930
3031jobs :
32+ build :
33+ name : Build the SDK
34+ runs-on : ubuntu-latest
35+ steps :
36+ # Install Chrome so the correct version of webdriver can be installed by chromedriver when
37+ # setting up the repo. This must be done to build and execute Auth properly.
38+ - name : install Chrome stable
39+ run : |
40+ npx @puppeteer/browsers install chrome@stable
41+ - uses : actions/checkout@v3
42+ - name : Set up Node (20)
43+ uses : actions/setup-node@v3
44+ with :
45+ node-version : 22.10.0
46+ - name : Test setup and yarn install
47+ run : |
48+ cp config/ci.config.json config/project.json
49+ yarn
50+ - name : yarn build:changed auth
51+ run : yarn build:changed auth
52+ - name : Archive build
53+ if : ${{ !cancelled() }}
54+ run : |
55+ tar -cf build.tar --exclude=.git .
56+ gzip build.tar
57+ - name : Upload build archive
58+ if : ${{ !cancelled() }}
59+ uses : actions/upload-artifact@v3
60+ with :
61+ name : build.tar.gz
62+ path : build.tar.gz
63+ retention-days : ${{ env.artifactRetentionDays }}
64+
3165 test-chrome :
3266 name : Test Auth on Chrome and Node If Changed
3367 runs-on : ubuntu-latest
5690 with :
5791 # This makes Actions fetch all Git history so run-changed script can diff properly.
5892 fetch-depth : 0
93+ - name : Download build archive
94+ uses : actions/download-artifact@v3
95+ with :
96+ name : build.tar.gz
97+ - name : Unzip build artifact
98+ run : tar xf build.tar.gz
5999 - name : Set up Node (20)
60100 uses : actions/setup-node@v3
61101 with :
64104 run : |
65105 cp config/ci.config.json config/project.json
66106 yarn
67- - name : build
68- run : yarn build:changed auth
69107 - name : Run tests on changed packages
70108 run : xvfb-run yarn test:changed auth
71109 test-firefox :
@@ -96,8 +134,12 @@ jobs:
96134 run : |
97135 cp config/ci.config.json config/project.json
98136 yarn
99- - name : build
100- run : yarn build:changed auth
137+ - name : Download build archive
138+ uses : actions/download-artifact@v3
139+ with :
140+ name : build.tar.gz
141+ - name : Unzip build artifact
142+ run : tar xf build.tar.gz
101143 - name : Run tests on auth changed packages
102144 run : xvfb-run yarn test:changed auth
103145 env :
@@ -121,8 +163,12 @@ jobs:
121163 cp config/ci.config.json config/project.json
122164 yarn
123165 npx playwright install webkit
124- - name : build
125- run : yarn build:changed auth
166+ - name : Download build archive
167+ uses : actions/download-artifact@v3
168+ with :
169+ name : build.tar.gz
170+ - name : Unzip build artifact
171+ run : tar xf build.tar.gz
126172 - name : Run tests on changed packages
127173 run : yarn test:changed auth
128174 env :
0 commit comments