Skip to content

Commit

Permalink
black reformatting
Browse files Browse the repository at this point in the history
  • Loading branch information
sckott committed Jan 31, 2023
1 parent 439775b commit 6ca5b2e
Show file tree
Hide file tree
Showing 4 changed files with 21 additions and 5 deletions.
11 changes: 9 additions & 2 deletions habanero/request.py
Original file line number Diff line number Diff line change
Expand Up @@ -4,8 +4,15 @@

from .exceptions import RequestError
from .filterhandler import filter_handler
from .habanero_utils import (check_json, filter_dict, ifelsestr, is_json,
make_ua, parse_json_err, rename_query_filters)
from .habanero_utils import (
check_json,
filter_dict,
ifelsestr,
is_json,
make_ua,
parse_json_err,
rename_query_filters,
)
from .request_class import Request


Expand Down
4 changes: 3 additions & 1 deletion test/test-funders.py
Original file line number Diff line number Diff line change
Expand Up @@ -126,7 +126,9 @@ def test_funders_mixed_ids_works_warn():
"""funders - param: warn"""
with pytest.warns(UserWarning):
out = cr.funders(
ids=["10.13039/100000001", "10.13039/notarealdoi", "10.13039/100000005"], works=True, warn=True
ids=["10.13039/100000001", "10.13039/notarealdoi", "10.13039/100000005"],
works=True,
warn=True,
)
assert len(out) == 3
assert len([x for x in out if x]) == 2
Expand Down
4 changes: 3 additions & 1 deletion test/test-journals.py
Original file line number Diff line number Diff line change
Expand Up @@ -140,7 +140,9 @@ def test_journals_bad_id_works_warn():
def test_journals_mixed_ids_works_warn():
"""journals - param: warn"""
with pytest.warns(UserWarning):
out = cr.journals(ids=["1803-2427", "4444-4444", "2167-8359"], works=True, warn=True)
out = cr.journals(
ids=["1803-2427", "4444-4444", "2167-8359"], works=True, warn=True
)
assert len(out) == 3
assert len([x for x in out if x]) == 2
assert isinstance(out[0], dict)
Expand Down
7 changes: 6 additions & 1 deletion test/test-works.py
Original file line number Diff line number Diff line change
Expand Up @@ -115,7 +115,12 @@ def test_works_mixed_ids_warn():
"""works - param: warn"""
with pytest.warns(UserWarning):
out = cr.works(
ids=["10.1371/journal.pone.0033693", "10.1371/notarealdoi", "10.1371/journal.pone.0020476", ], warn=True
ids=[
"10.1371/journal.pone.0033693",
"10.1371/notarealdoi",
"10.1371/journal.pone.0020476",
],
warn=True,
)
assert len(out) == 3
assert len([x for x in out if x]) == 2
Expand Down

0 comments on commit 6ca5b2e

Please sign in to comment.