Skip to content

Commit 3a87ac5

Browse files
committed
Merge branch 'issue163-failure-details'
2 parents 166f273 + 162488b commit 3a87ac5

File tree

13 files changed

+1130
-302
lines changed

13 files changed

+1130
-302
lines changed

.github/workflows/benchmarks.yaml

Lines changed: 5 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -49,16 +49,14 @@ jobs:
4949
APEX_ALGORITHMS_S3_ENDPOINT_URL: "https://s3.waw3-1.cloudferro.com"
5050
APEX_ALGORITHMS_S3_DEFAULT_REGION: "waw3-1"
5151

52-
- name: Issue Generation
53-
if: ${{ failure() }}
52+
- name: GitHub Issue Handler
53+
if: ${{ always() }}
5454
env:
5555
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
5656
run: |
57-
if grep -q "FAILED" qa/benchmarks/pytest_output.txt; then
58-
python qa/tools/apex_algorithm_qa_tools/test_failure_handler.py
59-
else
60-
echo "No test failures detected"
61-
fi
57+
python qa/tools/apex_algorithm_qa_tools/github_issue_handler.py \
58+
--terminal-report qa/benchmarks/pytest_output.txt \
59+
--metrics-json qa/benchmarks/report/metrics.json
6260
6361
- name: List local reports
6462
if: ${{ !cancelled() }}

qa/benchmarks/tests/test_dummy.py

Lines changed: 17 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -7,6 +7,7 @@
77
"""
88

99
import pytest
10+
import requests
1011

1112

1213
@pytest.mark.parametrize("y", [4, 5, 6])
@@ -44,3 +45,19 @@ def test_upload_assets(tmp_path, upload_assets_on_fail, x):
4445
path.write_text("Hello, world.\n")
4546
upload_assets_on_fail(path)
4647
assert x == 5
48+
49+
50+
def test_output_stuff():
51+
print("print print")
52+
import logging
53+
54+
logger = logging.getLogger("test_output_stuff")
55+
logger.info("logger info")
56+
logger.warning("logger warning")
57+
logger.error("logger error")
58+
assert False
59+
60+
61+
def test_requests_fail():
62+
r = requests.get("https://nope.test/meh", timeout=0.1)
63+
assert r.status_code == 200

0 commit comments

Comments
 (0)