From 9f06308dbd0b0911e73dfc001a1348960bfdced0 Mon Sep 17 00:00:00 2001 From: simon lehericey Date: Fri, 25 May 2018 10:50:18 +0200 Subject: [PATCH] DubiousProcedure: ensure that hidden procedure are not detected --- spec/jobs/find_dubious_procedures_job_spec.rb | 6 ++++++ 1 file changed, 6 insertions(+) diff --git a/spec/jobs/find_dubious_procedures_job_spec.rb b/spec/jobs/find_dubious_procedures_job_spec.rb index 2c1fb450a..06673367a 100644 --- a/spec/jobs/find_dubious_procedures_job_spec.rb +++ b/spec/jobs/find_dubious_procedures_job_spec.rb @@ -45,6 +45,12 @@ RSpec.describe FindDubiousProceduresJob, type: :job do it { expect(AdministrationMailer).to have_received(:dubious_procedures).with([]) } end + + context 'and a hidden procedure' do + let(:procedure) { create(:procedure, :hidden) } + + it { expect(AdministrationMailer).to have_received(:dubious_procedures).with([]) } + end end context 'with no suspicious champs' do