Fix tests
This commit is contained in:
parent
f2a5d582b8
commit
b44da7b43d
4 changed files with 8 additions and 8 deletions
|
@ -15,7 +15,7 @@
|
|||
|
||||
- unless smart_listing.empty?
|
||||
- @dossiers.each do |dossier|
|
||||
%tr{'data-dossier_url' => backoffice_dossier_url(id: dossier.id)}
|
||||
%tr{id: "tr_dossier_#{dossier.id}", 'data-dossier_url' => backoffice_dossier_url(id: dossier.id)}
|
||||
- @dossiers_list_facade.preference_list_dossiers_filter.each_with_index do |preference, index|
|
||||
%td
|
||||
- if preference.table.nil? || preference.table.empty?
|
||||
|
|
|
@ -19,7 +19,7 @@
|
|||
- dossier_url = users_dossier_recapitulatif_path(dossier) unless dossier.brouillon?
|
||||
- dossier_url = users_dossier_description_path(dossier) if dossier.brouillon?
|
||||
|
||||
%tr{'data-dossier_url' => dossier_url}
|
||||
%tr{id: "tr_dossier_#{dossier.id}", 'data-dossier_url' => dossier_url}
|
||||
%td.center
|
||||
= dossier.id
|
||||
%td
|
||||
|
|
|
@ -20,9 +20,9 @@ feature 'on backoffice page' do
|
|||
|
||||
page.click_on 'Se connecter'
|
||||
end
|
||||
context 'when he click on first dossier' do
|
||||
context 'when he click on first dossier', js: true do
|
||||
before do
|
||||
page.click_on dossier.id
|
||||
page.find("#tr_dossier_#{dossier.id}").click
|
||||
end
|
||||
|
||||
scenario 'it redirect to dossier page' do
|
||||
|
@ -30,7 +30,7 @@ feature 'on backoffice page' do
|
|||
end
|
||||
end
|
||||
|
||||
context 'when gestionnaire have enterprise and individual dossier in his inbox' do
|
||||
context 'when gestionnaire have enterprise and individual dossier in his inbox', js: true do
|
||||
let!(:procedure_individual) { create :procedure, libelle: 'procedure individual', administrateur: administrateur, for_individual: true }
|
||||
let!(:dossier_individual) { create :dossier, procedure: procedure_individual, state: 'updated' }
|
||||
|
||||
|
@ -38,7 +38,7 @@ feature 'on backoffice page' do
|
|||
create :assign_to, gestionnaire: gestionnaire, procedure: procedure_individual
|
||||
|
||||
visit backoffice_path
|
||||
page.click_on dossier_individual.id
|
||||
page.find("#tr_dossier_#{dossier_individual.id}").click
|
||||
end
|
||||
|
||||
scenario 'it redirect to dossier page' do
|
||||
|
|
|
@ -32,9 +32,9 @@ feature 'user access to the list of his dossier' do
|
|||
expect(page).to have_css("#dossier_#{dossier1.id}_state")
|
||||
end
|
||||
|
||||
context 'when user clicks on a projet in list' do
|
||||
context 'when user clicks on a projet in list', js: true do
|
||||
before do
|
||||
page.click_on dossier1.procedure.libelle
|
||||
page.find("#tr_dossier_#{dossier1.id}").click
|
||||
end
|
||||
scenario 'user is redirected to dossier page' do
|
||||
expect(page).to have_css('#recap_dossier')
|
||||
|
|
Loading…
Reference in a new issue