Exemplo n.º 1
0
 def test_status_delete():
     r = tests.t_delete("/api/v1/statuses/2")
     assert r.status_code == 401
     r = tests.a_delete("/api/v1/statuses/2")
     assert r.status_code == 403
     r = tests.a_delete("/api/v1/statuses/2", admin=True)
     assert r.status_code == 200
Exemplo n.º 2
0
 def test_user_delete():
     r = tests.t_delete("/api/v1/users/lionize")
     assert r.status_code == 401
     r = tests.a_delete("/api/v1/users/lionize")
     assert r.status_code == 403
     r = tests.a_delete("/api/v1/users/lionize", admin=True)
     assert r.status_code == 200
     r = tests.a_get("/api/v1/users/lionize")
     assert r.status_code == 404
Exemplo n.º 3
0
 def test_user_delete():
     r = tests.t_delete("/api/v1/users/lionize")
     assert r.status_code == 401
     r = tests.a_delete("/api/v1/users/lionize")
     assert r.status_code == 403
     r = tests.a_delete("/api/v1/users/lionize", admin=True)
     assert r.status_code == 200
     r = tests.a_get("/api/v1/users/lionize")
     assert r.status_code == 404
Exemplo n.º 4
0
 def test_ticket_delete(self):
     r = tests.t_delete("/api/v1/tickets/the-a-team/TEST/TEST-10")
     assert r.status_code == 401
     r = tests.a_delete("/api/v1/tickets/the-a-team/TEST/TEST-10")
     assert r.status_code == 200
     r = tests.a_get("/api/v1/tickets/the-a-team/TEST/TEST-10")
     assert r.status_code == 404
Exemplo n.º 5
0
 def test_member_delete():
     r = tests.t_delete("/api/v1/roles/the-a-team/0")
     assert r.status_code == 401
     r = tests.a_delete("/api/v1/roles/the-a-team/0")
     assert r.status_code == 200
     r = tests.a_get("/api/v1/roles/the-a-team/0")
     assert r.status_code == 404
Exemplo n.º 6
0
 def test_member_delete():
     r = tests.t_delete("/api/v1/roles/the-a-team/0")
     assert r.status_code == 401
     r = tests.a_delete("/api/v1/roles/the-a-team/0")
     assert r.status_code == 200
     r = tests.a_get("/api/v1/roles/the-a-team/0")
     assert r.status_code == 404
Exemplo n.º 7
0
 def test_team_delete():
     r = tests.t_delete("/api/v1/teams/the-a-team")
     assert r.status_code == 401
     r = tests.a_delete("/api/v1/teams/the-a-team")
     assert r.status_code == 200
     r = tests.a_get("/api/v1/teams/the-a-team")
     assert r.status_code == 404
Exemplo n.º 8
0
 def test_project_delete():
     r = tests.t_delete("/api/v1/projects/the-a-team/TEST2")
     assert r.status_code == 401
     r = tests.a_delete("/api/v1/projects/the-a-team/TEST2")
     assert r.status_code == 200
     r = tests.a_get("/api/v1/projects/the-a-team/TEST2")
     assert r.status_code == 404
Exemplo n.º 9
0
 def test_field_delete(self):
     r = tests.t_delete("/api/v1/fields/1")
     assert r.status_code == 401
     r = tests.a_delete("/api/v1/fields/1")
     assert r.status_code == 200
     r = tests.a_get("/api/v1/fields/1")
     assert r.status_code == 404
Exemplo n.º 10
0
 def test_field_delete(self):
     r = tests.t_delete("/api/v1/fields/1")
     assert r.status_code == 401
     r = tests.a_delete("/api/v1/fields/1")
     assert r.status_code == 200
     r = tests.a_get("/api/v1/fields/1")
     assert r.status_code == 404
Exemplo n.º 11
0
 def test_team_delete():
     r = tests.t_delete("/api/v1/teams/the-a-team")
     assert r.status_code == 401
     r = tests.a_delete("/api/v1/teams/the-a-team")
     assert r.status_code == 200
     r = tests.a_get("/api/v1/teams/the-a-team")
     assert r.status_code == 404