Skip to content

Commit

Permalink
Address Webtest breakage
Browse files Browse the repository at this point in the history
  • Loading branch information
MKodde committed Jul 8, 2024
1 parent 16988f7 commit 938ea10
Show file tree
Hide file tree
Showing 5 changed files with 14 additions and 4 deletions.
3 changes: 3 additions & 0 deletions tests/webtests/EntityDeleteTest.php
Original file line number Diff line number Diff line change
Expand Up @@ -58,6 +58,7 @@ public function test_delete_a_published_test_entity()
->form();

self::$pantherClient->submit($form);
self::$pantherClient->wait(2);
self::assertOnPage('Your entity is deleted');
}

Expand Down Expand Up @@ -86,6 +87,7 @@ public function test_delete_a_unpublished_production_entity()
->form();

self::$pantherClient->submit($form);
self::$pantherClient->wait(2);
self::assertOnPage('Your entity is deleted');

}
Expand Down Expand Up @@ -117,6 +119,7 @@ public function test_request_delete_a_published_production_entity_jira_not_avail
->form();

self::$pantherClient->submit($form);
self::$pantherClient->wait(2);
$this->assertOnPage(
'Oops, creating the delete request failed. Our ticket service might have been offline. Please try again at a later time.'
);
Expand Down
6 changes: 3 additions & 3 deletions tests/webtests/EntityDetailTest.php
Original file line number Diff line number Diff line change
Expand Up @@ -77,9 +77,9 @@ public function test_render_details_of_manage_entity()
$this->assertDetailEquals(0, 'Metadata URL', 'https://sp1-entityid.example.com/metadata');
$this->assertDetailsAscLocationEquals(1, 'ACS location', 'https://sp1-entityid.example.com/acs');
$this->assertDetailEquals(2, 'Entity ID', 'https://sp1-entityid.example.com');
$this->assertDetailEquals(8, 'Name EN', 'SP3 Name English');
$this->assertDetailEquals(10, 'First name', 'givenname', true);
$this->assertDetailEquals(11, 'Last name', 'surname', false);
$this->assertDetailEquals(9, 'Name EN', 'SP3 Name English');
$this->assertDetailEquals(11, 'First name', 'givenname');
$this->assertDetailEquals(12, 'Last name', 'surname', false);
}


Expand Down
5 changes: 4 additions & 1 deletion tests/webtests/EntityEditTest.php
Original file line number Diff line number Diff line change
Expand Up @@ -154,6 +154,8 @@ public function test_it_loads_xml_from_textarea()
self::fillFormField($formElement, '#dashboard_bundle_entity_type_attributes_commonNameAttribute_motivation', 'foo');
self::fillFormField($formElement, '#dashboard_bundle_entity_type_attributes_organizationAttribute_motivation', 'foo');
self::fillFormField($formElement, '#dashboard_bundle_entity_type_attributes_personalCodeAttribute_motivation', 'foo');
// Also check a type of service (as they are mandatory)
self::checkFormField($formElement, '#dashboard_bundle_entity_type_metadata_typeOfService_2');
self::findBy('#dashboard_bundle_entity_type_publishButton')->click();

$pageTitle = self::$pantherClient->refreshCrawler()->filter('h1')->first()->text();
Expand Down Expand Up @@ -287,6 +289,7 @@ private function buildValidFormData()
'dashboard_bundle_entity_type[metadata][descriptionEn]' => 'SURF SP2 Description English',
'dashboard_bundle_entity_type[metadata][applicationUrl]' => '',
'dashboard_bundle_entity_type[metadata][eulaUrl]' => '',
'dashboard_bundle_entity_type[metadata][typeOfService][]' => 'Research',
'dashboard_bundle_entity_type[contactInformation][administrativeContact][firstName]' => 'Jane',
'dashboard_bundle_entity_type[contactInformation][administrativeContact][lastName]' => 'Doe',
'dashboard_bundle_entity_type[contactInformation][administrativeContact][email]' => '[email protected]',
Expand All @@ -299,7 +302,7 @@ private function buildValidFormData()
'dashboard_bundle_entity_type[contactInformation][supportContact][lastName]' => 'surname',
'dashboard_bundle_entity_type[contactInformation][supportContact][email]' => '[email protected]',
'dashboard_bundle_entity_type[contactInformation][supportContact][phone]' => 'telephonenumber',
'dashboard_bundle_entity_type[comments][comments]' => 'I need a new name NL'
'dashboard_bundle_entity_type[comments][comments]' => 'I need a new name NL',
];

foreach ($attributes as $attribute) {
Expand Down
2 changes: 2 additions & 0 deletions tests/webtests/Manage/Client/template/oidc10.json
Original file line number Diff line number Diff line change
Expand Up @@ -65,6 +65,8 @@
"OrganizationURL:nl": "%5$s Organisation Url Dutch",
"coin:service_team_id": "%7$s",
"coin:institution_id": "%8$s",
"coin:ss:type_of_service:en": "Research",
"coin:ss:type_of_service:nl": "Research",
"isPublicClient": true
},
"allowedEntities": [],
Expand Down
2 changes: 2 additions & 0 deletions tests/webtests/Manage/Client/template/saml20_sp.json
Original file line number Diff line number Diff line change
Expand Up @@ -65,6 +65,8 @@
"OrganizationURL:nl": "%5$s Organisation Url Dutch",
"coin:service_team_id": "%7$s",
"coin:institution_id": "%8$s",
"coin:ss:type_of_service:en": "Research",
"coin:ss:type_of_service:nl": "Research",
"logo:0:url": "%3$s\/images\/logo.png",
"logo:0:width": 100,
"logo:0:height": 100,
Expand Down

0 comments on commit 938ea10

Please sign in to comment.