Skip to content

Commit

Permalink
Adjust benchmark report to be more useful
Browse files Browse the repository at this point in the history
  • Loading branch information
stloyd committed Oct 17, 2023
1 parent 910c5ac commit a22cdd4
Show file tree
Hide file tree
Showing 4 changed files with 18 additions and 11 deletions.
10 changes: 1 addition & 9 deletions .github/workflows/benchmark-tag.yml
Original file line number Diff line number Diff line change
Expand Up @@ -51,7 +51,7 @@ jobs:
fi
- name: "Checkout to specific ref"
uses: "actions/checkout@v2"
uses: "actions/checkout@v4"
with:
ref: ${{ env.GIT_REF }}

Expand All @@ -63,14 +63,6 @@ jobs:
php-version: "${{ matrix.php-version }}"
ini-values: memory_limit=-1

- name: "Install PHP"
uses: "shivammathur/setup-php@v2"
with:
coverage: none
tools: composer:v2
php-version: "${{ matrix.php-version }}"
ini-values: memory_limit=-1

- name: "Get Composer Cache Directory"
id: composer-cache
run: |
Expand Down
3 changes: 2 additions & 1 deletion .github/workflows/test-benchmark.yml
Original file line number Diff line number Diff line change
Expand Up @@ -8,6 +8,7 @@ on:
- 'src/core/**'
- 'src/lib/**'
- 'tools/**'
- 'composer.json'
- 'composer.lock'

jobs:
Expand Down Expand Up @@ -96,4 +97,4 @@ jobs:
echo '---' >> $GITHUB_STEP_SUMMARY
echo '```' >> $GITHUB_STEP_SUMMARY
composer test:benchmark -- --ref=1.x --progress=none --group=entry_factory >> $GITHUB_STEP_SUMMARY
echo '```' >> $GITHUB_STEP_SUMMARY
echo '```' >> $GITHUB_STEP_SUMMARY
2 changes: 1 addition & 1 deletion composer.json
Original file line number Diff line number Diff line change
Expand Up @@ -165,7 +165,7 @@
"tools/phpunit/vendor/bin/phpunit"
],
"test:benchmark": [
"tools/phpbench/vendor/bin/phpbench run --report=aggregate --retry-threshold=5"
"tools/phpbench/vendor/bin/phpbench run --report=flow-report"
],
"test:mutation": [
"tools/infection/vendor/bin/infection -j2"
Expand Down
14 changes: 14 additions & 0 deletions phpbench.json
Original file line number Diff line number Diff line change
@@ -1,6 +1,19 @@
{
"$schema": "./tools/phpbench/vendor/phpbench/phpbench/phpbench.schema.json",
"runner.bootstrap": "vendor/autoload.php",
"report.generators": {
"flow-report": {
"generator": "expression",
"cols": {
"benchmark": null,
"subject": null,
"revs": null,
"its": null,
"mem_peak": null,
"mode": null
}
}
},
"runner.path": [
"src/adapter/etl-adapter-avro/tests/Flow/ETL/Adapter/Avro/Tests/Benchmark/",
"src/adapter/etl-adapter-csv/tests/Flow/ETL/Adapter/CSV/Tests/Benchmark/",
Expand All @@ -11,5 +24,6 @@
"src/core/etl/tests/Flow/ETL/Tests/Benchmark/"
],
"runner.progress": "dots",
"runner.retry_threshold": 5,
"storage.xml_storage_path": "var/phpbench"
}

0 comments on commit a22cdd4

Please sign in to comment.