Beispiel #1
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
Beispiel #2
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
Beispiel #3
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
Beispiel #4
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
 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
Beispiel #6
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
Beispiel #7
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
 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
Beispiel #9
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
Beispiel #10
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
Beispiel #11
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