Commit ed757ef6 authored by Dmitriy Zaporozhets's avatar Dmitriy Zaporozhets

Rewrite remove tag test

Signed-off-by: default avatarDmitriy Zaporozhets <dmitriy.zaporozhets@gmail.com>
parent cea2afa8
...@@ -29,13 +29,6 @@ Feature: Project Commits Tags ...@@ -29,13 +29,6 @@ Feature: Project Commits Tags
@javascript @javascript
Scenario: I delete a tag Scenario: I delete a tag
Given I visit tag 'v1.1.0' page
Given I delete tag 'v1.1.0' Given I delete tag 'v1.1.0'
Then I should not see tag 'v1.1.0' Then I should not see tag 'v1.1.0'
@javascript
Scenario: I delete all tags and see info message
Given I delete all tags
Then I should see tags info message
# @wip
# Scenario: I can download project by tag
...@@ -52,31 +52,18 @@ class Spinach::Features::ProjectCommitsTags < Spinach::FeatureSteps ...@@ -52,31 +52,18 @@ class Spinach::Features::ProjectCommitsTags < Spinach::FeatureSteps
expect(page).to have_content 'Tag already exists' expect(page).to have_content 'Tag already exists'
end end
step "I visit tag 'v1.1.0' page" do
click_link 'v1.1.0'
end
step "I delete tag 'v1.1.0'" do step "I delete tag 'v1.1.0'" do
page.within '.tags' do
first('.btn-remove').click first('.btn-remove').click
sleep 0.05 sleep 0.05
end end
end
step "I should not see tag 'v1.1.0'" do step "I should not see tag 'v1.1.0'" do
page.within '.tags' do page.within '.tags' do
expect(page.all(visible: true)).not_to have_content 'v1.1.0' expect(page.all(visible: true)).not_to have_content 'v1.1.0'
end end
end end
step 'I delete all tags' do
page.within '.tags' do
page.all('.btn-remove').each do |remove|
remove.click
sleep 0.05
end
end
end
step 'I should see tags info message' do
page.within '.tags' do
expect(page).to have_content 'Repository has no tags yet.'
end
end
end end
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment