Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Update github workloads #478

Open
wants to merge 5 commits into
base: main
Choose a base branch
from
Open
Show file tree
Hide file tree
Changes from 4 commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
36 changes: 24 additions & 12 deletions .github/workflows/test.yml
Original file line number Diff line number Diff line change
Expand Up @@ -15,15 +15,20 @@ jobs:
runs-on: macos-latest
steps:
- name: Checkout Branch
uses: actions/checkout@v3
uses: actions/checkout@v4

- name: Setup Node
uses: actions/setup-node@v3
uses: actions/setup-node@v4
with:
node-version: 18.13.0
- name: Install
run: npm install
node-version-file: "package.json"
cache: "npm"

- name: Install Node Packages
run: npm ci
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

much better!


- name: Run linters
run: npm run format

- name: Check if anything changed
run: |
git_status="`LC_ALL=C git status --porcelain --ignore-submodules -unormal 2>&1`"
Expand All @@ -35,6 +40,7 @@ jobs:
git diff -U8
exit 1
fi

build:
name: Build
runs-on: macos-latest
Expand All @@ -45,19 +51,25 @@ jobs:
- name: Install Firefox
if: ${{ matrix.browser == 'firefox' }}
run: brew install --cask firefox

- name: Checkout Branch
uses: actions/checkout@v3
uses: actions/checkout@v4

- name: Setup Node
uses: actions/setup-node@v3
uses: actions/setup-node@v4
with:
node-version: 18.13.0
- name: Install
run: npm install
- name: Run tests
node-version-file: "package.json"
cache: "npm"

- name: Install Node Packages
run: npm ci

- name: Run Unit Tests
run: |
echo "Running in $BROWSER"
npm run test:${{ matrix.browser }}
- name: Run end2end

- name: Run end2end Tests
run: |
echo "Running in $BROWSER"
npm run test-e2e:${{ matrix.browser }}
2 changes: 1 addition & 1 deletion package.json
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@
"version": "3.0.0-alpha",
"description": "An open source repository for the Speedometer benchmark.",
"engines": {
"node": ">=18.13.0",
"node": ">=22.0.0",
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

do we want to ensure that we stay on v22 by adding < 23 as well? I'm a bit afraid that this will switch to v24 automatically and we'll get build errors. We can always change that later if this happens of course.

Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I believe you need to run npm i to update package-lock.json as well.

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

ah yeah... of course.
Let me add a CI check for that as well in a separate PR.

Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I think npm ci does it for dependencies, it's disappointing it doesn't work for everything that can update it!

"npm": ">=8.19.3"
},
"repository": {
Expand Down