Skip to content
Snippets Groups Projects
Commit 3f63fd12 authored by Claudiu Cristea's avatar Claudiu Cristea
Browse files

ISAICP-7466: Fix the URL alias for IOPE news page.

parent c3e4acd8
No related branches found
No related tags found
1 merge request!58ISAICP-7466: Can't add news
@api @group-clone
Feature: Covers \joinup_core_deploy_108900().
Scenario: Test that news creation works.
Given I am logged in as a moderator
And I am on the homepage
When I click "Interoperable Europe"
And I click "News"
Then the url should match "/interoperable-europe/latest-news"
When I click "Add news" in the plus button menu
Then the response status code should be 200
And the url should match "/interoperable-europe/news/add"
And I should see the heading "Add news"
...@@ -13,3 +13,17 @@ ...@@ -13,3 +13,17 @@
*/ */
declare(strict_types = 1); declare(strict_types = 1);
use Drupal\pathauto\PathautoState;
/**
* Fix Interoperable Europe news creation link.
*/
function joinup_core_deploy_108900(): void {
$entityTypeManager = \Drupal::entityTypeManager();
$entityTypeManager->getStorage('node')->load(704825)->set('path', [
'pathauto' => PathautoState::SKIP,
'alias' => '/interoperable-europe/latest-news',
])->save();
$entityTypeManager->getStorage('path_alias')->load(84170)->delete();
}
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment