Merge pull request #14 from zcash/ci-updates

CI: Update benchmarks runner
This commit is contained in:
str4d 2021-01-22 01:42:24 +13:00 committed by GitHub
commit ca59d7f8c3
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
1 changed files with 4 additions and 8 deletions

View File

@ -21,13 +21,9 @@ jobs:
- uses: actions/checkout@v2
- name: Run benchmarks
run: |
# run benchmarks and save baseline to "criterion.dev.temp"
cargo bench -- --verbose --noplot --save-baseline criterion.dev.temp
# set the path to the file to upload to criterion.dev
echo "::set-env name=CRITERION_FILE_PATH::$(find $(find . -type d -name criterion.dev.temp) -name raw.csv)"
# run benchmarks and save baseline in a directory called "new"
cargo bench -- --verbose
- name: Upload benchmarks
run: |
# upload the file
curl -F 'raw.csv=@${{ env.CRITERION_FILE_PATH }}' \
'https://api.criterion.dev/v1/${{ github.repository }}/measurements?token=${{ secrets.CRITERION_TOKEN }}&commit=${{ github.sha }}'
# upload the files
bash <(curl -s https://criterion.dev/bash)