Welcome to mirror list, hosted at ThFree Co, Russian Federation.

gitlab.com/gitlab-org/gitlab-foss.git - Unnamed repository; edit this file 'description' to name the repository.
summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorStan Hu <stanhu@gmail.com>2015-03-22 18:24:23 +0300
committerStan Hu <stanhu@gmail.com>2015-03-22 18:47:22 +0300
commit90cbb73ed6c7deed4ff7fab4a5cf796228e6d145 (patch)
tree87e57cbb3fec487c9b5a3fc140d8b0520f8253ae /features/steps/dashboard
parent29f6b01d6343c08dc9fe1f6bdf95a645dd4e4cc0 (diff)
Fix "Import projects from" button to show the correct instructions
Closes #1267
Diffstat (limited to 'features/steps/dashboard')
-rw-r--r--features/steps/dashboard/new_project.rb27
1 files changed, 27 insertions, 0 deletions
diff --git a/features/steps/dashboard/new_project.rb b/features/steps/dashboard/new_project.rb
new file mode 100644
index 00000000000..5e588ceb780
--- /dev/null
+++ b/features/steps/dashboard/new_project.rb
@@ -0,0 +1,27 @@
+class Spinach::Features::NewProject < Spinach::FeatureSteps
+ include SharedAuthentication
+ include SharedPaths
+ include SharedProject
+
+ step 'I click "New project" link' do
+ click_link "New project"
+ end
+
+ step 'I see "New project" page' do
+ page.should have_content("Project path")
+ end
+
+ step 'I click on "Import project from GitHub"' do
+ first('.how_to_import_link').click
+ end
+
+ step 'I see instructions on how to import from GitHub' do
+ github_modal = first('.modal-body')
+ github_modal.should be_visible
+ github_modal.should have_content "To enable importing projects from GitHub"
+
+ all('.modal-body').each do |element|
+ element.should_not be_visible unless element == github_modal
+ end
+ end
+end