Fixed tests.

This commit is contained in:
Jakub Roztocil 2014-04-26 20:14:46 +02:00
parent 43bc6d0c98
commit 1169a3eb23

View File

@ -10,7 +10,7 @@ from tests.fixtures import UNICODE
class TestUnicode: class TestUnicode:
def test_unicode_headers(self): def test_unicode_headers(self):
r = http('--verbose', httpbin('/headers'), u'Test:%s' % UNICODE) r = http(httpbin('/headers'), u'Test:%s' % UNICODE)
assert HTTP_OK in r assert HTTP_OK in r
assert r.json['headers']['Test'] == UNICODE assert r.json['headers']['Test'] == UNICODE
@ -42,9 +42,9 @@ class TestUnicode:
assert UNICODE in r assert UNICODE in r
def test_unicode_raw_json_item(self): def test_unicode_raw_json_item(self):
r = http('--verbose', r = http('--json', 'POST', httpbin('/post'),
'--json', 'POST', httpbin('/post'),
u'test:={ "%s" : [ "%s" ] }' % (UNICODE, UNICODE)) u'test:={ "%s" : [ "%s" ] }' % (UNICODE, UNICODE))
assert r.json['json'] == {'test': {UNICODE: [UNICODE]}}
def test_unicode_raw_json_item_verbose(self): def test_unicode_raw_json_item_verbose(self):
r = http('--verbose', r = http('--verbose',