Skip to content

Commit

Permalink
Limiting line width by 99 chars
Browse files Browse the repository at this point in the history
  • Loading branch information
pylover committed Mar 8, 2018
1 parent 4dde614 commit e0b1611
Show file tree
Hide file tree
Showing 2 changed files with 13 additions and 5 deletions.
16 changes: 13 additions & 3 deletions bddrest/tests/test_call.py
Original file line number Diff line number Diff line change
Expand Up @@ -32,7 +32,11 @@ def test_call_constructor(self):
self.assertEqual(call.url, '/:id')
self.assertDictEqual(call.url_parameters, dict(id='1'))

call = Given('Testing Call contractor', url='/id: 1/:name', url_parameters=dict(name='foo', id=2))
call = Given(
'Testing Call contractor',
url='/id: 1/:name',
url_parameters=dict(name='foo', id=2)
)
call.validate()
self.assertEqual(call.url, '/:id/:name')
self.assertDictEqual(call.url_parameters, dict(id='2', name='foo'))
Expand All @@ -56,7 +60,10 @@ def test_call_response(self):
self.assertEqual(call.response.content_type, 'application/json')
self.assertIsNotNone(call.response.text)
self.assertDictEqual(call.response.json, {'query': 'a=1', 'url': '/1'})
self.assertListEqual(call.response.headers, [('Content-Type', 'application/json;charset=utf-8')])
self.assertListEqual(
call.response.headers,
[('Content-Type', 'application/json;charset=utf-8')]
)

def test_call_to_dict(self):
call = Given('Testing Call to_dict', url='/id: 1', query='a=1')
Expand Down Expand Up @@ -107,7 +114,10 @@ def test_call_verify(self):
altered_call.verify(wsgi_application)

altered_call.response.body = '{"a": 1}'
self.assertRaises(CallVerifyError, functools.partial(altered_call.verify, wsgi_application))
self.assertRaises(
CallVerifyError,
functools.partial(altered_call.verify, wsgi_application)
)


if __name__ == '__main__':
Expand Down
2 changes: 0 additions & 2 deletions bddrest/tests/test_documentary.py
Original file line number Diff line number Diff line change
Expand Up @@ -91,8 +91,6 @@ def test_markdown(self):
outputstring
)

maxDiff = None


if __name__ == '__main__':
unittest.main()
Expand Down

0 comments on commit e0b1611

Please sign in to comment.