Skip to content

Commit 83c8ba2

Browse files
edtf.tests: autoformat
1 parent dedb361 commit 83c8ba2

File tree

1 file changed

+12
-11
lines changed

1 file changed

+12
-11
lines changed

edtf/tests.py

Lines changed: 12 additions & 11 deletions
Original file line numberDiff line numberDiff line change
@@ -111,8 +111,8 @@ def test_roll_negative_time_fields():
111111
year, month, day, hour, minute, second
112112
) == (-102, 5, 24, 21, 41, 47)
113113

114-
def test_remapparams():
115114

115+
def test_remapparams():
116116
@remapparams(parseAll="parse_all")
117117
def parser(s, parse_all=True):
118118
pass
@@ -154,30 +154,31 @@ def no_remappings():
154154
"expected ValueError from @remapparams() because p1 remaps to another remapped parameter"
155155
)
156156

157+
157158
def test_remapparams_parse_edtf():
158-
edtf_s = '2005-09-24T10:00:00' # ISO8601 example from the EDTF spec
159-
dat = parse_edtf(edtf_s) # implicit parse_all=True
159+
edtf_s = "2005-09-24T10:00:00" # ISO8601 example from the EDTF spec
160+
dat = parse_edtf(edtf_s) # implicit parse_all=True
160161
assert dat.isoformat() == edtf_s
161162
assert parse_edtf(edtf_s, parse_all=True).isoformat() == edtf_s
162163
assert parse_edtf(edtf_s, parseAll=True).isoformat() == edtf_s
163-
assert parse_edtf(f'{edtf_s} SNORT', parse_all=False).isoformat() == edtf_s
164-
assert parse_edtf(f'{edtf_s} SNORT', parseAll=False).isoformat() == edtf_s
164+
assert parse_edtf(f"{edtf_s} SNORT", parse_all=False).isoformat() == edtf_s
165+
assert parse_edtf(f"{edtf_s} SNORT", parseAll=False).isoformat() == edtf_s
165166
# make sure parse_all=True fails the SNORT parse
166167
try:
167-
parse_edtf(f'{edtf_s} SNORT')
168+
parse_edtf(f"{edtf_s} SNORT")
168169
except EDTFParseException:
169170
pass
170171
else:
171-
raise AssertionError('expected EDTFParseException')
172+
raise AssertionError("expected EDTFParseException")
172173
try:
173-
parse_edtf(f'{edtf_s} SNORT', parse_all=True)
174+
parse_edtf(f"{edtf_s} SNORT", parse_all=True)
174175
except EDTFParseException:
175176
pass
176177
else:
177-
raise AssertionError('expected EDTFParseException')
178+
raise AssertionError("expected EDTFParseException")
178179
try:
179-
parse_edtf(f'{edtf_s} SNORT', parseAll=True)
180+
parse_edtf(f"{edtf_s} SNORT", parseAll=True)
180181
except EDTFParseException:
181182
pass
182183
else:
183-
raise AssertionError('expected EDTFParseException')
184+
raise AssertionError("expected EDTFParseException")

0 commit comments

Comments
 (0)