DossierController: allow upload of empty

This commit is contained in:
simon lehericey 2018-02-27 17:25:45 +01:00
parent b08eb3592b
commit abc9068412
2 changed files with 13 additions and 2 deletions

View file

@ -212,5 +212,15 @@ describe NewUser::DossiersController, type: :controller do
it { expect(dossier.reload.state).to eq('brouillon') }
end
end
context 'when dossier has no champ' do
let(:submit_payload) { { id: dossier.id } }
it 'does not raise any errors' do
subject
expect(response).to redirect_to(users_dossier_recapitulatif_path(dossier))
end
end
end
end