diff options
author | Robert Speicher <rspeicher@gmail.com> | 2015-06-12 00:44:13 -0400 |
---|---|---|
committer | Robert Speicher <rspeicher@gmail.com> | 2015-06-12 05:12:09 -0400 |
commit | 69bbc413fec7aa4168d9ff12df5421674db90032 (patch) | |
tree | 215a7f16d4630067bf4863d8d6f992fcac23969e /features/steps/snippets | |
parent | b07cf1182f78c5c46edbfa0fde668dd75ae47e05 (diff) | |
download | gitlab-ce-69bbc413fec7aa4168d9ff12df5421674db90032.tar.gz |
Update all `should`-style syntax to `expect` in features
Diffstat (limited to 'features/steps/snippets')
-rw-r--r-- | features/steps/snippets/discover.rb | 6 | ||||
-rw-r--r-- | features/steps/snippets/public_snippets.rb | 4 | ||||
-rw-r--r-- | features/steps/snippets/snippets.rb | 10 | ||||
-rw-r--r-- | features/steps/snippets/user.rb | 12 |
4 files changed, 16 insertions, 16 deletions
diff --git a/features/steps/snippets/discover.rb b/features/steps/snippets/discover.rb index 2667c1e3d44..76379d09d02 100644 --- a/features/steps/snippets/discover.rb +++ b/features/steps/snippets/discover.rb @@ -4,15 +4,15 @@ class Spinach::Features::SnippetsDiscover < Spinach::FeatureSteps include SharedSnippet step 'I should see "Personal snippet one" in snippets' do - page.should have_content "Personal snippet one" + expect(page).to have_content "Personal snippet one" end step 'I should see "Personal snippet internal" in snippets' do - page.should have_content "Personal snippet internal" + expect(page).to have_content "Personal snippet internal" end step 'I should not see "Personal snippet private" in snippets' do - page.should_not have_content "Personal snippet private" + expect(page).not_to have_content "Personal snippet private" end def snippet diff --git a/features/steps/snippets/public_snippets.rb b/features/steps/snippets/public_snippets.rb index 67669dc0a69..2ebdca5ed30 100644 --- a/features/steps/snippets/public_snippets.rb +++ b/features/steps/snippets/public_snippets.rb @@ -4,11 +4,11 @@ class Spinach::Features::PublicSnippets < Spinach::FeatureSteps include SharedSnippet step 'I should see snippet "Personal snippet one"' do - page.should have_no_xpath("//i[@class='public-snippet']") + expect(page).to have_no_xpath("//i[@class='public-snippet']") end step 'I should see raw snippet "Personal snippet one"' do - page.should have_text(snippet.content) + expect(page).to have_text(snippet.content) end step 'I visit snippet page "Personal snippet one"' do diff --git a/features/steps/snippets/snippets.rb b/features/steps/snippets/snippets.rb index de936db85ee..0f56fb03068 100644 --- a/features/steps/snippets/snippets.rb +++ b/features/steps/snippets/snippets.rb @@ -9,7 +9,7 @@ class Spinach::Features::Snippets < Spinach::FeatureSteps end step 'I should not see "Personal snippet one" in snippets' do - page.should_not have_content "Personal snippet one" + expect(page).not_to have_content "Personal snippet one" end step 'I click link "Edit"' do @@ -32,8 +32,8 @@ class Spinach::Features::Snippets < Spinach::FeatureSteps end step 'I should see snippet "Personal snippet three"' do - page.should have_content "Personal snippet three" - page.should have_content "Content of snippet three" + expect(page).to have_content "Personal snippet three" + expect(page).to have_content "Content of snippet three" end step 'I submit new title "Personal snippet new title"' do @@ -42,7 +42,7 @@ class Spinach::Features::Snippets < Spinach::FeatureSteps end step 'I should see "Personal snippet new title"' do - page.should have_content "Personal snippet new title" + expect(page).to have_content "Personal snippet new title" end step 'I uncheck "Private" checkbox' do @@ -51,7 +51,7 @@ class Spinach::Features::Snippets < Spinach::FeatureSteps end step 'I should see "Personal snippet one" public' do - page.should have_no_xpath("//i[@class='public-snippet']") + expect(page).to have_no_xpath("//i[@class='public-snippet']") end step 'I visit snippet page "Personal snippet one"' do diff --git a/features/steps/snippets/user.rb b/features/steps/snippets/user.rb index 146cc535d88..e6c6ec27e76 100644 --- a/features/steps/snippets/user.rb +++ b/features/steps/snippets/user.rb @@ -8,27 +8,27 @@ class Spinach::Features::SnippetsUser < Spinach::FeatureSteps end step 'I should see "Personal snippet one" in snippets' do - page.should have_content "Personal snippet one" + expect(page).to have_content "Personal snippet one" end step 'I should see "Personal snippet private" in snippets' do - page.should have_content "Personal snippet private" + expect(page).to have_content "Personal snippet private" end step 'I should see "Personal snippet internal" in snippets' do - page.should have_content "Personal snippet internal" + expect(page).to have_content "Personal snippet internal" end step 'I should not see "Personal snippet one" in snippets' do - page.should_not have_content "Personal snippet one" + expect(page).not_to have_content "Personal snippet one" end step 'I should not see "Personal snippet private" in snippets' do - page.should_not have_content "Personal snippet private" + expect(page).not_to have_content "Personal snippet private" end step 'I should not see "Personal snippet internal" in snippets' do - page.should_not have_content "Personal snippet internal" + expect(page).not_to have_content "Personal snippet internal" end step 'I click "Internal" filter' do |