File tree Expand file tree Collapse file tree 2 files changed +13
-0
lines changed Expand file tree Collapse file tree 2 files changed +13
-0
lines changed Original file line number Diff line number Diff line change @@ -185,4 +185,8 @@ $t->delete_ok("/webwork3/api/courses/4/sets/$hw1->{set_id}/problems/$new_problem
185185$t -> get_ok(" /webwork3/api/courses/4/sets/$hw1 ->{set_id}/problems/$new_problem ->{set_problem_id}" )-> status_is(500)
186186 -> json_is(' /exception' => ' DB::Exception::SetProblemNotFound' );
187187
188+ # And check that the problem is no longer in the db.
189+ $t -> get_ok(" /webwork3/api/courses/4/sets/$hw1 ->{set_id}/problems/$new_problem ->{set_problem_id}" )-> status_is(500)
190+ -> json_is(' /exception' => ' DB::Exception::SetProblemNotFound' );
191+
188192done_testing;
Original file line number Diff line number Diff line change @@ -247,6 +247,11 @@ $t->get_ok(
247247 " /webwork3/api/courses/4/sets/$hw1 ->{set_id}/users/$ralph ->{user_id}/problems/$new_user_problem ->{user_problem_id}" )
248248 -> status_is(500)-> json_is(' /exception' => ' DB::Exception::UserProblemNotFound' );
249249
250+ # And check that the user problem is no longer in the db.
251+ $t -> get_ok(
252+ " /webwork3/api/courses/4/sets/$hw1 ->{set_id}/users/$ralph ->{user_id}/problems/$new_user_problem ->{user_problem_id}" )
253+ -> status_is(500)-> json_is(' /exception' => ' DB::Exception::UserProblemNotFound' );
254+
250255# Delete the added problem
251256
252257$t -> delete_ok(" /webwork3/api/courses/4/sets/$hw1 ->{set_id}/problems/$new_problem ->{set_problem_id}" )-> status_is(200)
@@ -256,4 +261,8 @@ $t->delete_ok("/webwork3/api/courses/4/sets/$hw1->{set_id}/problems/$new_problem
256261$t -> get_ok(" /webwork3/api/courses/4/sets/$hw1 ->{set_id}/problems/$new_problem ->{set_problem_id}" )-> status_is(500)
257262 -> json_is(' /exception' => ' DB::Exception::SetProblemNotFound' );
258263
264+ # And check that the problem is no longer in the db.
265+ $t -> get_ok(" /webwork3/api/courses/4/sets/$hw1 ->{set_id}/problems/$new_problem ->{set_problem_id}" )-> status_is(500)
266+ -> json_is(' /exception' => ' DB::Exception::SetProblemNotFound' );
267+
259268done_testing;
You can’t perform that action at this time.
0 commit comments