summaryrefslogtreecommitdiff
path: root/spec/features/tags
diff options
context:
space:
mode:
Diffstat (limited to 'spec/features/tags')
-rw-r--r--spec/features/tags/developer_creates_tag_spec.rb8
-rw-r--r--spec/features/tags/developer_deletes_tag_spec.rb6
-rw-r--r--spec/features/tags/developer_updates_tag_spec.rb8
-rw-r--r--spec/features/tags/developer_views_tags_spec.rb20
4 files changed, 21 insertions, 21 deletions
diff --git a/spec/features/tags/developer_creates_tag_spec.rb b/spec/features/tags/developer_creates_tag_spec.rb
index f982d403ce1..b0219cb546d 100644
--- a/spec/features/tags/developer_creates_tag_spec.rb
+++ b/spec/features/tags/developer_creates_tag_spec.rb
@@ -38,8 +38,8 @@ RSpec.describe 'Developer creates tag' do
it 'with multiline message displays the message in a <pre> block' do
create_tag_in_form(tag: 'v3.0', ref: 'master', message: "Awesome tag message\n\n- hello\n- world")
- expect(current_path).to eq(
- project_tag_path(project, 'v3.0'))
+ expect(page).to have_current_path(
+ project_tag_path(project, 'v3.0'), ignore_query: true)
expect(page).to have_content 'v3.0'
page.within 'pre.wrap' do
expect(page).to have_content "Awesome tag message - hello - world"
@@ -49,8 +49,8 @@ RSpec.describe 'Developer creates tag' do
it 'with multiline release notes parses the release note as Markdown' do
create_tag_in_form(tag: 'v4.0', ref: 'master', desc: "Awesome release notes\n\n- hello\n- world")
- expect(current_path).to eq(
- project_tag_path(project, 'v4.0'))
+ expect(page).to have_current_path(
+ project_tag_path(project, 'v4.0'), ignore_query: true)
expect(page).to have_content 'v4.0'
page.within '.description' do
expect(page).to have_content 'Awesome release notes'
diff --git a/spec/features/tags/developer_deletes_tag_spec.rb b/spec/features/tags/developer_deletes_tag_spec.rb
index 7c4c6f54685..6b669695f7b 100644
--- a/spec/features/tags/developer_deletes_tag_spec.rb
+++ b/spec/features/tags/developer_deletes_tag_spec.rb
@@ -27,13 +27,13 @@ RSpec.describe 'Developer deletes tag', :js do
context 'from a specific tag page' do
it 'deletes the tag' do
click_on 'v1.0.0'
- expect(current_path).to eq(
- project_tag_path(project, 'v1.0.0'))
+ expect(page).to have_current_path(
+ project_tag_path(project, 'v1.0.0'), ignore_query: true)
container = page.find('.nav-controls')
delete_tag container
- expect(current_path).to eq("#{project_tags_path(project)}/")
+ expect(page).to have_current_path("#{project_tags_path(project)}/", ignore_query: true)
expect(page).not_to have_content 'v1.0.0'
end
end
diff --git a/spec/features/tags/developer_updates_tag_spec.rb b/spec/features/tags/developer_updates_tag_spec.rb
index 93a275131bd..b2fc28b8493 100644
--- a/spec/features/tags/developer_updates_tag_spec.rb
+++ b/spec/features/tags/developer_updates_tag_spec.rb
@@ -20,8 +20,8 @@ RSpec.describe 'Developer updates tag' do
fill_in 'release_description', with: 'Awesome release notes'
click_button 'Save changes'
- expect(current_path).to eq(
- project_tag_path(project, 'v1.1.0'))
+ expect(page).to have_current_path(
+ project_tag_path(project, 'v1.1.0'), ignore_query: true)
expect(page).to have_content 'v1.1.0'
expect(page).to have_content 'Awesome release notes'
end
@@ -45,8 +45,8 @@ RSpec.describe 'Developer updates tag' do
fill_in 'release_description', with: 'Awesome release notes'
click_button 'Save changes'
- expect(current_path).to eq(
- project_tag_path(project, 'v1.1.0'))
+ expect(page).to have_current_path(
+ project_tag_path(project, 'v1.1.0'), ignore_query: true)
expect(page).to have_content 'v1.1.0'
expect(page).to have_content 'Awesome release notes'
end
diff --git a/spec/features/tags/developer_views_tags_spec.rb b/spec/features/tags/developer_views_tags_spec.rb
index 6bae53afe6f..57e1f7da04e 100644
--- a/spec/features/tags/developer_views_tags_spec.rb
+++ b/spec/features/tags/developer_views_tags_spec.rb
@@ -55,8 +55,8 @@ RSpec.describe 'Developer views tags' do
it 'views a specific tag page' do
click_on 'v1.0.0'
- expect(current_path).to eq(
- project_tag_path(project, 'v1.0.0'))
+ expect(page).to have_current_path(
+ project_tag_path(project, 'v1.0.0'), ignore_query: true)
expect(page).to have_content 'v1.0.0'
expect(page).to have_content 'This tag has no release notes.'
end
@@ -65,25 +65,25 @@ RSpec.describe 'Developer views tags' do
it 'has a button to browse files' do
click_on 'v1.0.0'
- expect(current_path).to eq(
- project_tag_path(project, 'v1.0.0'))
+ expect(page).to have_current_path(
+ project_tag_path(project, 'v1.0.0'), ignore_query: true)
click_on 'Browse files'
- expect(current_path).to eq(
- project_tree_path(project, 'v1.0.0'))
+ expect(page).to have_current_path(
+ project_tree_path(project, 'v1.0.0'), ignore_query: true)
end
it 'has a button to browse commits' do
click_on 'v1.0.0'
- expect(current_path).to eq(
- project_tag_path(project, 'v1.0.0'))
+ expect(page).to have_current_path(
+ project_tag_path(project, 'v1.0.0'), ignore_query: true)
click_on 'Browse commits'
- expect(current_path).to eq(
- project_commits_path(project, 'v1.0.0'))
+ expect(page).to have_current_path(
+ project_commits_path(project, 'v1.0.0'), ignore_query: true)
end
end
end