Skip to content
This repository has been archived by the owner on Jul 27, 2022. It is now read-only.

Commit

Permalink
Merge pull request #2494 from ec-europa/ISAICP-6467
Browse files Browse the repository at this point in the history
  • Loading branch information
claudiu-cristea authored Jun 18, 2021
2 parents 35ae48e + cff3a5b commit a143042
Show file tree
Hide file tree
Showing 36 changed files with 163 additions and 186 deletions.
16 changes: 13 additions & 3 deletions config/sync/block.block.webtools_etrans.yml
Original file line number Diff line number Diff line change
Expand Up @@ -3,8 +3,7 @@ langcode: en
status: true
dependencies:
module:
- eif
- node
- joinup_core
- oe_webtools_etrans
theme:
- joinup_theme
Expand All @@ -25,4 +24,15 @@ settings:
delay: 0
include: ''
exclude: ''
visibility: { }
visibility:
request_route:
id: request_route
routes:
- entity.node.delete_form
- entity.node.edit_form
- entity.rdf_entity.delete_form
- entity.rdf_entity.edit_form
- entity.taxonomy_term.edit_form
- entity.taxonomy_term.delete_form
negate: true
context_mapping: { }
2 changes: 1 addition & 1 deletion tests/features/asset_release/asset_release.delete.feature
Original file line number Diff line number Diff line change
Expand Up @@ -37,7 +37,7 @@ Feature: Asset release "delete" functionality.
Scenario: "Delete" action should redirect users to the parent solution.
# Navigating through UI should redirect the user to the solution homepage.
When I am logged in as a "moderator"
And I go to the "Yet another release" release edit form
And I go to the edit form of the "Yet another release" release
And I click "Delete"
And I press "Delete"
Then I should be on "/collection/yet-another-collection/solution/yet-another-solution"
2 changes: 1 addition & 1 deletion tests/features/collection/collection.about.feature
Original file line number Diff line number Diff line change
Expand Up @@ -56,7 +56,7 @@ Feature: About page

# When there is no abstract, the description should be shown in the homepage.
When I am logged in as a "moderator"
And I go to the "Fitness at work" collection edit form
And I go to the edit form of the "Fitness at work" collection
And I fill in "Abstract" with ""
And I press "Publish"
Then I should see the heading "Fitness at work"
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -204,7 +204,7 @@ Feature: Collection membership administration
# Check that Dr House can't edit the collection.
When I am logged in as "Gregory House"
And I go to the "Medical diagnosis" collection
Then I go to the "Medical diagnosis" collection edit form
And I go to the edit form of the "Medical diagnosis" collection
Then I should see the heading "Access denied"

# Dr Cuddy promotes Dr House to facilitator.
Expand All @@ -227,8 +227,7 @@ Feature: Collection membership administration

# Dr House can now edit the collection.
When I am logged in as "Gregory House"
And I go to the "Medical diagnosis" collection
Then I go to the "Medical diagnosis" collection edit form
And I go to the edit form of the "Medical diagnosis" collection
Then I should not see the heading "Access denied"

Scenario: Privileged members should be allowed to add users to a collection.
Expand Down
8 changes: 4 additions & 4 deletions tests/features/collection/last_update_time.feature
Original file line number Diff line number Diff line change
Expand Up @@ -74,8 +74,8 @@ Feature: Tests the collection last update time.
# The custom page is the newest thus will give the collection updated time.
Then the response should contain "2016-05-06T05:29"

And I go to the document content "Get Rid of Rats" edit screen
When I press "Update"
When I go to the edit form of the "Get Rid of Rats" document
And I press "Update"
# The updated time has changed to the current time but we cannot catch the
# time we ran the update.
Then the response should not contain "2016-05-06T05:29"
Expand All @@ -101,7 +101,7 @@ Feature: Tests the collection last update time.
Then I should see "about a minute ago"

# Editing the solution changes the last updated time.
Given I go to the "Roof Hole Cover" solution edit form
Given I go to the edit form of the "Roof Hole Cover" solution
And I select "Public Policy Cycle" from "Solution type"
And I select "Demography" from "Topic"
And I press "Publish"
Expand All @@ -113,7 +113,7 @@ Feature: Tests the collection last update time.
Then I should see "about a minute ago"

# Deleting the solution changes the last updated time.
Given I go to the "Roof Hole Cover" solution edit form
Given I go to the edit form of the "Roof Hole Cover" solution
And I click "Delete"
When I press "Delete"
And I go to the homepage of the "Household Wizard" collection
Expand Down
4 changes: 2 additions & 2 deletions tests/features/collection/propose.feature
Original file line number Diff line number Diff line change
Expand Up @@ -177,7 +177,7 @@ Feature: Proposing a collection
And the "Just a proposal" collection logo is image #3
And the "Just a proposal" collection banner is image #8

When I go to the "Just a proposal" collection edit form
Given I go to the edit form of the "Just a proposal" collection
And I click "Additional fields" tab
And I remove the file from the "Logo" field
But I wait for AJAX to finish
Expand All @@ -187,7 +187,7 @@ Feature: Proposing a collection
And I wait for AJAX to finish
And I press "Propose"

When I go to the "Just a proposal" collection edit form
When I go to the edit form of the "Just a proposal" collection
And I click "Additional fields" tab
Then I should see the link "logo.png"

Expand Down
2 changes: 1 addition & 1 deletion tests/features/communities/eif/solutions_page.feature
Original file line number Diff line number Diff line change
Expand Up @@ -65,7 +65,7 @@ Feature: As a user, visiting the EIF Toolbox page, I want to be able to filter
And the menu link "Solutions" is in the active trail

Given I am logged in as a moderator
When I go to the "Solution 3" solution edit form
When I go to the edit form of the "Solution 3" solution
And I select "Recommendation 7" from "EIF reference"
And I check the box "Semantic assets"
# Other require fields...
Expand Down
4 changes: 2 additions & 2 deletions tests/features/communities/eif/vocabulary.feature
Original file line number Diff line number Diff line change
Expand Up @@ -20,11 +20,11 @@ Feature:
| collection | EIF Toolbox |

Given I am logged in as a facilitator of the "Some EIF solution" solution
When I go to the "Some EIF solution" solution edit form
When I go to the edit form of the "Some EIF solution" solution
Then the following fields should not be present "EIF reference, EIF category"

Given I am logged in as a moderator
When I go to the "Some EIF solution" solution edit form
When I go to the edit form of the "Some EIF solution" solution
Then the following fields should be present "EIF reference, EIF category"

When I press "Publish"
Expand Down
4 changes: 2 additions & 2 deletions tests/features/communities/tallinn/dashboard.feature
Original file line number Diff line number Diff line change
Expand Up @@ -76,7 +76,7 @@ Feature:
Then the page should be cached

# Edit the group entity.
Given I go to the "Tallinn Ministerial Declaration" collection edit form
When I go to the edit form of the "Tallinn Ministerial Declaration" collection
And I fill in "Description" with "Hooli"
When I press "Publish"
And I go to "/api/v1/communities/tallinn/report"
Expand All @@ -85,7 +85,7 @@ Feature:
Then the page should be cached

# Edit any report.
Given I go to the tallinn_report content "Malta" edit screen
When I go to the edit form of the "Malta" "tallinn report"
And I press "Save"
When I go to "/api/v1/communities/tallinn/report"
Then the page should not be cached
Expand Down
10 changes: 5 additions & 5 deletions tests/features/communities/tallinn/permissions.feature
Original file line number Diff line number Diff line change
Expand Up @@ -181,7 +181,7 @@ Feature:
| France Report |
| Romania Report |

When I go to the "tallinn_report" content "Romania Report" edit screen
When I go to the edit form of the "Romania Report" "tallinn report"
And I press "Save"
And I go to the "Tallinn Ministerial Declaration" collection
And I click "Implementation monitoring" in the "Left sidebar" region
Expand All @@ -193,14 +193,14 @@ Feature:

# A moderator is able to change any report's author.
Given I am logged in as chef
When I visit the tallinn_report content "Romania Report" edit screen
When I go to the edit form of the "Romania Report" "tallinn report"
And I fill in "Authored by" with "dominique"
When I press "Save"
Then I should see the error message "The user dominique cannot be set as author of this report as he/she already owns 'France Report'."

# Test the same but as facilitator to verify the functionality for him as well.
Given I am logged in as "sherlock"
When I visit the tallinn_report content "Romania Report" edit screen
When I go to the edit form of the "Romania Report" "tallinn report"
And I fill in "Authored by" with "vasile"
When I press "Save"
Then I should see "Tallinn report Romania Report has been updated."
Expand All @@ -211,7 +211,7 @@ Feature:
# A user can change its own report but not other's. In
# the same time he's not able to change the node owner.
Given I am logged in as vasile
When I visit the tallinn_report content "Romania Report" edit screen
When I go to the edit form of the "Romania Report" "tallinn report"
Then I should get a 200 HTTP response
And the following fields should not be present "Authored by"

Expand All @@ -231,5 +231,5 @@ Feature:
And I should see "This is done"

# The user cannot edit a report owned by someone else.
Given I visit the tallinn_report content "France Report" edit screen
When I go to the edit form of the "France Report" "tallinn report"
Then I should get a 403 HTTP response
2 changes: 1 addition & 1 deletion tests/features/contact_information/access.feature
Original file line number Diff line number Diff line change
Expand Up @@ -36,5 +36,5 @@ Feature: Contact information access
| collection | user | roles |
| Ausy software solutions | Michiel Lucas | facilitator |
When I am logged in as "Michiel Lucas"
When I go to the "Ausy software solutions" collection edit form
When I go to the edit form of the "Ausy software solutions" collection
Then I should see the button "Edit" in the "Contact information inline form" region
Original file line number Diff line number Diff line change
Expand Up @@ -146,6 +146,6 @@ Feature: Contact Information moderation
And I click "Edit" in the "Entity actions"
And the following 1 button should be present "Update"
And I should see the link "Delete"
When I go to the "Saint Louis solutions" collection edit form
When I go to the edit form of the "Saint Louis solutions" collection
Then I should see the button "Edit" in the "Contact information inline form" region
Then I should see the button "Remove" in the "Contact information inline form" region
Original file line number Diff line number Diff line change
Expand Up @@ -398,7 +398,7 @@ Feature:
| 20 year anniversary |
| Rare Nintendo64 disk drive discovered |

Given I go to the news content "Current wars" edit screen
When I go to the edit form of the "Current wars" news
And I fill in "Short title" with "Current wars is over"
And I press "Update"
Then I should see the heading "Current wars is over"
Expand Down
2 changes: 1 addition & 1 deletion tests/features/glossary/glossary.feature
Original file line number Diff line number Diff line change
Expand Up @@ -373,7 +373,7 @@ Feature: As a moderator or group facilitator I want to be able to add, edit and
| Duplicate | dupe,DuPe | duplicate sysnonym | A World of Things |

# Hard to fill a multi-value field, so we'll pre-create it with duplicates.
When I go to the glossary content "Duplicate" edit screen
When I go to the edit form of the "Duplicate" glossary
And I press "Save"
Then I should see the error message "The 'DuPe' synonym is duplicated. Keep only one entry."

Expand Down
6 changes: 3 additions & 3 deletions tests/features/joinup_discussion/discussion.subscribe.feature
Original file line number Diff line number Diff line change
Expand Up @@ -96,13 +96,13 @@ Feature: Following discussions
# relevant fields are changed.
And the mail collector cache is empty
And I am logged in as "Dr. Hans Zarkov"
When I go to the discussion content "Rare Butter" edit screen
And I go to the edit form of the "Rare Butter" discussion
And I press "Update"
Then 0 e-mails should have been sent

# When relevant fields of a discussion are changed, the subscribers are
# receiving a notification.
Given I go to the discussion content "Rare Butter" edit screen
Given I go to the edit form of the "Rare Butter" discussion
And I fill in "Content" with "The old content was wrong."
And I press "Update"
Then the following email should have been sent:
Expand All @@ -125,7 +125,7 @@ Feature: Following discussions
# notification will be sent, regardless if a relevant field is changed.
Given the mail collector cache is empty
And I am logged in as a moderator
When I go to the discussion content "Rare Butter" edit screen
When I go to the edit form of the "Rare Butter" discussion
And I fill in "Content" with "Is this change triggering notifications?"
And I fill in "Motivation" with "Reporting this content..."
And I press "Report"
Expand Down
2 changes: 1 addition & 1 deletion tests/features/joinup_event/add_event.collection.feature
Original file line number Diff line number Diff line change
Expand Up @@ -129,7 +129,7 @@ Feature: "Add event" visibility options.
Given I am logged in as a moderator

# Upload works.
When I go to the event content "The Great Opening" edit screen
When I go to the edit form of the "The Great Opening" event
And I attach the file "logo.png" to "Logo"
And I wait for AJAX to finish

Expand Down
6 changes: 3 additions & 3 deletions tests/features/joinup_federation/import.feature
Original file line number Diff line number Diff line change
Expand Up @@ -236,7 +236,7 @@ Feature: As a site moderator I am able to import RDF files.
And the "Solution 2" solution should be affiliated with the "NIO" collection

# Check that the existing solution values were overridden.
Given I go to the "Solution 2" solution edit form
Given I go to the edit form of the "Solution 2" solution
Then the "Title" field should contain "Solution 2"
And the "Description" field should contain "This solution has a standalone distribution."

Expand All @@ -247,7 +247,7 @@ Feature: As a site moderator I am able to import RDF files.

# Verify that the collection owner can edit the new solutions.
When I am logged in as "CS Owner"
And I go to the "Solution 1" solution edit form
Given I go to the edit form of the "Solution 1" solution
Then the response status code should be 200

# Ensure that the og relation is set between the distribution and the solution.
Expand Down Expand Up @@ -310,7 +310,7 @@ Feature: As a site moderator I am able to import RDF files.
And the "Solution 3" solution should be affiliated with the "NIO" collection

# Check that the Topic value was not overridden.
Given I go to the "Solution 2" solution edit form
Given I go to the edit form of the "Solution 2" solution
# The text is '-E-health' because of the '-' prepended to children options.
And the option with text "-E-health" from select "Topic" is selected
And I press "Publish"
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -14,14 +14,14 @@ Feature:
| collection | Collection with child |

When I am logged in as a moderator
And I go to the "Collection with child" collection delete form
And I go to the delete form of the "Collection with child" collection
Then I should not see the button "Delete"
And I should see the heading "The collection Collection with child cannot be deleted because it contains the following solutions:"
But I should see the link "Child of collection with child"
And I should see the text "You can delete your solutions or transfer them to another collection."

Given I delete the "Child of collection with child" solution
And I go to the "Collection with child" collection delete form
And I go to the delete form of the "Collection with child" collection
Then I should see the heading "Are you sure you want to delete collection Collection with child?"
And I should see the text "This action cannot be undone."
When I press "Delete"
Expand Down
12 changes: 6 additions & 6 deletions tests/features/joinup_group/member_permissions_table.feature
Original file line number Diff line number Diff line change
Expand Up @@ -155,7 +155,7 @@ Feature: Group member permissions table
| title | state | collection | author |
| Election of Boy Archchancellor | validated | Approximate accuracy | Horace Worblehat |
| The Wizards' Excuse Me | draft | Approximate accuracy | Mustrum Ridcully |
When I go to the event content "Election of Boy Archchancellor" edit screen
When I go to the edit form of the "Election of Boy Archchancellor" event
Then I should see the button "Request deletion"
And I should see the button "Propose changes"
But I should not see the link "Delete"
Expand Down Expand Up @@ -198,7 +198,7 @@ Feature: Group member permissions table
| title | state | collection | author |
| Beating the bounds | validated | Dust, miscellaneous particles and filaments | Ponder Stibbons |
| Archchancellor Bowell's Remembrance's Bun and Penny | draft | Dust, miscellaneous particles and filaments | Mustrum Ridcully |
When I go to the event content "Beating the bounds" edit screen
When I go to the edit form of the "Beating the bounds" event
Then I should see the link "Delete"
And I should see the button "Update"
But I should not see the button "Request deletion"
Expand Down Expand Up @@ -247,7 +247,7 @@ Feature: Group member permissions table
| title | state | collection | author |
| The Convivium | validated | Creative uncertainty | Henry Porter |
| The Hunting of the Megapode | draft | Creative uncertainty | Mustrum Ridcully |
When I go to the event content "The Convivium" edit screen
When I go to the edit form of the "The Convivium" event
Then I should see the button "Request deletion"
And I should see the button "Propose changes"
But I should not see the link "Delete"
Expand Down Expand Up @@ -290,7 +290,7 @@ Feature: Group member permissions table
| title | state | collection | author |
| Gaudy night | validated | Woolly thinking | Rincewind |
| Archchancellor Preserved Bigger's Bequest | draft | Woolly thinking | Mustrum Ridcully |
When I go to the event content "Gaudy night" edit screen
When I go to the edit form of the "Gaudy night" event
Then I should see the link "Delete"
And I should see the button "Update"
But I should not see the button "Request deletion"
Expand Down Expand Up @@ -401,7 +401,7 @@ Feature: Group member permissions table
| title | state | solution | author |
| Head of the River | validated | Prehumous morbid bibliomancy | Dr. John Hicks |
| Poore Boys Funne | draft | Prehumous morbid bibliomancy | Mustrum Ridcully |
When I go to the event content "Head of the River" edit screen
When I go to the edit form of the "Head of the River" event
Then I should see the button "Request deletion"
And I should see the button "Propose changes"
But I should not see the link "Delete"
Expand Down Expand Up @@ -444,7 +444,7 @@ Feature: Group member permissions table
| title | state | collection | author |
| May Morning | validated | Posthumous morbid bibliomancy | Hex |
| A veritable heyhoe-rumbledown | draft | Posthumous morbid bibliomancy | Mustrum Ridcully |
When I go to the event content "May Morning" edit screen
When I go to the edit form of the "May Morning" event
Then I should see the link "Delete"
And I should see the button "Update"
But I should not see the button "Request deletion"
Expand Down
Loading

0 comments on commit a143042

Please sign in to comment.