-
-
Notifications
You must be signed in to change notification settings - Fork 1.4k
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
this mainly fixes some inconsistencies in style, outdated or wrong comments and action version - replace Legit-Labs/action-download-artifact with actions/download-artifact - fix Swatinem/rust-cache arguments - fix benchmark transformations - expand feature soundness lints - wording and capitalization in comments
- Loading branch information
1 parent
73d519e
commit 02d7473
Showing
24 changed files
with
190 additions
and
210 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -11,11 +11,11 @@ on: | |
- "website/**" | ||
types: [labeled, synchronize, opened, reopened] | ||
|
||
permissions: | ||
# deployments permission to deploy GitHub pages website | ||
deployments: write | ||
# contents permission to update benchmark contents in gh-pages branch | ||
contents: write | ||
# Cancel outstanding benchmarks on pull requests | ||
# https://docs.github.com/en/actions/writing-workflows/workflow-syntax-for-github-actions#example-using-a-fallback-value | ||
concurrency: | ||
group: ${{ github.head_ref || github.run_id }} | ||
cancel-in-progress: true | ||
|
||
jobs: | ||
benchmark: | ||
|
@@ -37,39 +37,43 @@ jobs: | |
toolchain: stable | ||
targets: wasm32-unknown-unknown | ||
|
||
- uses: jetli/[email protected] | ||
with: | ||
version: "latest" | ||
- name: Setup wasm-pack | ||
uses: jetli/[email protected] | ||
|
||
- name: Setup Node | ||
uses: actions/setup-node@v4 | ||
with: | ||
node-version: 18 | ||
node-version: ">=18" | ||
cache: "npm" | ||
cache-dependency-path: js-framework-benchmark/package-lock.json | ||
|
||
- uses: Swatinem/rust-cache@v2 | ||
- name: Restore Rust cache for yew packages | ||
uses: Swatinem/rust-cache@v2 | ||
with: | ||
shared-key: yew-packages | ||
|
||
- name: Setup chrome | ||
id: setup-chrome | ||
uses: browser-actions/setup-chrome@v1 | ||
with: | ||
install-chromedriver: true | ||
|
||
- name: setup js-framework-benchmark | ||
- name: Setup js-framework-benchmark | ||
working-directory: js-framework-benchmark | ||
run: | | ||
npm ci | ||
npm run install-server | ||
npm run install-webdriver-ts | ||
- name: setup benchmark-struct benchmark | ||
- name: Setup benchmark-struct benchmark | ||
run: | | ||
ls -lauh | ||
rm *.js | ||
rm *.wasm | ||
echo "STRUCT_BUILD_DIR=$PWD" >> $GITHUB_ENV | ||
working-directory: js-framework-benchmark/frameworks/keyed/yew/bundled-dist/ | ||
|
||
- name: build benchmark-struct app | ||
- name: Build benchmark-struct app | ||
working-directory: yew/tools/benchmark-struct | ||
run: | | ||
wasm-pack build \ | ||
|
@@ -79,19 +83,19 @@ jobs: | |
--out-name js-framework-benchmark-yew \ | ||
--out-dir $STRUCT_BUILD_DIR | ||
- name: show built benchmark-struct benchmark files | ||
- name: Show built benchmark-struct benchmark files | ||
run: | | ||
ls -lauh js-framework-benchmark/frameworks/keyed/yew/bundled-dist/ | ||
- name: setup yew-hooks benchmark | ||
- name: Setup yew-hooks benchmark | ||
run: | | ||
ls -lauh | ||
rm *.js | ||
rm *.wasm | ||
echo "HOOKS_BUILD_DIR=$PWD" >> $GITHUB_ENV | ||
working-directory: js-framework-benchmark/frameworks/keyed/yew-hooks/bundled-dist/ | ||
|
||
- name: build benchmark-hooks app | ||
- name: Build benchmark-hooks app | ||
working-directory: yew/tools/benchmark-hooks | ||
run: | | ||
wasm-pack build \ | ||
|
@@ -101,25 +105,25 @@ jobs: | |
--out-name js-framework-benchmark-yew-hooks \ | ||
--out-dir $HOOKS_BUILD_DIR | ||
- name: show built benchmark-hooks benchmark files | ||
- name: Show built benchmark-hooks benchmark files | ||
run: | | ||
ls -lauh js-framework-benchmark/frameworks/keyed/yew-hooks/bundled-dist/ | ||
- name: run js-framework-benchmark server | ||
- name: Run js-framework-benchmark server | ||
working-directory: js-framework-benchmark | ||
run: | | ||
npm start & | ||
sleep 5 | ||
- name: js-framework-benchmark/webdriver-ts npm run bench | ||
- name: Run js-framework-benchmark/webdriver-ts npm run bench | ||
working-directory: js-framework-benchmark/webdriver-ts | ||
run: xvfb-run npm run bench -- --framework keyed/yew keyed/yew-hooks --runner playwright | ||
run: xvfb-run npm run bench -- --framework keyed/yew keyed/yew-hooks --runner playwright --chromeBinary "${{ steps.setup-chrome.outputs.chrome-path }}" | ||
|
||
- name: transform results to be fit for display benchmark-action/github-action-benchmark@v1 | ||
- name: Transform results to be fit for display benchmark-action/github-action-benchmark@v1 | ||
run: | | ||
mkdir artifacts/ | ||
jq -s . js-framework-benchmark/webdriver-ts/results/*.json | cargo run --manifest-path yew/Cargo.toml --release -p process-benchmark-results > artifacts/results.json | ||
echo "$EVENT_INFO" > artifacts/PR_INFO | ||
echo "$EVENT_INFO" > artifacts/.PR_INFO | ||
env: | ||
EVENT_INFO: ${{ toJSON(github.event) }} | ||
|
||
|
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Oops, something went wrong.