Skip to content

Commit

Permalink
move swc post install libs into runtest yaml file
Browse files Browse the repository at this point in the history
  • Loading branch information
jesuyedavid committed Feb 14, 2024
1 parent 58e4a84 commit 6bb06d4
Show file tree
Hide file tree
Showing 2 changed files with 23 additions and 39 deletions.
39 changes: 0 additions & 39 deletions .github/workflows/new-run-tests.yml

This file was deleted.

23 changes: 23 additions & 0 deletions .github/workflows/run-tests.yml
Original file line number Diff line number Diff line change
Expand Up @@ -22,6 +22,15 @@ jobs:
react-dom@^17.0.2 \
@testing-library/react@^12.1.3 \
@testing-library/react-hooks@^8.0.0
npm install --save-optional \
"@swc/core-linux-arm-gnueabihf" \
"@swc/core-linux-arm64-gnu" \
"@swc/core-linux-arm64-musl" \
"@swc/core-linux-x64-gnu" \
"@swc/core-linux-x64-musl" \
"@swc/core-win32-arm64-msvc" \
"@swc/core-win32-ia32-msvc" \
"@swc/core-win32-x64-msvc"
npm run build
node_matrix: '["16.x", "18.x"]'
secrets:
Expand All @@ -30,12 +39,26 @@ jobs:
call_run_tests-react-16:
uses: yext/slapshot-reusable-workflows/.github/workflows/run_tests.yml@v1
with:
# We have to install the swc libraries manually because
# the post install script doesn't seem to run properly
# after we install specific versions of react and react-dom
# more info at - https://github.com/swc-project/swc/issues/5616#issuecomment-1651214641

build_script: |
npm i \
react@^16.14 \
react-dom@^16.14 \
@testing-library/react@^12.1.3 \
@testing-library/react-hooks@^8.0.0
npm install --save-optional \
"@swc/core-linux-arm-gnueabihf" \
"@swc/core-linux-arm64-gnu" \
"@swc/core-linux-arm64-musl" \
"@swc/core-linux-x64-gnu" \
"@swc/core-linux-x64-musl" \
"@swc/core-win32-arm64-msvc" \
"@swc/core-win32-ia32-msvc" \
"@swc/core-win32-x64-msvc"
npm run build
node_matrix: '["16.x", "18.x"]'
secrets:
Expand Down

0 comments on commit 6bb06d4

Please sign in to comment.