diff options
author | Dmitriy Zaporozhets <dmitriy.zaporozhets@gmail.com> | 2013-12-18 16:41:06 +0400 |
---|---|---|
committer | Dmitriy Zaporozhets <dmitriy.zaporozhets@gmail.com> | 2013-12-18 16:41:06 +0400 |
commit | 79248f4ca503a765131731dc7ffa5bfeca89cf73 (patch) | |
tree | eebc5121998b9eda17e1cec027c3486e7582a386 /features | |
parent | dad576a7771678ac4caf455272e03d2c779298ee (diff) | |
parent | 1521f467cbf8b1b9b3e9cb4169f3e96a9984bb46 (diff) |
Merge pull request #5866 from jhollingsworth/fix/default-public-pull-url
Update default public pull url.
Diffstat (limited to 'features')
-rw-r--r-- | features/public/public_projects.feature | 19 | ||||
-rw-r--r-- | features/steps/public/projects_feature.rb | 18 |
2 files changed, 32 insertions, 5 deletions
diff --git a/features/public/public_projects.feature b/features/public/public_projects.feature index 5a30c03dd4a..d6574ca900e 100644 --- a/features/public/public_projects.feature +++ b/features/public/public_projects.feature @@ -26,6 +26,14 @@ Feature: Public Projects Feature Given public empty project "Empty Public Project" When I visit empty project page Then I should see empty public project details + And I should see empty public project details with http clone info + + Scenario: I visit an empty public project page as user + Given I sign in as a user + And public empty project "Empty Public Project" + When I visit empty project page + Then I should see empty public project details + And I should see empty public project details with ssh clone info Scenario: I visit public area as user Given I sign in as a user @@ -42,10 +50,15 @@ Feature: Public Projects Feature Scenario: I visit public project page When I visit project "Community" page Then I should see project "Community" home page - And I should see a http link to the repository + And I should see an http link to the repository - Scenario: I visit public area as user + Scenario: I visit public project page as user Given I sign in as a user When I visit project "Community" page Then I should see project "Community" home page - And I should see a ssh link to the repository + And I should see an ssh link to the repository + + Scenario: I visit an empty public project page + Given public empty project "Empty Public Project" + When I visit empty project page + Then I should see empty public project details diff --git a/features/steps/public/projects_feature.rb b/features/steps/public/projects_feature.rb index a4209bb9c78..47e52f47d07 100644 --- a/features/steps/public/projects_feature.rb +++ b/features/steps/public/projects_feature.rb @@ -46,6 +46,20 @@ class Spinach::Features::PublicProjectsFeature < Spinach::FeatureSteps page.should have_content 'Git global setup' end + step 'I should see empty public project details with http clone info' do + project = Project.find_by_name('Empty Public Project') + page.all(:css, '.git-empty .clone').each do |element| + element.text.should include(project.http_url_to_repo) + end + end + + step 'I should see empty public project details with ssh clone info' do + project = Project.find_by_name('Empty Public Project') + page.all(:css, '.git-empty .clone').each do |element| + element.text.should include(project.url_to_repo) + end + end + step 'private project "Enterprise"' do create :project, name: 'Enterprise' end @@ -84,12 +98,12 @@ class Spinach::Features::PublicProjectsFeature < Spinach::FeatureSteps end end - Then 'I should see a http link to the repository' do + step 'I should see an http link to the repository' do project = Project.find_by_name 'Community' page.should have_field('project_clone', with: project.http_url_to_repo) end - Then 'I should see a ssh link to the repository' do + step 'I should see an ssh link to the repository' do project = Project.find_by_name 'Community' page.should have_field('project_clone', with: project.url_to_repo) end |