Skip to content

Commit

Permalink
testutils: Fix black style
Browse files Browse the repository at this point in the history
  • Loading branch information
MrKevinWeiss committed Jan 29, 2024
1 parent 9588fab commit 6e6db29
Show file tree
Hide file tree
Showing 2 changed files with 8 additions and 6 deletions.
6 changes: 3 additions & 3 deletions testutils/github.py
Original file line number Diff line number Diff line change
Expand Up @@ -210,9 +210,9 @@ def create_comment(github, issue):
def _generate_outcome_summary(pytest_report, task):
# pylint: disable=C0209
return "<strong>{a_open}{outcome}{a_close}</strong>".format(
a_open='<a href="{}">'.format(task["outcome_url"])
if "outcome_url" in task
else '',
a_open=(
'<a href="{}">'.format(task["outcome_url"]) if "outcome_url" in task else ''
),
outcome=pytest_report.outcome.upper(),
a_close='</a>' if "outcome_url" in task else '',
)
Expand Down
8 changes: 5 additions & 3 deletions testutils/tests/test_github.py
Original file line number Diff line number Diff line change
Expand Up @@ -983,9 +983,11 @@ def test_upload_results(
monkeypatch.setattr(
testutils.github,
"get_results_gist",
lambda *args, **kwargs: (testutils.github.Git('.'), "", "the_gist_id")
if gist_created
else (None, None, None),
lambda *args, **kwargs: (
(testutils.github.Git('.'), "", "the_gist_id")
if gist_created
else (None, None, None)
),
)
monkeypatch.setattr(
testutils.github, "upload_result_content", lambda *args, **kwargs: head
Expand Down

0 comments on commit 6e6db29

Please sign in to comment.