Refactor specs

This commit is contained in:
blackst0ne 2017-03-12 00:59:09 +11:00
parent 93e204ea52
commit 6625d605ec
1 changed files with 9 additions and 6 deletions

View File

@ -16,6 +16,15 @@ feature "New project", feature: true do
expect(find_field("project_visibility_level_#{level}")).to be_checked
end
it 'saves visibility level on validation error' do
visit new_project_path
choose(key)
click_button('Create project')
expect(find_field("project_visibility_level_#{level}")).to be_checked
end
end
end
@ -60,12 +69,6 @@ feature "New project", feature: true do
expect(namespace.text).to eq group.name
end
it 'selects the visibility level' do
level = Gitlab::VisibilityLevel.options['Internal']
expect(find_field("project_visibility_level_#{level}")).to be_checked
end
end
end
end