aboutsummaryrefslogtreecommitdiffstats
path: root/spec/controllers/api/v1
diff options
context:
space:
mode:
Diffstat (limited to 'spec/controllers/api/v1')
-rw-r--r--spec/controllers/api/v1/compliance_check_sets_controller_spec.rb9
1 files changed, 7 insertions, 2 deletions
diff --git a/spec/controllers/api/v1/compliance_check_sets_controller_spec.rb b/spec/controllers/api/v1/compliance_check_sets_controller_spec.rb
index c9c58c7cb..e8e24b530 100644
--- a/spec/controllers/api/v1/compliance_check_sets_controller_spec.rb
+++ b/spec/controllers/api/v1/compliance_check_sets_controller_spec.rb
@@ -1,7 +1,12 @@
RSpec.describe Api::V1::ComplianceCheckSetsController, type: :controller do
+ include_context 'iboo authenticated api user'
+
describe "POST #validate" do
- it "calls [that thing that updates statuses on ComplianceCheckX]" do
- post :validated, params: { id: 5 }
+ it "calls #update_status on the ComplianceCheckSet" do
+ check_set = create(:compliance_check_set)
+ expect_any_instance_of(ComplianceCheckSet).to receive(:update_status)
+
+ patch :validated, id: check_set.id
end
end
end