fix test
This commit is contained in:
parent
686000d6cb
commit
16864cc868
4 changed files with 9 additions and 13 deletions
|
@ -43,10 +43,6 @@
|
|||
= t('views.users.dossiers.dossiers_list.n_dossier')
|
||||
= number_with_html_delimiter(dossier.id)
|
||||
|
||||
- if @statut == "dossiers-supprimes"
|
||||
%span.fr-badge.fr-badge--sm.fr-badge--warning
|
||||
= t('views.users.dossiers.dossiers_list.deleted_badge')
|
||||
- else
|
||||
= status_badge_user(dossier, 'fr-mb-1w')
|
||||
|
||||
- if dossier.pending_correction?
|
||||
|
|
|
@ -513,7 +513,8 @@ en:
|
|||
created_at: Created at %{date}
|
||||
updated_at: updated at %{date}
|
||||
shared_with: File shared by %{owner} with
|
||||
deleted: Deleted at %{date}
|
||||
deleted_by_user: Deleted on %{date} by user
|
||||
deleted_by_automatic: Deleted on %{date} automatically due to expiration date
|
||||
procedure_closed:
|
||||
brouillon:
|
||||
internal_procedure_html: This procedure is closed. You cannot submit this file. We invite you to submit a new one on the %{link} which replaces it.
|
||||
|
|
|
@ -533,7 +533,6 @@ fr:
|
|||
created_at: Créé le %{date}
|
||||
updated_at: modifié le %{date}
|
||||
shared_with: Dossier partagé par %{owner} avec
|
||||
deleted: Supprimé le %{date}
|
||||
deleted_by_user: Supprimé le %{date} par l'usager
|
||||
deleted_by_automatic: Supprimé le %{date} automatiquement du à la date d'expiration
|
||||
dossier_action:
|
||||
|
|
|
@ -219,7 +219,7 @@ describe 'user access to the list of their dossiers', js: true do
|
|||
|
||||
describe 'restore' do
|
||||
it 'should have links to restore dossiers' do
|
||||
click_on "3 supprimés récemment"
|
||||
click_on "3 supprimés"
|
||||
expect(page).to have_link('Restaurer', href: restore_dossier_path(dossier_en_construction_supprime))
|
||||
expect(page).to have_button('Restaurer et étendre la conservation')
|
||||
expect(page).to have_link('Télécharger mon dossier', href: dossier_path("#{dossier_traite_expire.id}.pdf"))
|
||||
|
@ -227,29 +227,29 @@ describe 'user access to the list of their dossiers', js: true do
|
|||
|
||||
context 'when user clicks on restore button', js: true do
|
||||
scenario 'the dossier is restored' do
|
||||
click_on "3 supprimés récemment"
|
||||
click_on "3 supprimés"
|
||||
expect(page).to have_content(dossier_en_construction_supprime.procedure.libelle)
|
||||
click_on 'Restaurer'
|
||||
|
||||
expect(page).to have_content('Votre dossier a bien été restauré')
|
||||
expect(page).to have_content('2 supprimés récemment')
|
||||
expect(page).to have_content('2 supprimés')
|
||||
end
|
||||
end
|
||||
|
||||
context 'when user clicks on restore and extend button', js: true do
|
||||
scenario 'the dossier is restored and extended' do
|
||||
click_on "3 supprimés récemment"
|
||||
click_on "3 supprimés"
|
||||
expect(page).to have_content(dossier_en_construction_expire.procedure.libelle)
|
||||
click_on 'Restaurer et étendre la conservation'
|
||||
|
||||
expect(page).to have_content('Votre dossier sera conservé 3 mois supplémentaire')
|
||||
expect(page).to have_content('2 supprimés récemment')
|
||||
expect(page).to have_content('2 supprimés')
|
||||
end
|
||||
end
|
||||
|
||||
context 'when user download PDF of expired' do
|
||||
scenario "generate PDF" do
|
||||
click_on "3 supprimés récemment"
|
||||
click_on "3 supprimés"
|
||||
click_on 'Télécharger mon dossier', match: :first
|
||||
# Test fails when an error happens during PDF generation
|
||||
end
|
||||
|
|
Loading…
Reference in a new issue