diff options
author | Dmitriy Zaporozhets <dmitriy.zaporozhets@gmail.com> | 2014-07-31 23:05:30 +0300 |
---|---|---|
committer | Dmitriy Zaporozhets <dmitriy.zaporozhets@gmail.com> | 2014-07-31 23:05:30 +0300 |
commit | 394ac378f806db8d521e13709bdd3a3e5550399d (patch) | |
tree | 214fc94c35b329e738f52a92713159c71e942366 /features | |
parent | faaedbf0514f14d7f7341d72b507f541efbc5d26 (diff) | |
download | gitlab-ce-394ac378f806db8d521e13709bdd3a3e5550399d.tar.gz |
Fix markdown tests. Use new repo for testing. Fixed gitlab-shell test setup
Signed-off-by: Dmitriy Zaporozhets <dmitriy.zaporozhets@gmail.com>
Diffstat (limited to 'features')
-rw-r--r-- | features/project/source/markdown_render.feature | 24 | ||||
-rw-r--r-- | features/steps/project/markdown_render.rb | 32 |
2 files changed, 27 insertions, 29 deletions
diff --git a/features/project/source/markdown_render.feature b/features/project/source/markdown_render.feature index 970a9e57864..fce351317c6 100644 --- a/features/project/source/markdown_render.feature +++ b/features/project/source/markdown_render.feature @@ -2,7 +2,7 @@ Feature: Project markdown render Background: Given I sign in as a user And I own project "Delta" - Given I visit project source page + And I visit markdown branch # Tree README @@ -11,26 +11,26 @@ Feature: Project markdown render And I click on a relative link in README Then I should see the correct markdown - Scenario: I browse files from master branch - Then I should see files from repository in master + Scenario: I browse files from markdown branch + Then I should see files from repository in markdown And I should see rendered README which contains correct links And I click on Gitlab API in README Then I should see correct document rendered - Scenario: I view README in master branch - Then I should see files from repository in master + Scenario: I view README in markdown branch + Then I should see files from repository in markdown And I should see rendered README which contains correct links And I click on Rake tasks in README Then I should see correct directory rendered - Scenario: I view README in master branch to see reference links to directory - Then I should see files from repository in master + Scenario: I view README in markdown branch to see reference links to directory + Then I should see files from repository in markdown And I should see rendered README which contains correct links And I click on GitLab API doc directory in README Then I should see correct doc/api directory rendered - Scenario: I view README in master branch to see reference links to file - Then I should see files from repository in master + Scenario: I view README in markdown branch to see reference links to file + Then I should see files from repository in markdown And I should see rendered README which contains correct links And I click on Maintenance in README Then I should see correct maintenance file rendered @@ -41,19 +41,19 @@ Feature: Project markdown render # Blob - Scenario: I navigate to doc directory to view documentation in master + Scenario: I navigate to doc directory to view documentation in markdown And I navigate to the doc/api/README And I see correct file rendered And I click on users in doc/api/README Then I should see the correct document file - Scenario: I navigate to doc directory to view user doc in master + Scenario: I navigate to doc directory to view user doc in markdown And I navigate to the doc/api/README And I see correct file rendered And I click on raketasks in doc/api/README Then I should see correct directory rendered - Scenario: I navigate to doc directory to view user doc in master + Scenario: I navigate to doc directory to view user doc in markdown And I navigate to the doc/api/README And Header "GitLab API" should have correct id and link diff --git a/features/steps/project/markdown_render.rb b/features/steps/project/markdown_render.rb index c94de283069..1885649891e 100644 --- a/features/steps/project/markdown_render.rb +++ b/features/steps/project/markdown_render.rb @@ -12,11 +12,10 @@ class Spinach::Features::ProjectMarkdownRender < Spinach::FeatureSteps @project.team << [@user, :master] end - Then 'I should see files from repository in master' do - current_path.should == project_tree_path(@project, "master") - page.should have_content "Gemfile" - page.should have_content "app" - page.should have_content "README" + Then 'I should see files from repository in markdown' do + current_path.should == project_tree_path(@project, "markdown") + page.should have_content "README.md" + page.should have_content "CHANGELOG" end And 'I should see rendered README which contains correct links' do @@ -34,7 +33,7 @@ class Spinach::Features::ProjectMarkdownRender < Spinach::FeatureSteps end Then 'I should see correct document rendered' do - current_path.should == project_blob_path(@project, "master/doc/api/README.md") + current_path.should == project_blob_path(@project, "markdown/doc/api/README.md") page.should have_content "All API requests require authentication" end @@ -43,7 +42,7 @@ class Spinach::Features::ProjectMarkdownRender < Spinach::FeatureSteps end Then 'I should see correct directory rendered' do - current_path.should == project_tree_path(@project, "master/doc/raketasks") + current_path.should == project_tree_path(@project, "markdown/doc/raketasks") page.should have_content "backup_restore.md" page.should have_content "maintenance.md" end @@ -53,7 +52,7 @@ class Spinach::Features::ProjectMarkdownRender < Spinach::FeatureSteps end Then 'I should see correct doc/api directory rendered' do - current_path.should == project_tree_path(@project, "master/doc/api") + current_path.should == project_tree_path(@project, "markdown/doc/api") page.should have_content "README.md" page.should have_content "users.md" end @@ -63,7 +62,7 @@ class Spinach::Features::ProjectMarkdownRender < Spinach::FeatureSteps end Then 'I should see correct maintenance file rendered' do - current_path.should == project_blob_path(@project, "master/doc/raketasks/maintenance.md") + current_path.should == project_blob_path(@project, "markdown/doc/raketasks/maintenance.md") page.should have_content "bundle exec rake gitlab:env:info RAILS_ENV=production" end @@ -86,7 +85,7 @@ class Spinach::Features::ProjectMarkdownRender < Spinach::FeatureSteps end And 'I see correct file rendered' do - current_path.should == project_blob_path(@project, "master/doc/api/README.md") + current_path.should == project_blob_path(@project, "markdown/doc/api/README.md") page.should have_content "Contents" page.should have_link "Users" page.should have_link "Rake tasks" @@ -97,7 +96,7 @@ class Spinach::Features::ProjectMarkdownRender < Spinach::FeatureSteps end Then 'I should see the correct document file' do - current_path.should == project_blob_path(@project, "master/doc/api/users.md") + current_path.should == project_blob_path(@project, "markdown/doc/api/users.md") page.should have_content "Get a list of users." end @@ -125,9 +124,8 @@ class Spinach::Features::ProjectMarkdownRender < Spinach::FeatureSteps Then 'I should see files from repository in markdown branch' do current_path.should == project_tree_path(@project, "markdown") - page.should have_content "Gemfile" - page.should have_content "app" - page.should have_content "README" + page.should have_content "README.md" + page.should have_content "CHANGELOG" end And 'I see correct file rendered in markdown branch' do @@ -256,8 +254,8 @@ class Spinach::Features::ProjectMarkdownRender < Spinach::FeatureSteps end Given 'I go directory which contains README file' do - visit project_tree_path(@project, "master/doc/api") - current_path.should == project_tree_path(@project, "master/doc/api") + visit project_tree_path(@project, "markdown/doc/api") + current_path.should == project_tree_path(@project, "markdown/doc/api") end And 'I click on a relative link in README' do @@ -265,7 +263,7 @@ class Spinach::Features::ProjectMarkdownRender < Spinach::FeatureSteps end Then 'I should see the correct markdown' do - current_path.should == project_blob_path(@project, "master/doc/api/users.md") + current_path.should == project_blob_path(@project, "markdown/doc/api/users.md") page.should have_content "List users" end |