Skip to content

Commit e8df32c

Browse files
committed
test: add benchmarks
Closes TNTP-3733
1 parent 93a7028 commit e8df32c

File tree

9 files changed

+1007
-2
lines changed

9 files changed

+1007
-2
lines changed

.github/workflows/testing.yaml

Lines changed: 9 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -51,10 +51,18 @@ jobs:
5151
run: make coverage coveralls-deps coveralls
5252

5353
run-benchmarks:
54-
if: false
54+
if: (github.event_name == 'push') ||
55+
(github.event_name == 'pull_request' &&
56+
github.event.pull_request.head.repo.full_name != github.repository) ||
57+
(github.event_name == 'workflow_dispatch')
5558

5659
runs-on: ubuntu-latest
5760

61+
strategy:
62+
fail-fast: false
63+
matrix:
64+
golang: ['1.24', 'stable']
65+
5866
steps:
5967
- uses: actions/checkout@v4
6068
- uses: actions/setup-go@v5

Makefile

Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -17,6 +17,11 @@ testrace:
1717
@echo "Running tests with race flag"
1818
@go test ./... -count=100 -race
1919

20+
.PHONY: bench
21+
bench:
22+
@echo "Running benchmarks"
23+
@go test ./... -count=1 -bench=. -benchmem
24+
2025
.PHONY: coverage
2126
coverage:
2227
@echo "Running tests with coveralls"

0 commit comments

Comments
 (0)