|
39 | 39 |
|
40 | 40 | env:
|
41 | 41 | REPORT_FORMAT: ${{ (github.event_name == 'push' || github.event_name == 'pull_request' ) && 'json' || 'csv' }}
|
42 |
| - MAIN_BENCHMARK_TASK: ${{ github.event.pull_request.number && 'prValidationBenchmark' || 'benchmark' }} |
| 42 | + MAIN_BENCH_TASK: ${{ github.event.pull_request.number && 'prValidationBenchmark' || 'benchmark' }} |
| 43 | + MAIN_BENCH_RESULTS: ${{ github.event.pull_request.number && 'prValidation' || 'main' }} |
| 44 | + COMPARISON_BENCH_RESULTS: ${{ github.event.pull_request.number && 'prValidationComparison' || 'comparison' }} |
43 | 45 |
|
44 | 46 | concurrency:
|
45 | 47 | cancel-in-progress: true
|
|
90 | 92 | gradle-version: wrapper
|
91 | 93 | - name: Run benchmarks
|
92 | 94 | run: >
|
93 |
| - ./gradlew --no-daemon :benchmark:${{ env.MAIN_BENCHMARK_TASK }} ${{ matrix.additional-task }} |
| 95 | + ./gradlew --no-daemon :benchmark:${{ env.MAIN_BENCH_TASK }} ${{ matrix.additional-task }} |
94 | 96 | -Pbenchmark_warmups=${{ inputs.warmups }}
|
95 | 97 | -Pbenchmark_iterations=${{ inputs.iterations }}
|
96 | 98 | -Pbenchmark_iteration_time=${{ inputs.iteration-time }}
|
@@ -125,13 +127,13 @@ jobs:
|
125 | 127 | uses: actions/upload-artifact@v4
|
126 | 128 | with:
|
127 | 129 | name: bench-result-${{ matrix.os }}
|
128 |
| - path: ${{ env.BENCHMARK_RESULTS }}/main/**/*.json |
| 130 | + path: ${{ env.BENCHMARK_RESULTS }}/${{ env.MAIN_BENCH_RESULTS }}/**/*.json |
129 | 131 | - name: Store comparison results as artifact
|
130 | 132 | if: env.REPORT_FORMAT == 'json' && matrix.os == 'ubuntu-latest'
|
131 | 133 | uses: actions/upload-artifact@v4
|
132 | 134 | with:
|
133 | 135 | name: bench-comparison-result-${{ matrix.os }}
|
134 |
| - path: ${{ env.BENCHMARK_RESULTS }}/comparison/**/*.json |
| 136 | + path: ${{ env.BENCHMARK_RESULTS }}/${{ env.COMPARISON_BENCH_RESULTS }}/**/*.json |
135 | 137 |
|
136 | 138 | upload-benchmark-results:
|
137 | 139 | if: (github.event_name == 'push' || github.event_name == 'pull_request') && github.repository == 'OptimumCode/json-schema-validator'
|
|
0 commit comments