Skip to content

Commit

Permalink
gha: run benchmarks
Browse files Browse the repository at this point in the history
  • Loading branch information
efiop committed Nov 21, 2023
1 parent f98617a commit 7efd6ae
Show file tree
Hide file tree
Showing 2 changed files with 18 additions and 0 deletions.
3 changes: 3 additions & 0 deletions .github/workflows/tests.yml
Original file line number Diff line number Diff line change
Expand Up @@ -49,5 +49,8 @@ jobs:
- name: Upload coverage report
uses: codecov/[email protected]

- name: Run benchmarks
run: nox -s bench

- name: Build package
run: nox -s build
15 changes: 15 additions & 0 deletions noxfile.py
Original file line number Diff line number Diff line change
Expand Up @@ -21,6 +21,21 @@ def tests(session: nox.Session) -> None:
)


@nox.session
def bench(session: nox.Session) -> None:
session.install(".[tests]")
storage = os.getenv("PYTEST_BENCHMARK_STORAGE", "file://.benchmarks")
session.run(
"pytest",
"--benchmark-storage",
storage,
"--benchmark-only",
"--benchmark-group-by",
"func",
*session.posargs,
)


@nox.session
def lint(session: nox.Session) -> None:
session.install("pre-commit")
Expand Down

0 comments on commit 7efd6ae

Please sign in to comment.