fixed jsonify test

pull/10264/head
Brian Coca 10 years ago
parent 50379d59ba
commit bc5d0a8cd4

@ -181,14 +181,8 @@ class TestUtils(unittest.TestCase):
def test_jsonify(self): def test_jsonify(self):
self.assertEqual(ansible.utils.jsonify(None), '{}') self.assertEqual(ansible.utils.jsonify(None), '{}')
self.assertEqual(ansible.utils.jsonify(dict(foo='bar', baz=['qux'])), self.assertEqual(ansible.utils.jsonify(dict(foo='bar', baz=['qux'])), '{"baz": ["qux"], "foo": "bar"}')
'{"baz": ["qux"], "foo": "bar"}') expected = u'{\n "baz": [\n "qux"\n ],\n "foo": "bar"\n}'
expected = '''{
"baz": [
"qux"
],
"foo": "bar"
}'''
self.assertEqual(ansible.utils.jsonify(dict(foo='bar', baz=['qux']), format=True), expected) self.assertEqual(ansible.utils.jsonify(dict(foo='bar', baz=['qux']), format=True), expected)
def test_is_failed(self): def test_is_failed(self):

Loading…
Cancel
Save