Skip to content

Commit 1046724

Browse files
[pre-commit.ci] auto fixes from pre-commit.com hooks
for more information, see https://pre-commit.ci
1 parent 51ed4c9 commit 1046724

File tree

2 files changed

+9
-2
lines changed

2 files changed

+9
-2
lines changed

tests/base.py

Lines changed: 7 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -134,11 +134,16 @@ def test_handles_percent_in_fragment(self, uri_fragment_with_percent):
134134
uri = self.test_class.from_string(uri_fragment_with_percent)
135135
assert uri.fragment == "perc%25ent"
136136

137-
def test_handles_line_terminators_in_fragment(self, uri_fragment_with_line_terminators):
137+
def test_handles_line_terminators_in_fragment(
138+
self, uri_fragment_with_line_terminators
139+
):
138140
"""Test that self.test_class encodes line terminators in the fragment properly"""
139-
ref = self.test_class.from_string(uri_fragment_with_line_terminators, 'utf-8')
141+
ref = self.test_class.from_string(
142+
uri_fragment_with_line_terminators, "utf-8"
143+
)
140144
assert ref.fragment == "%0Afrag%0Ament%0A"
141145

146+
142147
class BaseTestUnsplits:
143148
test_class = None
144149

tests/conftest.py

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -145,10 +145,12 @@ def uri_query_with_percent(request):
145145
def uri_fragment_with_percent(request):
146146
return "https://%s#perc%%ent" % request.param
147147

148+
148149
@pytest.fixture(params=valid_hosts)
149150
def uri_fragment_with_line_terminators(request):
150151
return "https://%s#\nfrag\nment\n" % request.param
151152

153+
152154
@pytest.fixture(params=equivalent_schemes)
153155
def scheme_only(request):
154156
return "%s:" % request.param

0 commit comments

Comments
 (0)