Skip to content

Commit

Permalink
Add benchmark (#28)
Browse files Browse the repository at this point in the history
* fix: typo readme.md

* refactor: sortBase() as a method of model.Base

* feat: added benchmark

* fix: rm venom output
  • Loading branch information
mathisdrn authored Aug 28, 2023
1 parent 79c88b5 commit dc04ea2
Show file tree
Hide file tree
Showing 5 changed files with 11 additions and 145 deletions.
9 changes: 9 additions & 0 deletions .github/workflows/ci.yml
Original file line number Diff line number Diff line change
Expand Up @@ -46,3 +46,12 @@ jobs:
-e PATH=/usr/local/bin:/usr/sbin:/usr/bin:/sbin:/bin:/usr/local/go/bin:/home/vscode/go/bin:/workspace/bin \
ci \
neon -props "{tag: ${CI_ACTION_REF_NAME}, MODULE: github.com/${CI_REPOSITORY,,}, BY: ${CI_ACTOR}}" test-int
- name: Store benchmark result
uses: benchmark-action/github-action-benchmark@v1
with:
tool: "go"
output-file-path: bin/benchstats.txt
github-token: ${{ secrets.GITHUB_TOKEN }}
auto-push: ${{ env.CI_REF_NAME == 'main' }}
fail-on-alert: true
1 change: 1 addition & 0 deletions .gitignore
Original file line number Diff line number Diff line change
Expand Up @@ -11,3 +11,4 @@ testdata/benchmark/**/*.yaml

test/suites/cli/rimo.schema.json
test/suites/testdata/data1/output/data.yaml
test/suites/testdata/data1/output/data.yaml
2 changes: 1 addition & 1 deletion build.yml
Original file line number Diff line number Diff line change
Expand Up @@ -237,7 +237,7 @@ targets:
doc: "Run all benchmarks"
depends: ["info", "refresh", "lint", "bench-data"]
steps:
- $: go test -bench=. -benchmem -coverprofile=./={BUILD_DIR}/coverage_benchmark.txt -covermode=atomic ./...
- $: go test -bench=. -benchmem ./... -run=^# -benchtime=1s | tee ./={BUILD_DIR}/benchstats.txt

test:
doc: "Run all tests with coverage"
Expand Down
Empty file.
144 changes: 0 additions & 144 deletions test/suites/testdata/data1/output/data.yaml

This file was deleted.

0 comments on commit dc04ea2

Please sign in to comment.