diff options
author | GitLab Bot <gitlab-bot@gitlab.com> | 2021-05-19 18:44:42 +0300 |
---|---|---|
committer | GitLab Bot <gitlab-bot@gitlab.com> | 2021-05-19 18:44:42 +0300 |
commit | 4555e1b21c365ed8303ffb7a3325d773c9b8bf31 (patch) | |
tree | 5423a1c7516cffe36384133ade12572cf709398d /spec/features/groups/settings | |
parent | e570267f2f6b326480d284e0164a6464ba4081bc (diff) |
Add latest changes from gitlab-org/gitlab@13-12-stable-eev13.12.0-rc42
Diffstat (limited to 'spec/features/groups/settings')
-rw-r--r-- | spec/features/groups/settings/packages_and_registries_spec.rb | 31 |
1 files changed, 18 insertions, 13 deletions
diff --git a/spec/features/groups/settings/packages_and_registries_spec.rb b/spec/features/groups/settings/packages_and_registries_spec.rb index 45ea77e3868..551a0bc5375 100644 --- a/spec/features/groups/settings/packages_and_registries_spec.rb +++ b/spec/features/groups/settings/packages_and_registries_spec.rb @@ -66,28 +66,31 @@ RSpec.describe 'Group Packages & Registries settings' do it 'automatically saves changes to the server', :js do visit_settings_page - expect(page).to have_content('Allow duplicates') + within '[data-testid="maven-settings"]' do + expect(page).to have_content('Allow duplicates') - find('.gl-toggle').click + find('.gl-toggle').click - expect(page).to have_content('Do not allow duplicates') + expect(page).to have_content('Do not allow duplicates') - visit_settings_page + visit_settings_page - expect(page).to have_content('Do not allow duplicates') + expect(page).to have_content('Do not allow duplicates') + end end it 'shows an error on wrong regex', :js do visit_settings_page - expect(page).to have_content('Allow duplicates') - - find('.gl-toggle').click + within '[data-testid="maven-settings"]' do + expect(page).to have_content('Allow duplicates') - expect(page).to have_content('Do not allow duplicates') + find('.gl-toggle').click - fill_in 'Exceptions', with: ')' + expect(page).to have_content('Do not allow duplicates') + fill_in 'Exceptions', with: ')' + end # simulate blur event find('body').click @@ -98,11 +101,13 @@ RSpec.describe 'Group Packages & Registries settings' do it 'works correctly', :js do visit_sub_group_settings_page - expect(page).to have_content('Allow duplicates') + within '[data-testid="maven-settings"]' do + expect(page).to have_content('Allow duplicates') - find('.gl-toggle').click + find('.gl-toggle').click - expect(page).to have_content('Do not allow duplicates') + expect(page).to have_content('Do not allow duplicates') + end end end end |