BURs: add processing and failed states.
When a BUR is approved, put it in a `processing` state. After it successfully finishes processing, put it in the `approved` state. If it fails processing, put it in the `failed` state. If approving the BUR fails with a validation error, for example because the alias already exists or an implication lacks a wiki, then leave the BUR in the `pending` state. The `failed` state is only for unexpected errors during processing.
This commit is contained in:
@@ -181,7 +181,10 @@ class BulkUpdateRequestsControllerTest < ActionDispatch::IntegrationTest
|
||||
context "for an admin" do
|
||||
should "succeed" do
|
||||
post_auth approve_bulk_update_request_path(@bulk_update_request), @admin
|
||||
|
||||
assert_response :redirect
|
||||
assert_equal("processing", @bulk_update_request.reload.status)
|
||||
perform_enqueued_jobs
|
||||
assert_equal("approved", @bulk_update_request.reload.status)
|
||||
end
|
||||
end
|
||||
|
||||
Reference in New Issue
Block a user