Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Remove a resource from an item (see #516) #602

Draft
wants to merge 2 commits into
base: v7
Choose a base branch
from
Draft
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
12 changes: 12 additions & 0 deletions features/remove_resource_from_item.feature
Original file line number Diff line number Diff line change
@@ -0,0 +1,12 @@
#language: fr

Fonctionnalité: Supprimer une ressource appartenant à un item

Scénario: Supprimer une ressource appartenant à un item

Soit "AXN 009" l'item affiché
Et l'utilisateur est connecté
Et la ressource "favicon.ico" existe comme ressource
Quand l'utilisateur supprime la ressource "favicon.ico"
Alors la ressource "favicon.ico" est supprimée

4 changes: 4 additions & 0 deletions features/step_definitions/context.rb
Original file line number Diff line number Diff line change
Expand Up @@ -85,3 +85,7 @@
page.current_window.resize_to(320, 480)
end

Soit("la ressource {string} existe comme ressource") do |string|
expect(find('.attachment_list')).to have_content string
end

4 changes: 4 additions & 0 deletions features/step_definitions/event.rb
Original file line number Diff line number Diff line change
Expand Up @@ -96,3 +96,7 @@
end
end

Quand("l'utilisateur supprime la ressource {string}") do |string|
find(string).click_on class: "btn"
end

3 changes: 3 additions & 0 deletions features/step_definitions/outcome.rb
Original file line number Diff line number Diff line change
Expand Up @@ -69,3 +69,6 @@
expect(find(".Attributes")).not_to have_content attribute
end

Alors("la ressource string est supprimée") do |string|
expect(find(".attachment_list")).not_to have_content string
end