fix(dossier): excluded deleted dossiers from demarche overview
This commit is contained in:
parent
5eb489946d
commit
06f43f99d0
2 changed files with 8 additions and 2 deletions
|
@ -34,6 +34,13 @@ describe ProcedureOverview, type: :model do
|
|||
let!(:dossier_en_construction) do
|
||||
create(:dossier, procedure: procedure, state: Dossier.states.fetch(:en_construction), created_at: monday)
|
||||
end
|
||||
let(:dossier_en_construction_deleted_by_user) do
|
||||
create(:dossier, procedure: procedure, state: Dossier.states.fetch(:en_construction), created_at: monday)
|
||||
end
|
||||
|
||||
before do
|
||||
dossier_en_construction_deleted_by_user.update(hidden_by_user_at: Time.zone.now)
|
||||
end
|
||||
|
||||
it { expect(procedure_overview.dossiers_en_construction_count).to eq(1) }
|
||||
end
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue