diff options
author | tauriedavis <taurie@gitlab.com> | 2017-07-12 14:32:04 -0700 |
---|---|---|
committer | Phil Hughes <me@iamphill.com> | 2017-07-28 15:29:13 +0100 |
commit | d7b8b38db7e22e247b0cac30645b1bc7647eeb3a (patch) | |
tree | 3e424e79ad1e8c458e185c17251c2d19139382f6 /spec/features/projects/project_settings_spec.rb | |
parent | aaaa252e30e25afe58a39f97489a9a6eef92093e (diff) | |
download | gitlab-ce-d7b8b38db7e22e247b0cac30645b1bc7647eeb3a.tar.gz |
try and fix some tests
Diffstat (limited to 'spec/features/projects/project_settings_spec.rb')
-rw-r--r-- | spec/features/projects/project_settings_spec.rb | 8 |
1 files changed, 6 insertions, 2 deletions
diff --git a/spec/features/projects/project_settings_spec.rb b/spec/features/projects/project_settings_spec.rb index 6001bcfff0a..f9a24db648a 100644 --- a/spec/features/projects/project_settings_spec.rb +++ b/spec/features/projects/project_settings_spec.rb @@ -14,7 +14,9 @@ describe 'Edit Project Settings' do it 'shows errors for invalid project name' do visit edit_project_path(project) fill_in 'project_name_edit', with: 'foo&bar' - click_button 'Save changes' + page.within('.general-settings') do + click_button 'Save changes' + end expect(page).to have_field 'project_name_edit', with: 'foo&bar' expect(page).to have_content "Name can contain only letters, digits, emojis, '_', '.', dash, space. It must start with letter, digit, emoji or '_'." expect(page).to have_button 'Save changes' @@ -23,7 +25,9 @@ describe 'Edit Project Settings' do it 'shows a successful notice when the project is updated' do visit edit_project_path(project) fill_in 'project_name_edit', with: 'hello world' - click_button 'Save changes' + page.within('.general-settings') do + click_button 'Save changes' + end expect(page).to have_content "Project 'hello world' was successfully updated." end end |