Merge pull request #9549 from colinux/form-identite-fix-accessibilite
ETQ usager, le formulaire d'identité est un peu plus accessible
This commit is contained in:
commit
e1dab5bb39
16 changed files with 80 additions and 61 deletions
|
@ -110,8 +110,8 @@ describe 'wcag rules for usager', js: true, retry: 3 do
|
|||
click_on 'Commencer la démarche'
|
||||
|
||||
find('label', text: 'Monsieur')
|
||||
fill_in('identite_champ_first_name', with: 'prenom')
|
||||
fill_in('identite_champ_last_name', with: 'nom')
|
||||
fill_in('Prénom', with: 'prenom')
|
||||
fill_in('Nom', with: 'nom')
|
||||
click_on 'Continuer'
|
||||
|
||||
expect(page).to be_axe_clean
|
||||
|
|
|
@ -267,8 +267,8 @@ describe 'fetch API Particulier Data', js: true, retry: 3 do
|
|||
click_on 'Commencer la démarche'
|
||||
|
||||
find('label', text: 'Monsieur').click
|
||||
fill_in('identite_champ_first_name', with: 'prenom')
|
||||
fill_in('identite_champ_last_name', with: 'nom')
|
||||
fill_in('Prénom', with: 'prenom')
|
||||
fill_in('Nom', with: 'nom')
|
||||
|
||||
click_button('Continuer')
|
||||
|
||||
|
@ -326,8 +326,8 @@ describe 'fetch API Particulier Data', js: true, retry: 3 do
|
|||
click_on 'Commencer la démarche'
|
||||
|
||||
find('label', text: 'Monsieur').click
|
||||
fill_in('identite_champ_first_name', with: 'Georges')
|
||||
fill_in('identite_champ_last_name', with: 'Moustaki')
|
||||
fill_in('Prénom', with: 'Georges')
|
||||
fill_in('Nom', with: 'Moustaki')
|
||||
|
||||
click_button('Continuer')
|
||||
|
||||
|
@ -399,9 +399,9 @@ describe 'fetch API Particulier Data', js: true, retry: 3 do
|
|||
visit commencer_path(path: procedure.path)
|
||||
click_on 'Commencer la démarche'
|
||||
|
||||
find('label[for="identite_champ_radio_Mme"]').click
|
||||
fill_in('identite_champ_last_name', with: 'Dubois')
|
||||
fill_in('identite_champ_first_name', with: 'Angela Claire Louise')
|
||||
find('label', text: 'Madame').click
|
||||
fill_in('Prénom', with: 'Dubois')
|
||||
fill_in('Nom', with: 'Angela Claire Louise')
|
||||
|
||||
click_button('Continuer')
|
||||
|
||||
|
@ -463,9 +463,9 @@ describe 'fetch API Particulier Data', js: true, retry: 3 do
|
|||
visit commencer_path(path: procedure.path)
|
||||
click_on 'Commencer la démarche'
|
||||
|
||||
find('label[for="identite_champ_radio_Mme"]').click
|
||||
fill_in('identite_champ_last_name', with: 'FERRI')
|
||||
fill_in('identite_champ_first_name', with: 'Karine')
|
||||
find('label', text: 'Madame').click
|
||||
fill_in('Nom', with: 'FERRI')
|
||||
fill_in('Prénom', with: 'Karine')
|
||||
|
||||
click_button('Continuer')
|
||||
|
||||
|
|
|
@ -263,8 +263,8 @@ describe 'The routing with rules', js: true, retry: 3 do
|
|||
click_on 'Commencer la démarche'
|
||||
|
||||
find('label', text: 'Monsieur').click
|
||||
fill_in('identite_champ_first_name', with: 'Prenom')
|
||||
fill_in('identite_champ_last_name', with: 'Nom')
|
||||
fill_in('Prénom', with: 'Prenom')
|
||||
fill_in('Nom', with: 'Nom')
|
||||
click_button('Continuer')
|
||||
|
||||
# the old system should not be present
|
||||
|
|
|
@ -43,7 +43,7 @@ describe 'Signin in:' do
|
|||
|
||||
expect(page).to have_current_path identite_dossier_path(user.reload.dossiers.last)
|
||||
expect(page).to have_content(procedure.libelle)
|
||||
expect(page).to have_content "Données d’identité"
|
||||
expect(page).to have_content "Identité du demandeur"
|
||||
end
|
||||
end
|
||||
|
||||
|
|
|
@ -566,7 +566,7 @@ describe 'The user' do
|
|||
visit "/commencer/#{procedure.path}"
|
||||
click_on 'Commencer la démarche'
|
||||
|
||||
expect(page).to have_content("Données d’identité")
|
||||
expect(page).to have_content("Identité du demandeur")
|
||||
expect(page).to have_current_path(identite_dossier_path(user_dossier))
|
||||
end
|
||||
|
||||
|
@ -581,8 +581,8 @@ describe 'The user' do
|
|||
|
||||
def fill_individual
|
||||
find('label', text: 'Monsieur').click
|
||||
fill_in('identite_champ_first_name', with: 'prenom')
|
||||
fill_in('identite_champ_last_name', with: 'nom')
|
||||
fill_in('Prénom', with: 'prenom')
|
||||
fill_in('Nom', with: 'nom')
|
||||
click_on 'Continuer'
|
||||
expect(page).to have_current_path(brouillon_dossier_path(user_dossier))
|
||||
end
|
||||
|
|
|
@ -22,8 +22,8 @@ describe 'Creating a new dossier:' do
|
|||
expect(page).to have_title(libelle)
|
||||
|
||||
find('label', text: 'Monsieur').click
|
||||
fill_in('identite_champ_first_name', with: 'Prenom')
|
||||
fill_in('identite_champ_last_name', with: 'Nom')
|
||||
fill_in('Prénom', with: 'Prenom')
|
||||
fill_in('Nom', with: 'Nom')
|
||||
end
|
||||
|
||||
shared_examples 'the user can create a new draft' do
|
||||
|
@ -41,7 +41,7 @@ describe 'Creating a new dossier:' do
|
|||
let(:expected_birthday) { Date.new(1987, 10, 14) }
|
||||
|
||||
before do
|
||||
fill_in 'identite_champ_birthdate', with: birthday_format
|
||||
fill_in 'Date de naissance', with: birthday_format
|
||||
end
|
||||
|
||||
context 'when the browser supports `type=date` input fields' do
|
||||
|
|
|
@ -75,8 +75,8 @@ describe 'dropdown list with other option activated', js: true, retry: 3 do
|
|||
|
||||
def fill_individual
|
||||
find('label', text: 'Monsieur').click
|
||||
fill_in('identite_champ_first_name', with: 'prenom')
|
||||
fill_in('identite_champ_last_name', with: 'nom')
|
||||
fill_in('Prénom', with: 'prenom')
|
||||
fill_in('Nom', with: 'nom')
|
||||
click_on 'Continuer'
|
||||
expect(page).to have_current_path(brouillon_dossier_path(user_dossier))
|
||||
end
|
||||
|
|
|
@ -75,14 +75,14 @@ describe 'linked dropdown lists' do
|
|||
expect(page).to have_current_path(commencer_path(path: procedure.path))
|
||||
click_on 'Commencer la démarche'
|
||||
|
||||
expect(page).to have_content("Données d’identité")
|
||||
expect(page).to have_content("Identité du demandeur")
|
||||
expect(page).to have_current_path(identite_dossier_path(user_dossier))
|
||||
end
|
||||
|
||||
def fill_individual
|
||||
find('label', text: 'Monsieur').click
|
||||
fill_in('identite_champ_first_name', with: 'prenom')
|
||||
fill_in('identite_champ_last_name', with: 'nom')
|
||||
fill_in('Prénom', with: 'prenom')
|
||||
fill_in('Nom', with: 'nom')
|
||||
click_on 'Continuer'
|
||||
expect(page).to have_current_path(brouillon_dossier_path(user_dossier))
|
||||
end
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue