fix rubocop offenses

This commit is contained in:
Christophe Robillard 2020-01-08 15:09:03 +01:00 committed by clemkeirua
parent c72ce977f7
commit a0b4d97d08

View file

@ -233,13 +233,11 @@ describe User, type: :model do
context 'avec un dossier en instruction' do
let!(:dossier_en_instruction) { create(:dossier, :en_instruction, user: user) }
it 'ne supprime rien si dossier en instruction' do
user.delete_and_keep_track_dossiers(administration)
expect(Dossier.find_by(id: dossier_en_instruction.id)).to be_present
expect(User.find_by(id: user.id)).to be_present
end
end
context 'sans dossier en instruction' do
@ -247,7 +245,6 @@ describe User, type: :model do
let!(:dossier_brouillon) { create(:dossier, user: user) }
it "garde une trace des dossiers et supprime l'utilisateur" do
user.delete_and_keep_track_dossiers(administration)
expect(DeletedDossier.find_by(dossier_id: dossier_en_construction)).to be_present