Skip to content

chore: bump golang from c0074c7 to 4a7137e in /test/export/fake-reader #4467

chore: bump golang from c0074c7 to 4a7137e in /test/export/fake-reader

chore: bump golang from c0074c7 to 4a7137e in /test/export/fake-reader #4467

Workflow file for this run

name: build_test
on:
push:
paths-ignore:
- ".github/workflows/website.yaml"
- "docs/**"
- "library/**"
- "demo/**"
- "deprecated/**"
- "example/**"
- "website/**"
- "**.md"
- "!cmd/build/helmify/static/README.md"
pull_request:
paths-ignore:
- ".github/workflows/website.yaml"
- "docs/**"
- "library/**"
- "demo/**"
- "deprecated/**"
- "example/**"
- "website/**"
- "**.md"
- "!cmd/build/helmify/static/README.md"
permissions: read-all
jobs:
gator_test:
name: "Test Gator"
runs-on: oracle-vm-4cpu-16gb-x86-64
timeout-minutes: 5
steps:
- name: Harden Runner
uses: step-security/harden-runner@f808768d1510423e83855289c910610ca9b43176 # v2.17.0
with:
egress-policy: audit
- name: Check out code into the Go module directory
uses: actions/checkout@de0fac2e4500dabe0009e67214ff5f5447ce83dd # v6.0.2
- name: Set up Go
uses: actions/setup-go@4a3601121dd01d1626a1e23e37211e3254c1c06c # v6.4.0
with:
go-version: "1.25"
check-latest: true
- name: gator test
run: make test-gator-containerized
gator_bench_test:
name: "Gator Bench E2E"
runs-on: oracle-vm-4cpu-16gb-x86-64
timeout-minutes: 10
steps:
- name: Harden Runner
uses: step-security/harden-runner@f808768d1510423e83855289c910610ca9b43176 # v2.17.0
with:
egress-policy: audit
- name: Check out code into the Go module directory
uses: actions/checkout@de0fac2e4500dabe0009e67214ff5f5447ce83dd # v6.0.2
- name: Set up Go
uses: actions/setup-go@4a3601121dd01d1626a1e23e37211e3254c1c06c # v6.4.0
with:
go-version: "1.25"
check-latest: true
- name: Build gator
run: make gator
- name: Test basic Rego policy benchmark
run: |
./bin/gator bench \
--filename test/gator/bench/basic/ \
--iterations 50 \
--engine rego \
--output table
- name: Test CEL policy benchmark
run: |
./bin/gator bench \
--filename test/gator/bench/cel/ \
--iterations 50 \
--engine cel \
--output table
- name: Test dual-engine policy benchmark
run: |
./bin/gator bench \
--filename test/gator/bench/both/ \
--iterations 50 \
--engine all \
--output table
- name: Test memory profiling
run: |
./bin/gator bench \
--filename test/gator/bench/basic/ \
--iterations 20 \
--engine rego \
--memory \
--output table
- name: Test concurrent execution
run: |
./bin/gator bench \
--filename test/gator/bench/basic/ \
--iterations 100 \
--engine rego \
--concurrency 4 \
--output table
- name: Test JSON output
run: |
./bin/gator bench \
--filename test/gator/bench/basic/ \
--iterations 20 \
--engine rego \
--output json | jq .
- name: Test baseline save and compare
run: |
# Save baseline
./bin/gator bench \
--filename test/gator/bench/basic/ \
--iterations 30 \
--engine rego \
--save /tmp/baseline.json
# Compare against baseline - using high min-threshold since we're testing
# functionality not actual performance values in CI
./bin/gator bench \
--filename test/gator/bench/basic/ \
--iterations 30 \
--engine rego \
--compare /tmp/baseline.json \
--threshold 50 \
--min-threshold 100ms
- name: Test min-threshold
run: |
# Save baseline
./bin/gator bench \
--filename test/gator/bench/basic/ \
--iterations 30 \
--engine rego \
--save /tmp/baseline-min.json
# Compare with strict threshold (0.1%) but loose min-threshold (1s)
# This ensures the flag prevents failure from small variations
./bin/gator bench \
--filename test/gator/bench/basic/ \
--iterations 30 \
--engine rego \
--compare /tmp/baseline-min.json \
--threshold 0.1 \
--min-threshold 1s