Commit ae975341 authored by Kirill Smelkov's avatar Kirill Smelkov

.

parent 391d4570
...@@ -133,14 +133,12 @@ def test_encode(): ...@@ -133,14 +133,12 @@ def test_encode():
('αβγ', '_ce_b1_ce_b2_ce_b3'), ('αβγ', '_ce_b1_ce_b2_ce_b3'),
('a b+c_d', 'a_20b_2bc__d'), ('a b+c_d', 'a_20b_2bc__d'),
] ]
for (s, encok) in testv: for (s, encok) in testv:
assert encode(s) == encok assert encode(s) == encok
assert decode(encok) == s assert decode(encok) == s
# decode errors # decode errors
from pytest import raises from pytest import raises
def checkbad(x, f): def checkbad(x, f):
with raises(ValueError, match="invalid encoding") as exci: with raises(ValueError, match="invalid encoding") as exci:
decode(x) decode(x)
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment