diff --git a/.github/workflows/benchmark.yml b/.github/workflows/benchmark.yml index 8bc4590f..b5395dc5 100644 --- a/.github/workflows/benchmark.yml +++ b/.github/workflows/benchmark.yml @@ -29,27 +29,22 @@ jobs: with: python-version: '3.11' + - name: Upgrade pip and nox + run: python -m pip install --upgrade pip nox pytest-benchmark + - uses: actions/checkout@v4 with: ref: ${{ github.event.pull_request.base.sha }} fetch-depth: 0 - path: base + + - name: Benchmark on base branch + run: nox -s bench -- --benchmark-save=base - uses: actions/checkout@v4 with: fetch-depth: 0 - path: pr - - - name: Upgrade pip and nox - run: python -m pip install --upgrade pip nox pytest-benchmark - - - name: Benchmark on base branch - working-directory: base - run: | - nox -s bench -- --benchmark-save=base - name: Benchmark on pull request - working-directory: pr run: | nox -s bench -- --benchmark-save=${GITHUB_SHA::7} --benchmark-compare=0001 --benchmark-compare-fail=mean:10%