diff --git a/spec/tasks/maintenance/rescue_dossier_with_invalid_repetition_task_spec.rb b/spec/tasks/maintenance/rescue_dossier_with_invalid_repetition_task_spec.rb index 963adf048..4d7a75ac9 100644 --- a/spec/tasks/maintenance/rescue_dossier_with_invalid_repetition_task_spec.rb +++ b/spec/tasks/maintenance/rescue_dossier_with_invalid_repetition_task_spec.rb @@ -19,7 +19,7 @@ module Maintenance before { invalid_champ.update!(row_id: dossier.champs[1].row_id) } it "dissociate champ having a row_id without a parent_id" do - expect { described_class.process(dossier) } + expect { described_class.process(dossier.id) } .to change { Champ.exists?(invalid_champ.id) }.from(true).to(false) end end