-
Notifications
You must be signed in to change notification settings - Fork 0
/
unit.xml
51 lines (50 loc) · 6.96 KB
/
unit.xml
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
<?xml version="1.0" encoding="UTF-8"?>
<testsuites>
<testsuite errors="0" failures="1" name="RestAPI.tests.EventTestCase-20191010131706" skipped="0" tests="1" time="0.148">
<testcase classname="RestAPI.tests.EventTestCase" name="test_get_all_events" time="0.148">
<failure message="400 != 201" type="AssertionError">
<![CDATA[Traceback (most recent call last):
File "C:\Users\MikeGreat-2018-10\Documents\hackerrank_django\RestAPI\tests.py", line 55, in test_get_all_events
self.assertEqual(res.status_code, row['response']['status_code'])
AssertionError: 400 != 201
Stdout:
{'request': {'method': 'DELETE', 'url': '/erase', 'headers': {}, 'body': {}}, 'response': {'status_code': 200, 'headers': {}, 'body': {}}}
delete/erase/
final DELETE---/erase/---200===200
{'request': {'method': 'GET', 'url': '/events', 'headers': {}, 'body': {}}, 'response': {'status_code': 200, 'headers': {'Content-Type': 'application/json'}, 'body': []}}
get /events/
final GET---/events/---200===200
{'request': {'method': 'POST', 'url': '/events', 'headers': {'Content-Type': 'application/json'}, 'body': {'id': 1299472637, 'type': 'PushEvent', 'actor': {'id': 4189746, 'login': 'lisa67', 'avatar_url': 'https://avatars.com/4189746'}, 'repo': {'id': 144489, 'name': 'lisa67/aliquam-est-quaerat', 'url': 'https://github.com/lisa67/aliquam-est-quaerat'}, 'created_at': '2013-04-07 15:13:31'}}, 'response': {'status_code': 201, 'headers': {}, 'body': {}}}
{'id': 1299472637, 'type': 'PushEvent', 'created_at': datetime.datetime(2013, 4, 7, 15, 13, 31, tzinfo=<UTC>), 'repo': OrderedDict([('id', 144489), ('name', 'lisa67/aliquam-est-quaerat'), ('url', 'https://github.com/lisa67/aliquam-est-quaerat')]), 'actor': OrderedDict([('id', 4189746), ('login', 'lisa67'), ('avatar_url', 'https://avatars.com/4189746')])}
post /events/ --- {'id': 1299472637, 'type': 'PushEvent', 'actor': {'id': 4189746, 'login': 'lisa67', 'avatar_url': 'https://avatars.com/4189746'}, 'repo': {'id': 144489, 'name': 'lisa67/aliquam-est-quaerat', 'url': 'https://github.com/lisa67/aliquam-est-quaerat'}, 'created_at': '2013-04-07 15:13:31'}---http://localhost:8000/events/
final POST---/events/---201===201
{'request': {'method': 'POST', 'url': '/events', 'headers': {'Content-Type': 'application/json'}, 'body': {'id': 1299472637, 'type': 'PushEvent', 'actor': {'id': 4189746, 'login': 'lisa67', 'avatar_url': 'https://avatars.com/4189746'}, 'repo': {'id': 144489, 'name': 'lisa67/aliquam-est-quaerat', 'url': 'https://github.com/lisa67/aliquam-est-quaerat'}, 'created_at': '2013-04-07 15:13:31'}}, 'response': {'status_code': 400, 'headers': {}, 'body': {}}}
post /events/ --- {'id': 1299472637, 'type': 'PushEvent', 'actor': {'id': 4189746, 'login': 'lisa67', 'avatar_url': 'https://avatars.com/4189746'}, 'repo': {'id': 144489, 'name': 'lisa67/aliquam-est-quaerat', 'url': 'https://github.com/lisa67/aliquam-est-quaerat'}, 'created_at': '2013-04-07 15:13:31'}---http://localhost:8000/events/
final POST---/events/---400===400
{'request': {'method': 'POST', 'url': '/events', 'headers': {'Content-Type': 'application/json'}, 'body': {'id': 1299899515, 'type': 'PushEvent', 'actor': {'id': 4189746, 'login': 'lisa67', 'avatar_url': 'https://avatars.com/4189746'}, 'repo': {'id': 170826, 'name': 'lisa67/occaecati', 'url': 'https://github.com/lisa67/occaecati'}, 'created_at': '2013-04-08 00:13:31'}}, 'response': {'status_code': 201, 'headers': {}, 'body': {}}}
post /events/ --- {'id': 1299899515, 'type': 'PushEvent', 'actor': {'id': 4189746, 'login': 'lisa67', 'avatar_url': 'https://avatars.com/4189746'}, 'repo': {'id': 170826, 'name': 'lisa67/occaecati', 'url': 'https://github.com/lisa67/occaecati'}, 'created_at': '2013-04-08 00:13:31'}---http://localhost:8000/events/
final POST---/events/---400===201
]]> </failure>
</testcase>
<system-out>
<![CDATA[{'request': {'method': 'DELETE', 'url': '/erase', 'headers': {}, 'body': {}}, 'response': {'status_code': 200, 'headers': {}, 'body': {}}}
delete/erase/
final DELETE---/erase/---200===200
{'request': {'method': 'GET', 'url': '/events', 'headers': {}, 'body': {}}, 'response': {'status_code': 200, 'headers': {'Content-Type': 'application/json'}, 'body': []}}
get /events/
final GET---/events/---200===200
{'request': {'method': 'POST', 'url': '/events', 'headers': {'Content-Type': 'application/json'}, 'body': {'id': 1299472637, 'type': 'PushEvent', 'actor': {'id': 4189746, 'login': 'lisa67', 'avatar_url': 'https://avatars.com/4189746'}, 'repo': {'id': 144489, 'name': 'lisa67/aliquam-est-quaerat', 'url': 'https://github.com/lisa67/aliquam-est-quaerat'}, 'created_at': '2013-04-07 15:13:31'}}, 'response': {'status_code': 201, 'headers': {}, 'body': {}}}
{'id': 1299472637, 'type': 'PushEvent', 'created_at': datetime.datetime(2013, 4, 7, 15, 13, 31, tzinfo=<UTC>), 'repo': OrderedDict([('id', 144489), ('name', 'lisa67/aliquam-est-quaerat'), ('url', 'https://github.com/lisa67/aliquam-est-quaerat')]), 'actor': OrderedDict([('id', 4189746), ('login', 'lisa67'), ('avatar_url', 'https://avatars.com/4189746')])}
post /events/ --- {'id': 1299472637, 'type': 'PushEvent', 'actor': {'id': 4189746, 'login': 'lisa67', 'avatar_url': 'https://avatars.com/4189746'}, 'repo': {'id': 144489, 'name': 'lisa67/aliquam-est-quaerat', 'url': 'https://github.com/lisa67/aliquam-est-quaerat'}, 'created_at': '2013-04-07 15:13:31'}---http://localhost:8000/events/
final POST---/events/---201===201
{'request': {'method': 'POST', 'url': '/events', 'headers': {'Content-Type': 'application/json'}, 'body': {'id': 1299472637, 'type': 'PushEvent', 'actor': {'id': 4189746, 'login': 'lisa67', 'avatar_url': 'https://avatars.com/4189746'}, 'repo': {'id': 144489, 'name': 'lisa67/aliquam-est-quaerat', 'url': 'https://github.com/lisa67/aliquam-est-quaerat'}, 'created_at': '2013-04-07 15:13:31'}}, 'response': {'status_code': 400, 'headers': {}, 'body': {}}}
post /events/ --- {'id': 1299472637, 'type': 'PushEvent', 'actor': {'id': 4189746, 'login': 'lisa67', 'avatar_url': 'https://avatars.com/4189746'}, 'repo': {'id': 144489, 'name': 'lisa67/aliquam-est-quaerat', 'url': 'https://github.com/lisa67/aliquam-est-quaerat'}, 'created_at': '2013-04-07 15:13:31'}---http://localhost:8000/events/
final POST---/events/---400===400
{'request': {'method': 'POST', 'url': '/events', 'headers': {'Content-Type': 'application/json'}, 'body': {'id': 1299899515, 'type': 'PushEvent', 'actor': {'id': 4189746, 'login': 'lisa67', 'avatar_url': 'https://avatars.com/4189746'}, 'repo': {'id': 170826, 'name': 'lisa67/occaecati', 'url': 'https://github.com/lisa67/occaecati'}, 'created_at': '2013-04-08 00:13:31'}}, 'response': {'status_code': 201, 'headers': {}, 'body': {}}}
post /events/ --- {'id': 1299899515, 'type': 'PushEvent', 'actor': {'id': 4189746, 'login': 'lisa67', 'avatar_url': 'https://avatars.com/4189746'}, 'repo': {'id': 170826, 'name': 'lisa67/occaecati', 'url': 'https://github.com/lisa67/occaecati'}, 'created_at': '2013-04-08 00:13:31'}---http://localhost:8000/events/
final POST---/events/---400===201
]]> </system-out>
<system-err>
<![CDATA[]]> </system-err>
</testsuite>
</testsuites>