Skip to content

Commit

Permalink
Unicode Chars Removed
Browse files Browse the repository at this point in the history
  • Loading branch information
fahadsiddiqui committed Sep 21, 2020
1 parent eed4a8b commit ea32d52
Showing 1 changed file with 6 additions and 6 deletions.
12 changes: 6 additions & 6 deletions petl/test/io/test_jsonl.py
Original file line number Diff line number Diff line change
Expand Up @@ -9,21 +9,21 @@

def test_fromjson_1():
f = NamedTemporaryFile(delete=False, mode='w')
data = '{"name": "Gilbert", "wins": [["straight", "7♣"], ["one pair", "10♥"]]}\n' \
'{"name": "Alexa", "wins": [["two pair", "4♠"], ["two pair", "9♠"]]}\n' \
data = '{"name": "Gilbert", "wins": [["straight", "7S"], ["one pair", "10H"]]}\n' \
'{"name": "Alexa", "wins": [["two pair", "4S"], ["two pair", "9S"]]}\n' \
'{"name": "May", "wins": []}\n' \
'{"name": "Deloise", "wins": [["three of a kind", "5♣"]]}'
'{"name": "Deloise", "wins": [["three of a kind", "5S"]]}'

f.write(data)
f.close()

actual = fromjson(f.name, header=['name', 'wins'], lines=True)

expect = (('name', 'wins'),
('Gilbert', [["straight", "7♣"], ["one pair", "10♥"]]),
('Alexa', [["two pair", "4♠"], ["two pair", "9♠"]]),
('Gilbert', [["straight", "7S"], ["one pair", "10H"]]),
('Alexa', [["two pair", "4S"], ["two pair", "9S"]]),
('May', []),
('Deloise', [["three of a kind", "5♣"]]))
('Deloise', [["three of a kind", "5S"]]))

ieq(expect, actual)
ieq(expect, actual) # verify can iterate twice
Expand Down

0 comments on commit ea32d52

Please sign in to comment.