Fix comparison constant position (#145)
* Fix comparison constant position * format with black Co-authored-by: deepsource-autofix[bot] <62050782+deepsource-autofix[bot]@users.noreply.github.com> Co-authored-by: Akash Mahanty <akamhy@yahoo.com>
This commit is contained in:
parent
0b631592ea
commit
e0dfbe0b7d
@ -99,7 +99,7 @@ def test_no_api_call_str_repr() -> None:
|
||||
availability_api = WaybackMachineAvailabilityAPI(
|
||||
url=f"https://{rndstr(30)}.gov", user_agent=user_agent
|
||||
)
|
||||
assert "" == str(availability_api)
|
||||
assert str(availability_api) == ""
|
||||
|
||||
|
||||
def test_no_call_timestamp() -> None:
|
||||
|
@ -28,19 +28,21 @@ def test_full_url() -> None:
|
||||
assert endpoint == full_url(endpoint, params)
|
||||
|
||||
params = {"a": "1"}
|
||||
assert "https://web.archive.org/cdx/search/cdx?a=1" == full_url(endpoint, params)
|
||||
assert "https://web.archive.org/cdx/search/cdx?a=1" == full_url(
|
||||
endpoint + "?", params
|
||||
assert full_url(endpoint, params) == "https://web.archive.org/cdx/search/cdx?a=1"
|
||||
assert (
|
||||
full_url(endpoint + "?", params) == "https://web.archive.org/cdx/search/cdx?a=1"
|
||||
)
|
||||
|
||||
params["b"] = 2
|
||||
assert "https://web.archive.org/cdx/search/cdx?a=1&b=2" == full_url(
|
||||
endpoint + "?", params
|
||||
assert (
|
||||
full_url(endpoint + "?", params)
|
||||
== "https://web.archive.org/cdx/search/cdx?a=1&b=2"
|
||||
)
|
||||
|
||||
params["c"] = "foo bar"
|
||||
assert "https://web.archive.org/cdx/search/cdx?a=1&b=2&c=foo%20bar" == full_url(
|
||||
endpoint + "?", params
|
||||
assert (
|
||||
full_url(endpoint + "?", params)
|
||||
== "https://web.archive.org/cdx/search/cdx?a=1&b=2&c=foo%20bar"
|
||||
)
|
||||
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user