From 1563bc1645557a9a4ad91cf73ae078e8f4368314 Mon Sep 17 00:00:00 2001 From: Mike Decker Date: Tue, 24 Oct 2023 18:00:27 -0700 Subject: [PATCH 1/3] Adjust event card test --- .github/workflows/tests.yml | 2 +- tests/codeception/acceptance/Content/EventsCest.php | 2 ++ 2 files changed, 3 insertions(+), 1 deletion(-) diff --git a/.github/workflows/tests.yml b/.github/workflows/tests.yml index a4ed0d5e6..108caca1b 100644 --- a/.github/workflows/tests.yml +++ b/.github/workflows/tests.yml @@ -67,7 +67,7 @@ jobs: STANFORD_ENCRYPT: ${{ secrets.STANFORD_ENCRYPT }} run: | composer global require su-sws/stanford-caravan:10.x-dev - ~/.composer/vendor/bin/sws-caravan codeception /var/www/html --extension-dir=$GITHUB_WORKSPACE/project --suites=acceptance + ~/.composer/vendor/bin/sws-caravan codeception /var/www/html --extension-dir=$GITHUB_WORKSPACE/project --suites=acceptance --group=eventcard - name: Save Test Results uses: actions/upload-artifact@v3 if: always() diff --git a/tests/codeception/acceptance/Content/EventsCest.php b/tests/codeception/acceptance/Content/EventsCest.php index 38b84e94b..a83540d77 100644 --- a/tests/codeception/acceptance/Content/EventsCest.php +++ b/tests/codeception/acceptance/Content/EventsCest.php @@ -343,6 +343,8 @@ public function testClone(AcceptanceTester $I) { /** * Test event card markup. + * + * @group eventcard */ public function testEventCard(AcceptanceTester $I) { $event = $this->createEventNode($I); From ec09b48b9829294802c1d0e12594ba0cfdf53ea9 Mon Sep 17 00:00:00 2001 From: Mike Decker Date: Tue, 24 Oct 2023 18:03:40 -0700 Subject: [PATCH 2/3] only 1 test --- .github/workflows/tests.yml | 2 +- .../AuthenticatedPermissionsCest.php | 18 +++++------ .../acceptance/Content/BasicPageCest.php | 24 +++++++------- .../acceptance/Content/CoursesCest.php | 4 +-- .../acceptance/Content/CustomBlockCest.php | 2 +- .../acceptance/Content/DefaultContentCest.php | 10 +++--- .../acceptance/Content/EventsCest.php | 20 ++++++------ .../acceptance/Content/EventsSeriesCest.php | 12 +++---- .../acceptance/Content/NewsCest.php | 18 +++++------ .../acceptance/Content/PersonCest.php | 24 +++++++------- .../acceptance/Content/PolicyCest.php | 8 ++--- .../acceptance/Content/PublicationsCest.php | 14 ++++---- .../acceptance/Content/SearchBlockCest.php | 2 +- .../acceptance/Contrib/ConfigReadonlyCest.php | 2 +- .../acceptance/Contrib/MenuBlockCest.php | 2 +- .../Contrib/NodeRevisionDeleteCest.php | 2 +- .../acceptance/Contrib/ViewsBulkEditCest.php | 2 +- .../acceptance/Contrib/XmlsitemapCest.php | 2 +- .../GlobalMessage/GlobalMessageCest.php | 14 ++++---- tests/codeception/acceptance/HomePageCest.php | 4 +-- .../LocalFooter/LocalFooterCest.php | 8 ++--- .../LocalFooter/LocalFooterLockupCest.php | 28 ++++++++-------- .../LockupSettings/LockupSettingsCest.php | 30 ++++++++--------- .../LockupSettingsPermsCest.php | 6 ++-- .../acceptance/Media/MediaCest.php | 22 ++++++------- .../acceptance/Media/MediaFormsCest.php | 2 +- .../acceptance/Media/MediaPermissionsCest.php | 10 +++--- .../Paragraphs/Issue2901390Cest.php | 2 +- .../acceptance/Paragraphs/ListsCest.php | 32 +++++++++---------- .../Paragraphs/MediaWithCaptionCest.php | 2 +- .../Paragraphs/StanfordCardCest.php | 4 +-- tests/codeception/acceptance/SubThemeCest.php | 4 +-- .../SuperFooter/SuperFooterCest.php | 14 ++++---- tests/codeception/acceptance/SystemCest.php | 2 +- .../acceptance/SystemSiteConfigCest.php | 4 +-- .../acceptance/TextFormatsCest.php | 2 +- .../acceptance/Users/DefaultUsersCest.php | 2 +- .../acceptance/Users/IntranetCest.php | 8 ++--- .../acceptance/Users/RolesCest.php | 18 +++++------ 39 files changed, 193 insertions(+), 193 deletions(-) diff --git a/.github/workflows/tests.yml b/.github/workflows/tests.yml index 108caca1b..a4ed0d5e6 100644 --- a/.github/workflows/tests.yml +++ b/.github/workflows/tests.yml @@ -67,7 +67,7 @@ jobs: STANFORD_ENCRYPT: ${{ secrets.STANFORD_ENCRYPT }} run: | composer global require su-sws/stanford-caravan:10.x-dev - ~/.composer/vendor/bin/sws-caravan codeception /var/www/html --extension-dir=$GITHUB_WORKSPACE/project --suites=acceptance --group=eventcard + ~/.composer/vendor/bin/sws-caravan codeception /var/www/html --extension-dir=$GITHUB_WORKSPACE/project --suites=acceptance - name: Save Test Results uses: actions/upload-artifact@v3 if: always() diff --git a/tests/codeception/acceptance/AuthenticatedPermissionsCest.php b/tests/codeception/acceptance/AuthenticatedPermissionsCest.php index 036299090..e62e6f9d8 100644 --- a/tests/codeception/acceptance/AuthenticatedPermissionsCest.php +++ b/tests/codeception/acceptance/AuthenticatedPermissionsCest.php @@ -49,7 +49,7 @@ public function _after(AcceptanceTester $I) { /** * Make sure authenticated users can't access things they should not. */ - public function testAuthenticatedUserRestrictions(AcceptanceTester $I) { + protected function footestAuthenticatedUserRestrictions(AcceptanceTester $I) { $I->logInWithRole('authenticated'); $I->amOnPage('/'); $I->canSeeResponseCodeIs(200); @@ -76,7 +76,7 @@ public function testAuthenticatedUserRestrictions(AcceptanceTester $I) { /** * Make sure authenticated users can access things they should. */ - public function testAuthenticatedUserPermissions(AcceptanceTester $I) { + protected function footestAuthenticatedUserPermissions(AcceptanceTester $I) { $I->logInWithRole('authenticated'); $I->amOnPage('/patterns'); $I->canSeeResponseCodeIs(200); @@ -85,7 +85,7 @@ public function testAuthenticatedUserPermissions(AcceptanceTester $I) { /** * Site Manager cannot escalate their own role above Site Manager. */ - public function testSiteManagerEscalationSelf(AcceptanceTester $I) { + protected function footestSiteManagerEscalationSelf(AcceptanceTester $I) { $site_manager = $I->logInWithRole('site_manager'); $site_manager_id = $site_manager->id(); $I->amOnPage('/admin/users'); @@ -101,7 +101,7 @@ public function testSiteManagerEscalationSelf(AcceptanceTester $I) { /** * Site Manager cannot escalate others' role above Site Manager. */ - public function testSiteManagerEscalationOthers(AcceptanceTester $I) { + protected function footestSiteManagerEscalationOthers(AcceptanceTester $I) { $I->logInWithRole('site_manager'); $I->amOnPage('/admin/users'); $I->canSee('Morgan'); @@ -115,7 +115,7 @@ public function testSiteManagerEscalationOthers(AcceptanceTester $I) { /** * PHP code is not allowed in redirects. */ - public function testPhpInRedirect(AcceptanceTester $I) { + protected function footestPhpInRedirect(AcceptanceTester $I) { $I->logInWithRole('site_manager'); $I->amOnPage('/admin/config/search/redirect/add'); $I->fillField('#edit-redirect-source-0-path', 'home'); @@ -128,7 +128,7 @@ public function testPhpInRedirect(AcceptanceTester $I) { /** * PHP code is escaped and not run when added to content. */ - public function testPhpInContent(AcceptanceTester $I) { + protected function footestPhpInContent(AcceptanceTester $I) { $I->logInWithRole('site_manager'); $I->amOnPage('/node/add/stanford_page'); $I->fillField('#edit-title-0-value', ''); @@ -140,7 +140,7 @@ public function testPhpInContent(AcceptanceTester $I) { /** * PHP files are not allowed as uploads for favicons. */ - public function testPhpUploadInFavicon(AcceptanceTester $I) { + protected function footestPhpUploadInFavicon(AcceptanceTester $I) { $I->logInWithRole('administrator'); $I->amOnPage('/admin/appearance/settings'); $I->seeCheckboxIsChecked('#edit-default-favicon'); @@ -156,7 +156,7 @@ public function testPhpUploadInFavicon(AcceptanceTester $I) { /** * PHP files are not allowed as uploads for the logo. */ - public function testPhpUploadInLogo(AcceptanceTester $I) { + protected function footestPhpUploadInLogo(AcceptanceTester $I) { $I->logInWithRole('administrator'); $I->amOnPage('/admin/appearance/settings'); $I->seeCheckboxIsChecked('#edit-default-logo'); @@ -173,7 +173,7 @@ public function testPhpUploadInLogo(AcceptanceTester $I) { /** * Vocabs aren't seen if there are no permissions for them. */ - public function testTaxonomyOverviewPage(AcceptanceTester $I) { + protected function footestTaxonomyOverviewPage(AcceptanceTester $I) { $name = $this->faker->firstName; $vocab = $I->createEntity([ 'vid' => strtolower($name), diff --git a/tests/codeception/acceptance/Content/BasicPageCest.php b/tests/codeception/acceptance/Content/BasicPageCest.php index 8f72a425f..fcf227af9 100644 --- a/tests/codeception/acceptance/Content/BasicPageCest.php +++ b/tests/codeception/acceptance/Content/BasicPageCest.php @@ -29,7 +29,7 @@ public function __construct() { * @group pathauto * @group menu_link_weight */ - public function testCreatingPage(AcceptanceTester $I) { + protected function footestCreatingPage(AcceptanceTester $I) { $node_title = $this->faker->text(20); $node = $I->createEntity([ 'type' => 'stanford_page', @@ -72,7 +72,7 @@ public function testCreatingPage(AcceptanceTester $I) { /** * Test deleting menu items clears them from the main menu. */ - public function testDeletedMenuItems(AcceptanceTester $I) { + protected function footestDeletedMenuItems(AcceptanceTester $I) { $node_title = $this->faker->text(20); $node = $I->createEntity([ 'type' => 'stanford_page', @@ -100,7 +100,7 @@ public function testDeletedMenuItems(AcceptanceTester $I) { /** * Number of h1 tags should always be 1. */ - public function testH1Tags(AcceptanceTester $I) { + protected function footestH1Tags(AcceptanceTester $I) { $I->amOnPage('/' . $this->faker->text); $I->canSeeResponseCodeIs(404); $I->canSeeNumberOfElements('h1', 1); @@ -116,7 +116,7 @@ public function testH1Tags(AcceptanceTester $I) { * * Regression test for D8CORE-1547. */ - public function testRevisionPage(AcceptanceTester $I) { + protected function footestRevisionPage(AcceptanceTester $I) { $title = $this->faker->words(3, TRUE); $I->logInWithRole('site_manager'); $node = $I->createEntity(['title' => $title, 'type' => 'stanford_page']); @@ -128,7 +128,7 @@ public function testRevisionPage(AcceptanceTester $I) { /** * There should be Page Metadata fields */ - public function testPageDescription(AcceptanceTester $I) { + protected function footestPageDescription(AcceptanceTester $I) { $title = $this->faker->words(3, TRUE); $description = $this->faker->words(10, TRUE); $type_term = $I->createEntity([ @@ -150,7 +150,7 @@ public function testPageDescription(AcceptanceTester $I) { /** * Test that the vocabulary and default terms exist. */ - public function testBasicPageVocabularyTermsExists(AcceptanceTester $I) { + protected function footestBasicPageVocabularyTermsExists(AcceptanceTester $I) { $I->logInWithRole('site_manager'); $I->amOnPage("/admin/structure/taxonomy/manage/basic_page_types/overview"); $I->canSeeResponseCodeIs(200); @@ -167,7 +167,7 @@ public function testBasicPageVocabularyTermsExists(AcceptanceTester $I) { * * @group menu_link_weight */ - public function testUnpublishedMenuItems(AcceptanceTester $I) { + protected function footestUnpublishedMenuItems(AcceptanceTester $I) { $unpublished_title = $this->faker->words(5, TRUE); $unpublished_node = $I->createEntity([ 'type' => 'stanford_page', @@ -205,7 +205,7 @@ public function testUnpublishedMenuItems(AcceptanceTester $I) { /** * Clone a basic page. */ - public function testClone(AcceptanceTester $I) { + protected function footestClone(AcceptanceTester $I) { $title = $this->faker->words(3, TRUE); $I->logInWithRole('contributor'); @@ -228,7 +228,7 @@ public function testClone(AcceptanceTester $I) { * * @group scheduler */ - public function testScheduler(AcceptanceTester $I) { + protected function footestScheduler(AcceptanceTester $I) { $time = \Drupal::time(); /** @var \Drupal\system\TimeZoneResolver $timezone_resolver */ @@ -257,7 +257,7 @@ public function testScheduler(AcceptanceTester $I) { /** * Validate the Spacer Paragraph type exists */ - public function testSpacerParagraph(AcceptanceTester $I) { + protected function footestSpacerParagraph(AcceptanceTester $I) { $I->logInWithRole('administrator'); $I->amOnPage('/admin/structure/paragraphs_type'); $I->canSee('Spacer'); @@ -269,7 +269,7 @@ public function testSpacerParagraph(AcceptanceTester $I) { * * @group metadata */ - public function testMetaData(AcceptanceTester $I) { + protected function footestMetaData(AcceptanceTester $I) { $values = [ 'banner_image_alt' => $this->faker->words(3, TRUE), 'meta_image_alt' => $this->faker->words(3, TRUE), @@ -364,7 +364,7 @@ public function testMetaData(AcceptanceTester $I) { /** * @group search-results */ - public function testSearchResult(AcceptanceTester $I) { + protected function footestSearchResult(AcceptanceTester $I) { $text = $this->faker->paragraphs(2, TRUE); $wysiwyg = $I->createEntity([ 'type' => 'stanford_wysiwyg', diff --git a/tests/codeception/acceptance/Content/CoursesCest.php b/tests/codeception/acceptance/Content/CoursesCest.php index 3a2143963..c26a4f456 100644 --- a/tests/codeception/acceptance/Content/CoursesCest.php +++ b/tests/codeception/acceptance/Content/CoursesCest.php @@ -24,7 +24,7 @@ public function __construct() { /** * Test for view pages and taxonomy functionality */ - public function testViewPagesExist(AcceptanceTester $I) { + protected function footestViewPagesExist(AcceptanceTester $I) { $I->logInWithRole('administrator'); $quarters_term = $this->createCourseQuartersTerm($I); $subject_term = $this->createCourseSubjectsTerm($I); @@ -63,7 +63,7 @@ public function testViewPagesExist(AcceptanceTester $I) { /** * Test rabbit hole settings and field locking */ - public function testRabbitHoleRedirects(AcceptanceTester $I) { + protected function footestRabbitHoleRedirects(AcceptanceTester $I) { $I->logInWithRole('administrator'); $quarters_term = $this->createCourseQuartersTerm($I); $subject_term = $this->createCourseSubjectsTerm($I); diff --git a/tests/codeception/acceptance/Content/CustomBlockCest.php b/tests/codeception/acceptance/Content/CustomBlockCest.php index a15d5da0f..189e95961 100644 --- a/tests/codeception/acceptance/Content/CustomBlockCest.php +++ b/tests/codeception/acceptance/Content/CustomBlockCest.php @@ -22,7 +22,7 @@ public function __construct() { /** * Site managers should be able to edit custom blocks. */ - public function testCustomBlockAccess(AcceptanceTester $I) { + protected function footestCustomBlockAccess(AcceptanceTester $I) { $block = $I->createEntity([ 'type' => 'stanford_component_block', 'info' => $this->faker->word(3, TRUE), diff --git a/tests/codeception/acceptance/Content/DefaultContentCest.php b/tests/codeception/acceptance/Content/DefaultContentCest.php index 5f2da6f17..e9172f6da 100644 --- a/tests/codeception/acceptance/Content/DefaultContentCest.php +++ b/tests/codeception/acceptance/Content/DefaultContentCest.php @@ -10,7 +10,7 @@ class DefaultContentCest { /** * Test default images. */ - public function testDefaultImages(AcceptanceTester $I) { + protected function footestDefaultImages(AcceptanceTester $I) { $files = \Drupal::entityTypeManager()->getStorage('file')->loadMultiple(); /** @var \Drupal\file\FileInterface $file */ @@ -30,7 +30,7 @@ public function testDefaultImages(AcceptanceTester $I) { /** * Default content pages and meta data exist. */ - public function testExistingContent(AcceptanceTester $I) { + protected function footestExistingContent(AcceptanceTester $I) { $pages = [ '/', '/resources', @@ -49,7 +49,7 @@ public function testExistingContent(AcceptanceTester $I) { /** * There should be at least 15 media items. */ - public function testMedia(AcceptanceTester $I) { + protected function footestMedia(AcceptanceTester $I) { $I->logInWithRole('administrator'); $I->amOnPage('/admin/content/media'); $I->canSeeNumberOfElements('table img, form img', [15, 999]); @@ -58,7 +58,7 @@ public function testMedia(AcceptanceTester $I) { /** * XML Sitemap should exist after cron. */ - public function testXmlSitemap(AcceptanceTester $I) { + protected function footestXmlSitemap(AcceptanceTester $I) { $I->runDrush('cron'); $I->amOnPage('/sitemap.xml'); $I->canSeeResponseCodeIs(200); @@ -69,7 +69,7 @@ public function testXmlSitemap(AcceptanceTester $I) { * * @group menu_link_weight */ - public function testMenuItems(AcceptanceTester $I) { + protected function footestMenuItems(AcceptanceTester $I) { $I->logInWithRole('site_manager'); $I->amOnPage('/admin/structure/menu/manage/main'); diff --git a/tests/codeception/acceptance/Content/EventsCest.php b/tests/codeception/acceptance/Content/EventsCest.php index a83540d77..66c26956c 100644 --- a/tests/codeception/acceptance/Content/EventsCest.php +++ b/tests/codeception/acceptance/Content/EventsCest.php @@ -36,7 +36,7 @@ public function _after(AcceptanceTester $I) { * * @group D8CORE-4858 */ - public function testListIntro(AcceptanceTester $I) { + protected function footestListIntro(AcceptanceTester $I) { // Start with no events. $nodes = \Drupal::entityTypeManager() ->getStorage('node') @@ -97,7 +97,7 @@ public function testListIntro(AcceptanceTester $I) { /** * Ensure events are in the sitemap. */ - public function testXMLSiteMap(AcceptanceTester $I) { + protected function footestXMLSiteMap(AcceptanceTester $I) { $I->logInWithRole('administrator'); $I->amOnPage('/admin/config/search/xmlsitemap/settings/node/stanford_event'); $I->seeOptionIsSelected('#edit-xmlsitemap-status', 'Included'); @@ -107,7 +107,7 @@ public function testXMLSiteMap(AcceptanceTester $I) { /** * Test Page Title Conditions. */ - public function testPageTitleIgnoreCondition(AcceptanceTester $I) { + protected function footestPageTitleIgnoreCondition(AcceptanceTester $I) { $I->logInWithRole('administrator'); // Todo: make theme name dynamic. $I->amOnPage('/admin/structure/block/manage/stanford_basic_pagetitle'); @@ -121,7 +121,7 @@ public function testPageTitleIgnoreCondition(AcceptanceTester $I) { /** * Test the event content type exists and has at least a couple of fields. */ - public function testContentTypeExists(AcceptanceTester $I) { + protected function footestContentTypeExists(AcceptanceTester $I) { $I->logInWithRole('administrator'); $I->amOnPage('/admin/structure/types/manage/stanford_event/fields'); $I->canSee('body'); @@ -148,7 +148,7 @@ public function testContentTypeExists(AcceptanceTester $I) { /** * Test Access to stuff for contrib role. */ - public function testContributorPerms(AcceptanceTester $I) { + protected function footestContributorPerms(AcceptanceTester $I) { $I->logInWithRole('contributor'); // Can create a node. @@ -188,7 +188,7 @@ public function testContributorPerms(AcceptanceTester $I) { /** * Test thing. */ - public function testEditorPerms(AcceptanceTester $I) { + protected function footestEditorPerms(AcceptanceTester $I) { $I->logInWithRole('site_editor'); // Can create a node. @@ -233,7 +233,7 @@ public function testEditorPerms(AcceptanceTester $I) { /** * Test thing. */ - public function testSiteManagerPerms(AcceptanceTester $I) { + protected function footestSiteManagerPerms(AcceptanceTester $I) { $I->logInWithRole('site_manager'); // Can create a node. @@ -277,7 +277,7 @@ public function testSiteManagerPerms(AcceptanceTester $I) { /** * Test to make sure the main menu link is there. */ - public function testDefaultContentExists(AcceptanceTester $I) { + protected function footestDefaultContentExists(AcceptanceTester $I) { $I->logInWithRole('administrator'); // Events Main Menu Link. $I->amOnPage('/admin/structure/menu/manage/main'); @@ -287,7 +287,7 @@ public function testDefaultContentExists(AcceptanceTester $I) { /** * Published checkbox should be hidden on term edit pages. */ - public function testTermPublishing(AcceptanceTester $I) { + protected function footestTermPublishing(AcceptanceTester $I) { $I->logInWithRole('site_manager'); $term = $I->createEntity([ 'vid' => 'event_audience', @@ -307,7 +307,7 @@ public function testTermPublishing(AcceptanceTester $I) { /** * Clone events get incremented date. */ - public function testClone(AcceptanceTester $I) { + protected function footestClone(AcceptanceTester $I) { $user = $I->createUserWithRoles(['contributor']); /** @var \Drupal\node\NodeInterface $node */ $node = $this->createEventNode($I); diff --git a/tests/codeception/acceptance/Content/EventsSeriesCest.php b/tests/codeception/acceptance/Content/EventsSeriesCest.php index 0b47c220b..479550d9b 100644 --- a/tests/codeception/acceptance/Content/EventsSeriesCest.php +++ b/tests/codeception/acceptance/Content/EventsSeriesCest.php @@ -26,7 +26,7 @@ public function __construct() { /** * Ensure events are in the sitemap. */ - public function testXMLSiteMap(AcceptanceTester $I) { + protected function footestXMLSiteMap(AcceptanceTester $I) { $I->logInWithRole('administrator'); $I->amOnPage('/admin/config/search/xmlsitemap/settings/node/stanford_event_series'); $I->seeOptionIsSelected('#edit-xmlsitemap-status', 'Included'); @@ -36,7 +36,7 @@ public function testXMLSiteMap(AcceptanceTester $I) { /** * Test Page Title Conditions. */ - public function testPageTitleIgnoreCondition(AcceptanceTester $I) { + protected function footestPageTitleIgnoreCondition(AcceptanceTester $I) { $I->logInWithRole('administrator'); // Todo: make theme name dynamic. $I->amOnPage('/admin/structure/block/manage/stanford_basic_pagetitle'); @@ -50,7 +50,7 @@ public function testPageTitleIgnoreCondition(AcceptanceTester $I) { /** * Test the the event content type exists and has at least a couple of fields. */ - public function testContentTypeExists(AcceptanceTester $I) { + protected function footestContentTypeExists(AcceptanceTester $I) { $I->logInWithRole('administrator'); $I->amOnPage('/admin/structure/types/manage/stanford_event_series/fields'); $I->canSee('su_event_series_subheadline'); @@ -60,7 +60,7 @@ public function testContentTypeExists(AcceptanceTester $I) { /** * Test Access to stuff for contrib role. */ - public function testContributorPerms(AcceptanceTester $I) { + protected function footestContributorPerms(AcceptanceTester $I) { $I->logInWithRole('contributor'); // D8CORE-4551: Can NOT create a node. @@ -85,7 +85,7 @@ public function testContributorPerms(AcceptanceTester $I) { /** * Test thing. */ - public function testEditorPerms(AcceptanceTester $I) { + protected function footestEditorPerms(AcceptanceTester $I) { $I->logInWithRole('site_editor'); // Can create a node. @@ -115,7 +115,7 @@ public function testEditorPerms(AcceptanceTester $I) { /** * Test thing. */ - public function testSiteManagerPerms(AcceptanceTester $I) { + protected function footestSiteManagerPerms(AcceptanceTester $I) { $I->logInWithRole('site_manager'); // Can create a node. diff --git a/tests/codeception/acceptance/Content/NewsCest.php b/tests/codeception/acceptance/Content/NewsCest.php index 4e00a502c..84fa98b10 100644 --- a/tests/codeception/acceptance/Content/NewsCest.php +++ b/tests/codeception/acceptance/Content/NewsCest.php @@ -26,7 +26,7 @@ public function __construct() { /** * News list intro block is at the top of the page. */ - public function testListIntro(AcceptanceTester $I) { + protected function footestListIntro(AcceptanceTester $I) { $I->logInWithRole('site_manager'); $I->amOnPage('/news'); $I->canSeeResponseCodeIs(200); @@ -35,7 +35,7 @@ public function testListIntro(AcceptanceTester $I) { /** * Test that the default content has installed and is unpublished. */ - public function testDefaultContentExists(AcceptanceTester $I) { + protected function footestDefaultContentExists(AcceptanceTester $I) { $I->logInWithRole('administrator'); $I->amOnPage("/admin/content"); $I->see("Sample: Smith Conference"); @@ -57,7 +57,7 @@ public function testDefaultContentExists(AcceptanceTester $I) { /** * Test that the vocabulary and terms exist. */ - public function testVocabularyTermsExists(AcceptanceTester $I) { + protected function footestVocabularyTermsExists(AcceptanceTester $I) { $I->logInWithRole('administrator'); $I->amOnPage("/admin/structure/taxonomy/manage/stanford_news_topics/overview"); $I->canSeeNumberOfElements("input.term-id", [2, 99]); @@ -66,7 +66,7 @@ public function testVocabularyTermsExists(AcceptanceTester $I) { /** * Test that the view pages exist. */ - public function testViewPagesExist(AcceptanceTester $I) { + protected function footestViewPagesExist(AcceptanceTester $I) { $I->amOnPage("/news"); $I->seeLink('Announcement'); $I->click("a[href='/news/announcement']"); @@ -77,7 +77,7 @@ public function testViewPagesExist(AcceptanceTester $I) { /** * Validate external content redirect. */ - public function testExternalSourceArticle(AcceptanceTester $I) { + protected function footestExternalSourceArticle(AcceptanceTester $I) { $node = $I->createEntity([ 'type' => 'stanford_news', 'title' => $this->faker->words(3, TRUE), @@ -98,7 +98,7 @@ public function testExternalSourceArticle(AcceptanceTester $I) { * Test that only two of three new news nodes show up in the more news view * on the node page. */ - public function testMoreNewsView(AcceptanceTester $I) { + protected function footestMoreNewsView(AcceptanceTester $I) { $I->logInWithRole('administrator'); $first_news = $I->createEntity([ @@ -121,7 +121,7 @@ public function testMoreNewsView(AcceptanceTester $I) { /** * Test that the XML sitemap and metatag configuration is set. */ - public function testXMLMetaDataRevisions(AcceptanceTester $I) { + protected function footestXMLMetaDataRevisions(AcceptanceTester $I) { $I->logInWithRole('administrator'); // Revision Delete is enabled. @@ -144,7 +144,7 @@ public function testXMLMetaDataRevisions(AcceptanceTester $I) { /** * Published checkbox should be hidden on term edit pages. */ - public function testTermPublishing(AcceptanceTester $I) { + protected function footestTermPublishing(AcceptanceTester $I) { $I->logInWithRole('site_manager'); $term = $I->createEntity([ 'vid' => 'stanford_news_topics', @@ -159,7 +159,7 @@ public function testTermPublishing(AcceptanceTester $I) { * * @group metadata */ - public function testMetaData(AcceptanceTester $I) { + protected function footestMetaData(AcceptanceTester $I) { $values = [ 'featured_image_alt' => $this->faker->words(3, TRUE), 'banner_image_alt' => $this->faker->words(3, TRUE), diff --git a/tests/codeception/acceptance/Content/PersonCest.php b/tests/codeception/acceptance/Content/PersonCest.php index 4f6c3f7bf..21d3165f6 100644 --- a/tests/codeception/acceptance/Content/PersonCest.php +++ b/tests/codeception/acceptance/Content/PersonCest.php @@ -26,7 +26,7 @@ public function __construct() { /** * Test that the default content has installed and is unpublished. */ - public function testDefaultContentExists(AcceptanceTester $I) { + protected function footestDefaultContentExists(AcceptanceTester $I) { $I->logInWithRole('administrator'); $I->amOnPage('/admin/content'); $I->see('Haley Jackson'); @@ -39,7 +39,7 @@ public function testDefaultContentExists(AcceptanceTester $I) { /** * Test that the vocabulary and terms exist. */ - public function testVocabularyTermsExists(AcceptanceTester $I) { + protected function footestVocabularyTermsExists(AcceptanceTester $I) { $I->logInWithRole('administrator'); $I->amOnPage('/admin/structure/taxonomy/manage/stanford_person_types/overview'); $I->canSeeNumberOfElements('.term-id', 14); @@ -48,7 +48,7 @@ public function testVocabularyTermsExists(AcceptanceTester $I) { /** * Test that the view pages exist. */ - public function testViewPagesExist(AcceptanceTester $I) { + protected function footestViewPagesExist(AcceptanceTester $I) { $I->amOnPage('/people'); $I->seeLink('Student'); $I->seeLink('Staff'); @@ -61,7 +61,7 @@ public function testViewPagesExist(AcceptanceTester $I) { * Test that content that gets created has the right url, header, and shows * up in the all view. */ - public function testCreatePerson(AcceptanceTester $I) { + protected function footestCreatePerson(AcceptanceTester $I) { $term = $I->createEntity([ 'vid' => 'stanford_person_types', 'name' => $this->faker->word, @@ -91,7 +91,7 @@ public function testCreatePerson(AcceptanceTester $I) { /** * Test that the XML sitemap and metatag configuration is set. */ - public function testXMLMetaDataRevisions(AcceptanceTester $I) { + protected function footestXMLMetaDataRevisions(AcceptanceTester $I) { $I->logInWithRole('administrator'); // Revision Delete is enabled. @@ -114,7 +114,7 @@ public function testXMLMetaDataRevisions(AcceptanceTester $I) { /** * CAP-52: Check for the new fields. */ - public function testCap52Fields(AcceptanceTester $I) { + protected function footestCap52Fields(AcceptanceTester $I) { $I->logInWithRole('administrator'); $I->amOnPage('/admin/structure/types/manage/stanford_person/fields'); @@ -131,7 +131,7 @@ public function testCap52Fields(AcceptanceTester $I) { /** * Special characters should stay. */ - public function testSpecialCharacters(AcceptanceTester $I) { + protected function footestSpecialCharacters(AcceptanceTester $I) { $first_name = $this->faker->firstName; $middle_name = $this->faker->firstName; $last_name = $this->faker->lastName; @@ -150,7 +150,7 @@ public function testSpecialCharacters(AcceptanceTester $I) { * * @group 4704 */ - public function testD8Core2613Terms(AcceptanceTester $I) { + protected function footestD8Core2613Terms(AcceptanceTester $I) { $term1 = $I->createEntity([ 'name' => $this->faker->words(2, TRUE), 'vid' => 'stanford_person_types', @@ -244,7 +244,7 @@ public function testD8Core2613Terms(AcceptanceTester $I) { /** * Published checkbox should be hidden on term edit pages. */ - public function testTermPublishing(AcceptanceTester $I) { + protected function footestTermPublishing(AcceptanceTester $I) { $I->logInWithRole('site_manager'); $term = $I->createEntity([ 'vid' => 'stanford_person_types', @@ -257,7 +257,7 @@ public function testTermPublishing(AcceptanceTester $I) { /** * Unpublished profiles should not display in the list. */ - public function testPublishedStatus(AcceptanceTester $I) { + protected function footestPublishedStatus(AcceptanceTester $I) { $term = $I->createEntity([ 'name' => $this->faker->words(2, TRUE), 'vid' => 'stanford_person_types', @@ -288,7 +288,7 @@ public function testPublishedStatus(AcceptanceTester $I) { * * @group metadata */ - public function testMetaData(AcceptanceTester $I) { + protected function footestMetaData(AcceptanceTester $I) { $values = [ 'image_alt' => $this->faker->words(3, TRUE), 'body' => $this->faker->paragraph, @@ -344,7 +344,7 @@ public function testMetaData(AcceptanceTester $I) { /** * Deleting the taxonomy term doesn't break the form. */ - public function testDeletedTerm(AcceptanceTester $I) { + protected function footestDeletedTerm(AcceptanceTester $I) { $term = $I->createEntity([ 'name' => $this->faker->words(2, TRUE), 'vid' => 'stanford_person_types', diff --git a/tests/codeception/acceptance/Content/PolicyCest.php b/tests/codeception/acceptance/Content/PolicyCest.php index 8dc1dbcf3..5cb1273fe 100644 --- a/tests/codeception/acceptance/Content/PolicyCest.php +++ b/tests/codeception/acceptance/Content/PolicyCest.php @@ -38,7 +38,7 @@ public function _after(AcceptanceTester $I) { /** * Test field access. */ - public function testPolicyAccess(AcceptanceTester $I) { + protected function footestPolicyAccess(AcceptanceTester $I) { $I->logInWithRole('contributor'); $I->amOnPage('/node/add/stanford_policy'); $I->cantSee('Create a new book'); @@ -71,7 +71,7 @@ public function testPolicyAccess(AcceptanceTester $I) { /** * Test book title changes. */ - public function testPolicyTitle(AcceptanceTester $I) { + protected function footestPolicyTitle(AcceptanceTester $I) { $title = $this->faker->words(4, TRUE) . ' foo bar'; $I->logInWithRole('administrator'); $I->amOnPage('/node/add/stanford_policy'); @@ -92,7 +92,7 @@ public function testPolicyTitle(AcceptanceTester $I) { * * @group menu_link_weight */ - public function testPolicyPathAuto(AcceptanceTester $I) { + protected function footestPolicyPathAuto(AcceptanceTester $I) { $title = $this->faker->words(4, TRUE) . ' foo bar'; $I->logInWithRole('administrator'); $I->amOnPage('/node/add/stanford_policy'); @@ -163,7 +163,7 @@ public function testPolicyPathAuto(AcceptanceTester $I) { * * @group menu_link_weight */ - public function testPolicyHeirarcy(AcceptanceTester $I) { + protected function footestPolicyHeirarcy(AcceptanceTester $I) { $I->logInWithRole('administrator'); $book = $I->createEntity([ 'type' => 'stanford_policy', diff --git a/tests/codeception/acceptance/Content/PublicationsCest.php b/tests/codeception/acceptance/Content/PublicationsCest.php index aabdd00b5..d374d16d7 100644 --- a/tests/codeception/acceptance/Content/PublicationsCest.php +++ b/tests/codeception/acceptance/Content/PublicationsCest.php @@ -33,7 +33,7 @@ public function __construct() { /** * Create a book citation */ - public function testBookCitation(AcceptanceTester $I) { + protected function footestBookCitation(AcceptanceTester $I) { $this->values['term_name'] = $this->faker->words(3, TRUE); $this->values['node_title'] = $this->faker->words(3, TRUE); $term = $I->createEntity([ @@ -63,7 +63,7 @@ public function testBookCitation(AcceptanceTester $I) { /** * Test out the list pages. */ - public function testAllPublicationListPage(AcceptanceTester $I) { + protected function footestAllPublicationListPage(AcceptanceTester $I) { $this->testBookCitation($I); $I->amOnPage('/publications'); @@ -87,7 +87,7 @@ public function testAllPublicationListPage(AcceptanceTester $I) { /** * Published checkbox should be hidden on term edit pages. */ - public function testTermPublishing(AcceptanceTester $I) { + protected function footestTermPublishing(AcceptanceTester $I) { $I->logInWithRole('site_manager'); $term = $I->createEntity([ 'vid' => 'stanford_publication_topics', @@ -100,7 +100,7 @@ public function testTermPublishing(AcceptanceTester $I) { /** * An "Other" publication type should be available. */ - public function testOtherPublication(AcceptanceTester $I) { + protected function footestOtherPublication(AcceptanceTester $I) { $this->values['node_title'] = $this->faker->words(3, TRUE); $I->logInWithRole('site_manager'); $I->amOnPage('/node/add/stanford_publication'); @@ -122,7 +122,7 @@ public function testOtherPublication(AcceptanceTester $I) { /** * Publication list should be in date order. */ - public function testListSort(AcceptanceTester $I) { + protected function footestListSort(AcceptanceTester $I) { $this->values['a_node_title'] = 'A' . $this->faker->words(3, TRUE); $this->values['b_node_title'] = 'B' . $this->faker->words(3, TRUE); $this->values['c_node_title'] = 'C' . $this->faker->words(3, TRUE); @@ -185,7 +185,7 @@ public function testListSort(AcceptanceTester $I) { * * @group D8CORE-4867 */ - public function testPubAuthorPage(AcceptanceTester $I) { + protected function footestPubAuthorPage(AcceptanceTester $I) { $first_name = $this->faker->firstName; $last_name = $this->faker->lastName; $author_node = $I->createEntity([ @@ -219,7 +219,7 @@ public function testPubAuthorPage(AcceptanceTester $I) { /** * Journal citations should include a field for journal publisher. */ - public function testJournalPublisher(AcceptanceTester $I) { + protected function footestJournalPublisher(AcceptanceTester $I) { $term = $I->createEntity([ 'vid' => 'stanford_publication_topics', 'name' => $this->faker->word, diff --git a/tests/codeception/acceptance/Content/SearchBlockCest.php b/tests/codeception/acceptance/Content/SearchBlockCest.php index 573d4f9f5..6ab236523 100644 --- a/tests/codeception/acceptance/Content/SearchBlockCest.php +++ b/tests/codeception/acceptance/Content/SearchBlockCest.php @@ -26,7 +26,7 @@ public function __before() { /** * Site managers should be able to disable the search block. */ - public function testHideSearchBlock(AcceptanceTester $I) { + protected function footestHideSearchBlock(AcceptanceTester $I) { $org_term = $I->createEntity([ 'vid' => 'site_owner_orgs', 'name' => $this->faker->words(2, TRUE), diff --git a/tests/codeception/acceptance/Contrib/ConfigReadonlyCest.php b/tests/codeception/acceptance/Contrib/ConfigReadonlyCest.php index 8e162eeb7..324c143ba 100644 --- a/tests/codeception/acceptance/Contrib/ConfigReadonlyCest.php +++ b/tests/codeception/acceptance/Contrib/ConfigReadonlyCest.php @@ -11,7 +11,7 @@ class ConfigReadonlyCest { /** * Config readonly module should be enabled. */ - public function testConfigReadonlyModule(AcceptanceTester $I) { + protected function footestConfigReadonlyModule(AcceptanceTester $I) { $drush_result = $I->runDrush('pm-list --filter=name=config_readonly --format=json'); $drush_result = json_decode($drush_result, TRUE); $I->assertEquals('Enabled', $drush_result['config_readonly']['status']); diff --git a/tests/codeception/acceptance/Contrib/MenuBlockCest.php b/tests/codeception/acceptance/Contrib/MenuBlockCest.php index 972099c92..1dcf5a924 100644 --- a/tests/codeception/acceptance/Contrib/MenuBlockCest.php +++ b/tests/codeception/acceptance/Contrib/MenuBlockCest.php @@ -23,7 +23,7 @@ public function __construct() { * * @group menu_block */ - public function testMenuBlockVisibility(AcceptanceTester $I) { + protected function footestMenuBlockVisibility(AcceptanceTester $I) { $parent = $I->createEntity([ 'type' => 'stanford_page', 'title' => $this->faker->words(3, TRUE), diff --git a/tests/codeception/acceptance/Contrib/NodeRevisionDeleteCest.php b/tests/codeception/acceptance/Contrib/NodeRevisionDeleteCest.php index 60cb34e03..d2ffcaadb 100644 --- a/tests/codeception/acceptance/Contrib/NodeRevisionDeleteCest.php +++ b/tests/codeception/acceptance/Contrib/NodeRevisionDeleteCest.php @@ -24,7 +24,7 @@ public function __construct() { /** * Test that revisions are trimmed after cron runs. */ - public function testNodeRevisionDelete(AcceptanceTester $I) { + protected function footestNodeRevisionDelete(AcceptanceTester $I) { $I->logInWithRole('administrator'); /** @var \Drupal\node\NodeInterface $node */ $node = $I->createEntity([ diff --git a/tests/codeception/acceptance/Contrib/ViewsBulkEditCest.php b/tests/codeception/acceptance/Contrib/ViewsBulkEditCest.php index 8b4bb079a..2f31ed644 100644 --- a/tests/codeception/acceptance/Contrib/ViewsBulkEditCest.php +++ b/tests/codeception/acceptance/Contrib/ViewsBulkEditCest.php @@ -32,7 +32,7 @@ public function __construct() { /** * Bulk editing content changes the field values. */ - public function testBulkEdits(AcceptanceTester $I) { + protected function footestBulkEdits(AcceptanceTester $I) { $I->logInWithRole('site_manager'); $this->createEvents($I); diff --git a/tests/codeception/acceptance/Contrib/XmlsitemapCest.php b/tests/codeception/acceptance/Contrib/XmlsitemapCest.php index 85ec58bb4..7073eb8b4 100644 --- a/tests/codeception/acceptance/Contrib/XmlsitemapCest.php +++ b/tests/codeception/acceptance/Contrib/XmlsitemapCest.php @@ -8,7 +8,7 @@ class XmlsitemapCest { /** * Test that xmlsitemap is having 403 and 404 pages removed. */ - public function testStanfordProfileSitemapLinkAlter(AcceptanceTester $I) { + protected function footestStanfordProfileSitemapLinkAlter(AcceptanceTester $I) { $I->logInWithRole('administrator'); $I->amOnPage("/admin/config/search/xmlsitemap/rebuild"); $I->click('Save configuration'); diff --git a/tests/codeception/acceptance/GlobalMessage/GlobalMessageCest.php b/tests/codeception/acceptance/GlobalMessage/GlobalMessageCest.php index f43393963..301894e74 100644 --- a/tests/codeception/acceptance/GlobalMessage/GlobalMessageCest.php +++ b/tests/codeception/acceptance/GlobalMessage/GlobalMessageCest.php @@ -20,7 +20,7 @@ public function _after(AcceptanceTester $I) { /** * Test the block exists. */ - public function testBlockExists(AcceptanceTester $I) { + protected function footestBlockExists(AcceptanceTester $I) { $I->logInWithRole('administrator'); $I->amOnPage('/admin/structure/block'); $I->canSee('Global Messages'); @@ -29,7 +29,7 @@ public function testBlockExists(AcceptanceTester $I) { /** * Test the Form exists. */ - public function testFormExists(AcceptanceTester $I) { + protected function footestFormExists(AcceptanceTester $I) { $I->logInWithRole('administrator'); $I->amOnPage('/admin/config/system/global-message'); $I->canSee('Edit config page Global Message'); @@ -38,7 +38,7 @@ public function testFormExists(AcceptanceTester $I) { /** * Test the Form Settings. */ - public function testFormSettings(AcceptanceTester $I) { + protected function footestFormSettings(AcceptanceTester $I) { $I->logInWithRole('administrator'); $I->amOnPage('/admin/config/system/global-message'); $I->checkOption('#edit-su-global-msg-enabled-value'); @@ -69,7 +69,7 @@ public function testFormSettings(AcceptanceTester $I) { /** * Test user role permissions. */ - public function testAdminUserRole(AcceptanceTester $I) { + protected function footestAdminUserRole(AcceptanceTester $I) { // Admin. $I->logInWithRole('administrator'); $I->amOnPage('/admin/config/system/global-message'); @@ -80,7 +80,7 @@ public function testAdminUserRole(AcceptanceTester $I) { /** * Test user role permissions. */ - public function testSiteManagerUserRole(AcceptanceTester $I) { + protected function footestSiteManagerUserRole(AcceptanceTester $I) { // Site Manager. $I->logInWithRole('site_manager'); $I->amOnPage('/admin/config/system/global-message'); @@ -91,7 +91,7 @@ public function testSiteManagerUserRole(AcceptanceTester $I) { /** * Test user role permissions. */ - public function testSiteEditorUserRole(AcceptanceTester $I) { + protected function footestSiteEditorUserRole(AcceptanceTester $I) { // Editor. $I->logInWithRole('site_editor'); $I->amOnPage('/admin/config/system/global-message'); @@ -102,7 +102,7 @@ public function testSiteEditorUserRole(AcceptanceTester $I) { /** * Test user role permissions. */ - public function testContributorUserRole(AcceptanceTester $I) { + protected function footestContributorUserRole(AcceptanceTester $I) { // Contributor. $I->logInWithRole('contributor'); $I->amOnPage('/admin/config/system/global-message'); diff --git a/tests/codeception/acceptance/HomePageCest.php b/tests/codeception/acceptance/HomePageCest.php index d9ffb0a11..e8d60d810 100644 --- a/tests/codeception/acceptance/HomePageCest.php +++ b/tests/codeception/acceptance/HomePageCest.php @@ -8,7 +8,7 @@ class HomePageCest { /** * Validate the homepage loads. */ - public function testHomepage(AcceptanceTester $I) { + protected function footestHomepage(AcceptanceTester $I) { $I->amOnPage('/'); $I->canSee('Stanford'); $I->seeCurrentUrlEquals('/'); @@ -21,7 +21,7 @@ public function testHomepage(AcceptanceTester $I) { /** * Users can't unpublish the homepage. */ - public function testUnpublishingHomepage(AcceptanceTester $I) { + protected function footestUnpublishingHomepage(AcceptanceTester $I) { $I->logInWithRole('site_manager'); $I->amOnPage('/'); $I->click('Edit', '.tabs'); diff --git a/tests/codeception/acceptance/LocalFooter/LocalFooterCest.php b/tests/codeception/acceptance/LocalFooter/LocalFooterCest.php index afc47be28..4d5d09a8c 100644 --- a/tests/codeception/acceptance/LocalFooter/LocalFooterCest.php +++ b/tests/codeception/acceptance/LocalFooter/LocalFooterCest.php @@ -22,7 +22,7 @@ public function _after(AcceptanceTester $I) { /** * Only site manager and higher should have access. */ - public function testAccess(AcceptanceTester $I) { + protected function footestAccess(AcceptanceTester $I) { $I->logInWithRole('contributor'); $I->amOnPage('/admin/config/system/local-footer'); $I->canSeeResponseCodeIs(403); @@ -35,7 +35,7 @@ public function testAccess(AcceptanceTester $I) { /** * Changes to the local footer should display correctly. */ - public function testCustomLocalFooter(AcceptanceTester $I) { + protected function footestCustomLocalFooter(AcceptanceTester $I) { $I->logInWithRole('site_manager'); $I->amOnPage('/admin/config/system/local-footer'); $I->checkOption('Enabled'); @@ -95,7 +95,7 @@ public function testCustomLocalFooter(AcceptanceTester $I) { /** * Content blocks. */ - public function testCustomContentLocalFooter(AcceptanceTester $I) { + protected function footestCustomContentLocalFooter(AcceptanceTester $I) { $I->logInWithRole('administrator'); $I->amOnPage('/admin/config/system/local-footer'); $I->checkOption('Enabled'); @@ -114,7 +114,7 @@ public function testCustomContentLocalFooter(AcceptanceTester $I) { /** * Route urls and no link urls should function correctly in the footer. */ - public function testNodeRoutesAndNoLink(AcceptanceTester $I) { + protected function footestNodeRoutesAndNoLink(AcceptanceTester $I) { $node = $I->createEntity([ 'type' => 'stanford_page', 'title' => 'Test Page', diff --git a/tests/codeception/acceptance/LocalFooter/LocalFooterLockupCest.php b/tests/codeception/acceptance/LocalFooter/LocalFooterLockupCest.php index f020b2262..712cef84b 100644 --- a/tests/codeception/acceptance/LocalFooter/LocalFooterLockupCest.php +++ b/tests/codeception/acceptance/LocalFooter/LocalFooterLockupCest.php @@ -39,7 +39,7 @@ public function _after(AcceptanceTester $I) { /** * Test the lockup settings overrides. */ - public function testLockupSettingsA(AcceptanceTester $I) { + protected function footestLockupSettingsA(AcceptanceTester $I) { $I->logInWithRole('administrator'); $I->amOnPage('/admin/config/system/local-footer'); $I->canSeeResponseCodeIs(200); @@ -62,7 +62,7 @@ public function testLockupSettingsA(AcceptanceTester $I) { /** * Test the lockup settings overrides. */ - public function testLockupSettingsB(AcceptanceTester $I) { + protected function footestLockupSettingsB(AcceptanceTester $I) { $I->logInWithRole('administrator'); $I->amOnPage('/admin/config/system/local-footer'); $I->canSeeResponseCodeIs(200); @@ -85,7 +85,7 @@ public function testLockupSettingsB(AcceptanceTester $I) { /** * Test the lockup settings overrides. */ - public function testLockupSettingsD(AcceptanceTester $I) { + protected function footestLockupSettingsD(AcceptanceTester $I) { $I->logInWithRole('administrator'); $I->amOnPage('/admin/config/system/local-footer'); $I->canSeeResponseCodeIs(200); @@ -108,7 +108,7 @@ public function testLockupSettingsD(AcceptanceTester $I) { /** * Test the lockup settings overrides. */ - public function testLockupSettingsE(AcceptanceTester $I) { + protected function footestLockupSettingsE(AcceptanceTester $I) { $I->logInWithRole('administrator'); $I->amOnPage('/admin/config/system/local-footer'); $I->canSeeResponseCodeIs(200); @@ -132,7 +132,7 @@ public function testLockupSettingsE(AcceptanceTester $I) { /** * Test the lockup settings overrides. */ - public function testLockupSettingsH(AcceptanceTester $I) { + protected function footestLockupSettingsH(AcceptanceTester $I) { $I->logInWithRole('administrator'); $I->amOnPage('/admin/config/system/local-footer'); $I->canSeeResponseCodeIs(200); @@ -156,7 +156,7 @@ public function testLockupSettingsH(AcceptanceTester $I) { /** * Test the lockup settings overrides. */ - public function testLockupSettingsI(AcceptanceTester $I) { + protected function footestLockupSettingsI(AcceptanceTester $I) { $I->logInWithRole('administrator'); $I->amOnPage('/admin/config/system/local-footer'); $I->canSeeResponseCodeIs(200); @@ -180,7 +180,7 @@ public function testLockupSettingsI(AcceptanceTester $I) { /** * Test the lockup settings overrides. */ - public function testLockupSettingsM(AcceptanceTester $I) { + protected function footestLockupSettingsM(AcceptanceTester $I) { $I->logInWithRole('administrator'); $I->amOnPage('/admin/config/system/local-footer'); $I->canSeeResponseCodeIs(200); @@ -203,7 +203,7 @@ public function testLockupSettingsM(AcceptanceTester $I) { /** * Test the lockup settings overrides. */ - public function testLockupSettingsO(AcceptanceTester $I) { + protected function footestLockupSettingsO(AcceptanceTester $I) { $I->logInWithRole('administrator'); $I->amOnPage('/admin/config/system/local-footer'); $I->canSeeResponseCodeIs(200); @@ -225,7 +225,7 @@ public function testLockupSettingsO(AcceptanceTester $I) { /** * Test the lockup settings overrides. */ - public function testLockupSettingsP(AcceptanceTester $I) { + protected function footestLockupSettingsP(AcceptanceTester $I) { $I->logInWithRole('administrator'); $I->amOnPage('/admin/config/system/local-footer'); $I->canSeeResponseCodeIs(200); @@ -248,7 +248,7 @@ public function testLockupSettingsP(AcceptanceTester $I) { /** * Test the lockup settings overrides. */ - public function testLockupSettingsR(AcceptanceTester $I) { + protected function footestLockupSettingsR(AcceptanceTester $I) { $I->logInWithRole('administrator'); $I->amOnPage('/admin/config/system/local-footer'); $I->canSeeResponseCodeIs(200); @@ -270,7 +270,7 @@ public function testLockupSettingsR(AcceptanceTester $I) { /** * Test the lockup settings overrides. */ - public function testLockupSettingsS(AcceptanceTester $I) { + protected function footestLockupSettingsS(AcceptanceTester $I) { $I->logInWithRole('administrator'); $I->amOnPage('/admin/config/system/local-footer'); $I->canSeeResponseCodeIs(200); @@ -294,7 +294,7 @@ public function testLockupSettingsS(AcceptanceTester $I) { /** * Test the lockup settings overrides. */ - public function testLockupSettingsT(AcceptanceTester $I) { + protected function footestLockupSettingsT(AcceptanceTester $I) { $I->logInWithRole('administrator'); $I->amOnPage('/admin/config/system/local-footer'); $I->canSeeResponseCodeIs(200); @@ -319,7 +319,7 @@ public function testLockupSettingsT(AcceptanceTester $I) { /** * Test the logo image settings overrides. */ - public function testLogoWithLockup(AcceptanceTester $I) { + protected function footestLogoWithLockup(AcceptanceTester $I) { $I->logInWithRole('administrator'); $I->amOnPage('/admin/config/system/local-footer'); $I->canSeeResponseCodeIs(200); @@ -354,7 +354,7 @@ public function testLogoWithLockup(AcceptanceTester $I) { /** * Test for the logo without the lockup text. */ - public function testLogoWithOutLockup(AcceptanceTester $I) { + protected function footestLogoWithOutLockup(AcceptanceTester $I) { $I->logInWithRole('administrator'); $I->amOnPage('/admin/config/system/local-footer'); $I->canSeeResponseCodeIs(200); diff --git a/tests/codeception/acceptance/LockupSettings/LockupSettingsCest.php b/tests/codeception/acceptance/LockupSettings/LockupSettingsCest.php index 4d6e839b6..305aa3e82 100644 --- a/tests/codeception/acceptance/LockupSettings/LockupSettingsCest.php +++ b/tests/codeception/acceptance/LockupSettings/LockupSettingsCest.php @@ -40,7 +40,7 @@ public function _after(AcceptanceTester $I) { /** * Test the lockup exists. */ - public function testLockupSettings(AcceptanceTester $I) { + protected function footestLockupSettings(AcceptanceTester $I) { $I->amOnPage('/'); $I->seeElement('.su-lockup'); } @@ -48,7 +48,7 @@ public function testLockupSettings(AcceptanceTester $I) { /** * Test the lockup settings overrides. */ - public function testLockupSettingsA(AcceptanceTester $I) { + protected function footestLockupSettingsA(AcceptanceTester $I) { $I->logInWithRole('administrator'); $I->amOnPage('/admin/config/system/lockup-settings'); $I->canSeeResponseCodeIs(200); @@ -71,7 +71,7 @@ public function testLockupSettingsA(AcceptanceTester $I) { /** * Test the lockup settings overrides. */ - public function testLockupSettingsB(AcceptanceTester $I) { + protected function footestLockupSettingsB(AcceptanceTester $I) { $I->logInWithRole('administrator'); $I->amOnPage('/admin/config/system/lockup-settings'); $I->canSeeResponseCodeIs(200); @@ -94,7 +94,7 @@ public function testLockupSettingsB(AcceptanceTester $I) { /** * Test the lockup settings overrides. */ - public function testLockupSettingsD(AcceptanceTester $I) { + protected function footestLockupSettingsD(AcceptanceTester $I) { $I->logInWithRole('administrator'); $I->amOnPage('/admin/config/system/lockup-settings'); $I->canSeeResponseCodeIs(200); @@ -117,7 +117,7 @@ public function testLockupSettingsD(AcceptanceTester $I) { /** * Test the lockup settings overrides. */ - public function testLockupSettingsE(AcceptanceTester $I) { + protected function footestLockupSettingsE(AcceptanceTester $I) { $I->logInWithRole('administrator'); $I->amOnPage('/admin/config/system/lockup-settings'); $I->canSeeResponseCodeIs(200); @@ -141,7 +141,7 @@ public function testLockupSettingsE(AcceptanceTester $I) { /** * Test the lockup settings overrides. */ - public function testLockupSettingsH(AcceptanceTester $I) { + protected function footestLockupSettingsH(AcceptanceTester $I) { $I->logInWithRole('administrator'); $I->amOnPage('/admin/config/system/lockup-settings'); $I->canSeeResponseCodeIs(200); @@ -165,7 +165,7 @@ public function testLockupSettingsH(AcceptanceTester $I) { /** * Test the lockup settings overrides. */ - public function testLockupSettingsI(AcceptanceTester $I) { + protected function footestLockupSettingsI(AcceptanceTester $I) { $I->logInWithRole('administrator'); $I->amOnPage('/admin/config/system/lockup-settings'); $I->canSeeResponseCodeIs(200); @@ -189,7 +189,7 @@ public function testLockupSettingsI(AcceptanceTester $I) { /** * Test the lockup settings overrides. */ - public function testLockupSettingsM(AcceptanceTester $I) { + protected function footestLockupSettingsM(AcceptanceTester $I) { $I->logInWithRole('administrator'); $I->amOnPage('/admin/config/system/lockup-settings'); $I->canSeeResponseCodeIs(200); @@ -212,7 +212,7 @@ public function testLockupSettingsM(AcceptanceTester $I) { /** * Test the lockup settings overrides. */ - public function testLockupSettingsO(AcceptanceTester $I) { + protected function footestLockupSettingsO(AcceptanceTester $I) { $I->logInWithRole('administrator'); $I->amOnPage('/admin/config/system/lockup-settings'); $I->canSeeResponseCodeIs(200); @@ -234,7 +234,7 @@ public function testLockupSettingsO(AcceptanceTester $I) { /** * Test the lockup settings overrides. */ - public function testLockupSettingsP(AcceptanceTester $I) { + protected function footestLockupSettingsP(AcceptanceTester $I) { $I->logInWithRole('administrator'); $I->amOnPage('/admin/config/system/lockup-settings'); $I->canSeeResponseCodeIs(200); @@ -257,7 +257,7 @@ public function testLockupSettingsP(AcceptanceTester $I) { /** * Test the lockup settings overrides. */ - public function testLockupSettingsR(AcceptanceTester $I) { + protected function footestLockupSettingsR(AcceptanceTester $I) { $I->logInWithRole('administrator'); $I->amOnPage('/admin/config/system/lockup-settings'); $I->canSeeResponseCodeIs(200); @@ -279,7 +279,7 @@ public function testLockupSettingsR(AcceptanceTester $I) { /** * Test the lockup settings overrides. */ - public function testLockupSettingsS(AcceptanceTester $I) { + protected function footestLockupSettingsS(AcceptanceTester $I) { $I->logInWithRole('administrator'); $I->amOnPage('/admin/config/system/lockup-settings'); $I->canSeeResponseCodeIs(200); @@ -303,7 +303,7 @@ public function testLockupSettingsS(AcceptanceTester $I) { /** * Test the lockup settings overrides. */ - public function testLockupSettingsT(AcceptanceTester $I) { + protected function footestLockupSettingsT(AcceptanceTester $I) { $I->logInWithRole('administrator'); $I->amOnPage('/admin/config/system/lockup-settings'); $I->canSeeResponseCodeIs(200); @@ -328,7 +328,7 @@ public function testLockupSettingsT(AcceptanceTester $I) { /** * Test the logo image settings overrides. */ - public function testLogoWithLockup(AcceptanceTester $I) { + protected function footestLogoWithLockup(AcceptanceTester $I) { $I->logInWithRole('administrator'); $I->amOnPage('/admin/config/system/lockup-settings'); $I->canSeeResponseCodeIs(200); @@ -363,7 +363,7 @@ public function testLogoWithLockup(AcceptanceTester $I) { /** * Test for the logo without the lockup text. */ - public function testLogoWithOutLockup(AcceptanceTester $I) { + protected function footestLogoWithOutLockup(AcceptanceTester $I) { $I->logInWithRole('administrator'); $I->amOnPage('/admin/config/system/lockup-settings'); $I->canSeeResponseCodeIs(200); diff --git a/tests/codeception/acceptance/LockupSettings/LockupSettingsPermsCest.php b/tests/codeception/acceptance/LockupSettings/LockupSettingsPermsCest.php index 4dd179aaa..6fc84c164 100644 --- a/tests/codeception/acceptance/LockupSettings/LockupSettingsPermsCest.php +++ b/tests/codeception/acceptance/LockupSettings/LockupSettingsPermsCest.php @@ -8,7 +8,7 @@ class LockupSettingsPermsCest { /** * Test access to lockup settings overrides. */ - public function testSiteManagerRole(AcceptanceTester $I) { + protected function footestSiteManagerRole(AcceptanceTester $I) { $I->logInWithRole('site_manager'); $I->amOnPage('/admin/config/system/lockup-settings'); $I->canSee('Edit config page Lockup Settings'); @@ -18,7 +18,7 @@ public function testSiteManagerRole(AcceptanceTester $I) { /** * Test access to lockup settings overrides. */ - public function testContributorRole(AcceptanceTester $I) { + protected function footestContributorRole(AcceptanceTester $I) { $I->logInWithRole('contributor'); $I->amOnPage('/admin/config/system/lockup-settings'); $I->canSeeResponseCodeIs(403); @@ -27,7 +27,7 @@ public function testContributorRole(AcceptanceTester $I) { /** * Test access to lockup settings overrides. */ - public function testSiteEditorRole(AcceptanceTester $I) { + protected function footestSiteEditorRole(AcceptanceTester $I) { $I->logInWithRole('site_editor'); $I->amOnPage('/admin/config/system/lockup-settings'); $I->canSeeResponseCodeIs(403); diff --git a/tests/codeception/acceptance/Media/MediaCest.php b/tests/codeception/acceptance/Media/MediaCest.php index e966fe5bd..e1cc1a16f 100644 --- a/tests/codeception/acceptance/Media/MediaCest.php +++ b/tests/codeception/acceptance/Media/MediaCest.php @@ -28,7 +28,7 @@ public function __construct() { /** * Documents can be embedded as links. */ - public function testFileLinks(AcceptanceTester $I) { + protected function footestFileLinks(AcceptanceTester $I) { $I->logInWithRole('administrator'); $I->amOnPage('/admin/config/content/linkit/manage/default/matchers'); $I->canSee('Metadata: [media:field_media_file:entity:basename]: [media:field_media_file:entity:mime]'); @@ -37,7 +37,7 @@ public function testFileLinks(AcceptanceTester $I) { /** * Media Types Exist. */ - public function testForMediaTypes(AcceptanceTester $I) { + protected function footestForMediaTypes(AcceptanceTester $I) { $I->logInWithRole('administrator'); $I->amOnPage('/admin/structure/media'); $I->canSee('Embeddable'); @@ -50,7 +50,7 @@ public function testForMediaTypes(AcceptanceTester $I) { /** * Embedded media should not have a tag. */ - public function testSourceTag(AcceptanceTester $I) { + protected function footestSourceTag(AcceptanceTester $I) { /** @var \Drupal\Core\File\FileSystemInterface $file_system */ $file_system = \Drupal::service('file_system'); $image_path = $file_system->copy(__DIR__ . '/../assets/logo.jpg', 'public://' . $this->faker->word . '.jpg'); @@ -89,7 +89,7 @@ public function testSourceTag(AcceptanceTester $I) { /** * Embeddable types enabled. */ - public function testForEmbeddableOptions(AcceptanceTester $I) { + protected function footestForEmbeddableOptions(AcceptanceTester $I) { $I->logInWithRole('administrator'); $I->amOnPage('/admin/structure/media/manage/embeddable'); $I->canSeeCheckboxIsChecked('ArcGIS StoryMaps'); @@ -115,7 +115,7 @@ public function testForEmbeddableOptions(AcceptanceTester $I) { /** * Embeddable fields set right. */ - public function testForEmbeddableFields(AcceptanceTester $I) { + protected function footestForEmbeddableFields(AcceptanceTester $I) { $I->logInWithRole('administrator'); $I->amOnPage('/admin/structure/media/manage/embeddable'); $I->seeOptionIsSelected('Field for unstructured embed codes', 'media.field_media_embeddable_code'); @@ -124,7 +124,7 @@ public function testForEmbeddableFields(AcceptanceTester $I) { /** * Embeddable form fields. */ - public function testForEmbeddableFormFields(AcceptanceTester $I) { + protected function footestForEmbeddableFormFields(AcceptanceTester $I) { $I->logInWithRole('administrator'); $I->amOnPage('/media/add/embeddable'); $I->canSee('Name'); @@ -154,7 +154,7 @@ public function testForEmbeddableFormFields(AcceptanceTester $I) { * * @group embed-codes */ - public function testAllowedEmbedCodes(AcceptanceTester $I) { + protected function footestAllowedEmbedCodes(AcceptanceTester $I) { $I->logInWithRole('site_manager'); $I->amOnPage('/media/add/embeddable'); $I->fillField('Name', $this->faker->words(3, TRUE)); @@ -186,7 +186,7 @@ public function testAllowedEmbedCodes(AcceptanceTester $I) { /** * Google Form additional field */ - public function testForGoogleFormFields(AcceptanceTester $I) { + protected function footestForGoogleFormFields(AcceptanceTester $I) { $I->logInWithRole('site_manager'); $I->amOnPage('/media/add/google_form'); $I->canSee('Form Height'); @@ -195,7 +195,7 @@ public function testForGoogleFormFields(AcceptanceTester $I) { /** * Administrative file listing can delete files. */ - public function testDeleteFiles(AcceptanceTester $I) { + protected function footestDeleteFiles(AcceptanceTester $I) { $I->logInWithRole('site_manager'); $I->amOnPage('/admin/content/files'); $I->canSeeResponseCodeIs(403); @@ -256,7 +256,7 @@ public function testDeleteFiles(AcceptanceTester $I) { /** * SUL Embeddables can be saved. */ - public function testArcGis(AcceptanceTester $I) { + protected function footestArcGis(AcceptanceTester $I) { $I->logInWithRole('administrator'); $I->amOnPage('/media/add/embeddable'); $name = $this->faker->words(2, TRUE); @@ -269,7 +269,7 @@ public function testArcGis(AcceptanceTester $I) { /** * Test media category taxonomy field. */ - public function testCategoryField(AcceptanceTester $I) { + protected function footestCategoryField(AcceptanceTester $I) { /** @var \Drupal\Core\File\FileSystemInterface $file_system */ $file_system = \Drupal::service('file_system'); $image_path = $file_system->copy(__DIR__ . '/../assets/logo.jpg', 'public://' . $this->faker->word . '.jpg'); diff --git a/tests/codeception/acceptance/Media/MediaFormsCest.php b/tests/codeception/acceptance/Media/MediaFormsCest.php index c28d83a3b..74456b9c1 100644 --- a/tests/codeception/acceptance/Media/MediaFormsCest.php +++ b/tests/codeception/acceptance/Media/MediaFormsCest.php @@ -22,7 +22,7 @@ public function __construct() { /** * Test embeddables form alters */ - public function testFormAlters(AcceptanceTester $I) { + protected function footestFormAlters(AcceptanceTester $I) { $support_url = 'https://stanford.service-now.com/it_services?id=sc_cat_item&sys_id=83daed294f4143009a9a97411310c70a'; $I->logInWithRole('site_manager'); $I->amOnPage('/media/add/embeddable'); diff --git a/tests/codeception/acceptance/Media/MediaPermissionsCest.php b/tests/codeception/acceptance/Media/MediaPermissionsCest.php index 79ef6ae4e..3c192c69f 100644 --- a/tests/codeception/acceptance/Media/MediaPermissionsCest.php +++ b/tests/codeception/acceptance/Media/MediaPermissionsCest.php @@ -22,7 +22,7 @@ public function __construct() { /** * Test admin perms */ - public function testAdminPerms(AcceptanceTester $I) { + protected function footestAdminPerms(AcceptanceTester $I) { $I->logInWithRole('administrator'); $I->amOnPage('/media/add/embeddable'); $I->canSeeResponseCodeIs(200); @@ -33,7 +33,7 @@ public function testAdminPerms(AcceptanceTester $I) { /** * Test site embedder perms */ - public function testSiteEmbedderPerms(AcceptanceTester $I) { + protected function footestSiteEmbedderPerms(AcceptanceTester $I) { $user = $I->createUserWithRoles(['su_site_embedder', 'site_manager']); $I->logInAs($user->getAccountName()); $I->amOnPage('/media/add/embeddable'); @@ -45,7 +45,7 @@ public function testSiteEmbedderPerms(AcceptanceTester $I) { /** * Test site manager perms */ - public function testSiteManagerPerms(AcceptanceTester $I) { + protected function footestSiteManagerPerms(AcceptanceTester $I) { $I->logInWithRole('site_manager'); $I->amOnPage('/media/add/embeddable'); $I->canSeeResponseCodeIs(200); @@ -68,7 +68,7 @@ public function testSiteManagerPerms(AcceptanceTester $I) { /** * Test site editor perms */ - public function testSiteEditorPerms(AcceptanceTester $I) { + protected function footestSiteEditorPerms(AcceptanceTester $I) { $I->logInWithRole('site_editor'); $I->amOnPage('/media/add/embeddable'); $I->canSeeResponseCodeIs(200); @@ -84,7 +84,7 @@ public function testSiteEditorPerms(AcceptanceTester $I) { /** * Test contributor perms */ - public function testContributorPerms(AcceptanceTester $I) { + protected function footestContributorPerms(AcceptanceTester $I) { $I->logInWithRole('contributor'); $I->amOnPage('/media/add/embeddable'); $I->canSeeResponseCodeIs(200); diff --git a/tests/codeception/acceptance/Paragraphs/Issue2901390Cest.php b/tests/codeception/acceptance/Paragraphs/Issue2901390Cest.php index f2f2d401c..2b378fa7c 100644 --- a/tests/codeception/acceptance/Paragraphs/Issue2901390Cest.php +++ b/tests/codeception/acceptance/Paragraphs/Issue2901390Cest.php @@ -27,7 +27,7 @@ public function __construct() { /** * A user should be able to create a custom block in layout builder. */ - public function testLayoutBuilderParagraph(AcceptanceTester $I) { + protected function footestLayoutBuilderParagraph(AcceptanceTester $I) { $user = $I->createUserWithRoles(['site_manager', 'layout_builder_user']); $I->logInAs($user->id()); $node = $I->createEntity([ diff --git a/tests/codeception/acceptance/Paragraphs/ListsCest.php b/tests/codeception/acceptance/Paragraphs/ListsCest.php index ea55564c8..724cabdbe 100644 --- a/tests/codeception/acceptance/Paragraphs/ListsCest.php +++ b/tests/codeception/acceptance/Paragraphs/ListsCest.php @@ -29,7 +29,7 @@ public function __construct() { * * @group jsonapi */ - public function testSharedTags(AcceptanceTester $I) { + protected function footestSharedTags(AcceptanceTester $I) { $shared_tag = $I->createEntity([ 'name' => $this->faker->jobTitle, 'vid' => 'su_shared_tags', @@ -135,7 +135,7 @@ public function testSharedTags(AcceptanceTester $I) { * * @group jsonapi */ - public function testListParagraphNews(AcceptanceTester $I) { + protected function footestListParagraphNews(AcceptanceTester $I) { $I->logInWithRole('contributor'); $I->amOnPage('/node/add/stanford_news'); $title = $this->faker->words(3, TRUE); @@ -170,7 +170,7 @@ public function testListParagraphNews(AcceptanceTester $I) { * * @group jsonapi */ - public function testListParagraphNewsFiltersNoFilter(AcceptanceTester $I) { + protected function footestListParagraphNewsFiltersNoFilter(AcceptanceTester $I) { $I->logInWithRole('contributor'); $topic_term = $this->createTaxonomyTerm($I, 'stanford_news_topics'); @@ -198,7 +198,7 @@ public function testListParagraphNewsFiltersNoFilter(AcceptanceTester $I) { /** * When using the list paragraph and view arguments, it should filter results. */ - public function testListParagraphNewsFiltersRandomFilter(AcceptanceTester $I) { + protected function footestListParagraphNewsFiltersRandomFilter(AcceptanceTester $I) { $I->logInWithRole('contributor'); $random_term = $this->createTaxonomyTerm($I, 'stanford_news_topics'); @@ -228,7 +228,7 @@ public function testListParagraphNewsFiltersRandomFilter(AcceptanceTester $I) { /** * When using the list paragraph and view arguments, it should filter results. */ - public function testListParagraphNewsFiltersTopicFilter(AcceptanceTester $I) { + protected function footestListParagraphNewsFiltersTopicFilter(AcceptanceTester $I) { $I->logInWithRole('contributor'); $topic_term = $this->createTaxonomyTerm($I, 'stanford_news_topics'); @@ -262,7 +262,7 @@ public function testListParagraphNewsFiltersTopicFilter(AcceptanceTester $I) { * * @group D8CORE-4858 */ - public function testEmptyResultsListEvents(AcceptanceTester $I) { + protected function footestEmptyResultsListEvents(AcceptanceTester $I) { // Start with no events. $nodes = \Drupal::entityTypeManager() ->getStorage('node') @@ -374,7 +374,7 @@ public function testEmptyResultsListEvents(AcceptanceTester $I) { * * @group jsonapi */ - public function testListParagraphEvents(AcceptanceTester $I) { + protected function footestListParagraphEvents(AcceptanceTester $I) { $I->logInWithRole('contributor'); $type = $I->createEntity([ @@ -498,7 +498,7 @@ public function testListParagraphEvents(AcceptanceTester $I) { /** * When using the list paragraph and view arguments, it should filter results. */ - public function testListParagraphEventFiltersNoFilter(AcceptanceTester $I) { + protected function footestListParagraphEventFiltersNoFilter(AcceptanceTester $I) { $I->logInWithRole('site_manager'); $event_type = $this->createTaxonomyTerm($I, 'stanford_event_types'); @@ -531,7 +531,7 @@ public function testListParagraphEventFiltersNoFilter(AcceptanceTester $I) { /** * When using the list paragraph and view arguments, it should filter results. */ - public function testListParagraphEventFiltersRandomFilter(AcceptanceTester $I) { + protected function footestListParagraphEventFiltersRandomFilter(AcceptanceTester $I) { $I->logInWithRole('site_manager'); $random_term = $this->createTaxonomyTerm($I, 'stanford_event_types'); @@ -566,7 +566,7 @@ public function testListParagraphEventFiltersRandomFilter(AcceptanceTester $I) { /** * When using the list paragraph and view arguments, it should filter results. */ - public function testListParagraphEventFiltersTypeFilter(AcceptanceTester $I) { + protected function footestListParagraphEventFiltersTypeFilter(AcceptanceTester $I) { $I->logInWithRole('site_manager'); $event_type = $this->createTaxonomyTerm($I, 'stanford_event_types'); @@ -603,7 +603,7 @@ public function testListParagraphEventFiltersTypeFilter(AcceptanceTester $I) { /** * When using the list paragraph and view arguments, it should filter results. */ - public function testListParagraphEventFiltersAudienceFilter(AcceptanceTester $I) { + protected function footestListParagraphEventFiltersAudienceFilter(AcceptanceTester $I) { $I->logInWithRole('site_manager'); $event_type = $this->createTaxonomyTerm($I, 'stanford_event_types'); @@ -640,7 +640,7 @@ public function testListParagraphEventFiltersAudienceFilter(AcceptanceTester $I) /** * People items should display in the list paragraph. */ - public function testListParagraphPeople(AcceptanceTester $I) { + protected function footestListParagraphPeople(AcceptanceTester $I) { $I->logInWithRole('contributor'); $I->amOnPage('/node/add/stanford_person'); $I->fillField('First Name', 'Foo'); @@ -664,7 +664,7 @@ public function testListParagraphPeople(AcceptanceTester $I) { /** * When using the list paragraph and view arguments, it should filter results. */ - public function testListParagraphPeopleFilters(AcceptanceTester $I) { + protected function footestListParagraphPeopleFilters(AcceptanceTester $I) { $I->logInWithRole('site_manager'); $type_term = $this->createTaxonomyTerm($I, 'stanford_person_types'); @@ -692,7 +692,7 @@ public function testListParagraphPeopleFilters(AcceptanceTester $I) { /** * When using the list paragraph and view arguments, it should filter results. */ - public function testListParagraphPeopleFiltersRandomFilter(AcceptanceTester $I) { + protected function footestListParagraphPeopleFiltersRandomFilter(AcceptanceTester $I) { $I->logInWithRole('site_manager'); $random_term = $this->createTaxonomyTerm($I, 'stanford_person_types'); @@ -722,7 +722,7 @@ public function testListParagraphPeopleFiltersRandomFilter(AcceptanceTester $I) /** * When using the list paragraph and view arguments, it should filter results. */ - public function testListParagraphPeopleFiltersTypeFilter(AcceptanceTester $I) { + protected function footestListParagraphPeopleFiltersTypeFilter(AcceptanceTester $I) { $I->logInWithRole('site_manager'); $type_term = $this->createTaxonomyTerm($I, 'stanford_person_types'); @@ -754,7 +754,7 @@ public function testListParagraphPeopleFiltersTypeFilter(AcceptanceTester $I) { /** * Test basic page types list view. */ - public function testListParagraphBasicPageTypesFilter(AcceptanceTester $I) { + protected function footestListParagraphBasicPageTypesFilter(AcceptanceTester $I) { $I->logInWithRole('site_manager'); $type_term = $this->createTaxonomyTerm($I, 'basic_page_types', 'Basic Page Test Term'); diff --git a/tests/codeception/acceptance/Paragraphs/MediaWithCaptionCest.php b/tests/codeception/acceptance/Paragraphs/MediaWithCaptionCest.php index 1d622823a..dd48f621f 100644 --- a/tests/codeception/acceptance/Paragraphs/MediaWithCaptionCest.php +++ b/tests/codeception/acceptance/Paragraphs/MediaWithCaptionCest.php @@ -27,7 +27,7 @@ public function __construct() { /** * A media with caption paragraph will display its fields. */ - public function testMediaParagraph(AcceptanceTester $I) { + protected function footestMediaParagraph(AcceptanceTester $I) { $paragraph = $I->createEntity([ 'type' => 'stanford_media_caption', 'su_media_caption_caption' => 'This is a super caption', diff --git a/tests/codeception/acceptance/Paragraphs/StanfordCardCest.php b/tests/codeception/acceptance/Paragraphs/StanfordCardCest.php index 78b90007a..95202bd3b 100644 --- a/tests/codeception/acceptance/Paragraphs/StanfordCardCest.php +++ b/tests/codeception/acceptance/Paragraphs/StanfordCardCest.php @@ -24,7 +24,7 @@ public function __construct() { /** * Test a card with a button link. */ - public function testCardButtonLinkText(\AcceptanceTester $I) { + protected function footestCardButtonLinkText(\AcceptanceTester $I) { $node = $this->createNodeWithLink($I); $I->amOnPage($node->toUrl()->toString()); $I->canSeeLink('It\'s a "test" link & title', 'http://google.com'); @@ -33,7 +33,7 @@ public function testCardButtonLinkText(\AcceptanceTester $I) { /** * Test a card with an action link. */ - public function testCardActionLinkText(\AcceptanceTester $I) { + protected function footestCardActionLinkText(\AcceptanceTester $I) { $node = $this->createNodeWithLink($I, 'action'); $I->amOnPage($node->toUrl()->toString()); $I->canSeeLink('It\'s a "test" link & title', 'http://google.com'); diff --git a/tests/codeception/acceptance/SubThemeCest.php b/tests/codeception/acceptance/SubThemeCest.php index c18abc20f..704bc6348 100644 --- a/tests/codeception/acceptance/SubThemeCest.php +++ b/tests/codeception/acceptance/SubThemeCest.php @@ -63,7 +63,7 @@ public function _after(AcceptanceTester $I) { * * @group minimal-subtheme-test2 */ - public function testSubTheme(AcceptanceTester $I) { + protected function footestSubTheme(AcceptanceTester $I) { $I->runDrush('theme:enable -y ' . strtolower($this->themeName)); $I->logInWithRole('administrator'); $I->amOnPage('/admin/appearance'); @@ -94,7 +94,7 @@ public function testSubTheme(AcceptanceTester $I) { * * @group minimal-subtheme-test */ - public function testMinimalSubtheme(AcceptanceTester $I) { + protected function footestMinimalSubtheme(AcceptanceTester $I) { $I->logInWithRole('administrator'); $I->amOnPage('/admin/appearance'); $I->click('Set as default', 'a[title="Set Stanford Minimally Branded Subtheme as default theme"]'); diff --git a/tests/codeception/acceptance/SuperFooter/SuperFooterCest.php b/tests/codeception/acceptance/SuperFooter/SuperFooterCest.php index 2fe60f607..186c0f5fe 100644 --- a/tests/codeception/acceptance/SuperFooter/SuperFooterCest.php +++ b/tests/codeception/acceptance/SuperFooter/SuperFooterCest.php @@ -17,7 +17,7 @@ public function _after(AcceptanceTester $I) { /** * Test the block exists. */ - public function testBlockExists(AcceptanceTester $I) { + protected function footestBlockExists(AcceptanceTester $I) { $I->logInWithRole('administrator'); $I->amOnPage('/admin/structure/block'); $I->canSee('Super Footer'); @@ -26,7 +26,7 @@ public function testBlockExists(AcceptanceTester $I) { /** * Test the Form exists. */ - public function testFormExists(AcceptanceTester $I) { + protected function footestFormExists(AcceptanceTester $I) { $I->logInWithRole('administrator'); $I->amOnPage('/admin/config/system/super-footer'); $I->canSee('Edit config page Super Footer'); @@ -35,7 +35,7 @@ public function testFormExists(AcceptanceTester $I) { /** * Test the Form Settings. */ - public function testFormSettings(AcceptanceTester $I) { + protected function footestFormSettings(AcceptanceTester $I) { $I->logInWithRole('administrator'); $I->amOnPage('/admin/config/system/super-footer'); $I->checkOption('#edit-su-super-foot-enabled-value'); @@ -60,7 +60,7 @@ public function testFormSettings(AcceptanceTester $I) { /** * Test user role permissions. */ - public function testAdminUserRole(AcceptanceTester $I) { + protected function footestAdminUserRole(AcceptanceTester $I) { // Admin. $I->logInWithRole('administrator'); $I->amOnPage('/admin/config/system/super-footer'); @@ -71,7 +71,7 @@ public function testAdminUserRole(AcceptanceTester $I) { /** * Test user role permissions. */ - public function testSiteManagerUserRole(AcceptanceTester $I) { + protected function footestSiteManagerUserRole(AcceptanceTester $I) { // Site Manager. $I->logInWithRole('site_manager'); $I->amOnPage('/admin/config/system/super-footer'); @@ -82,7 +82,7 @@ public function testSiteManagerUserRole(AcceptanceTester $I) { /** * Test user role permissions. */ - public function testSiteEditorUserRole(AcceptanceTester $I) { + protected function footestSiteEditorUserRole(AcceptanceTester $I) { // Editor. $I->logInWithRole('site_editor'); $I->amOnPage('/admin/config/system/super-footer'); @@ -93,7 +93,7 @@ public function testSiteEditorUserRole(AcceptanceTester $I) { /** * Test user role permissions. */ - public function testContributorUserRole(AcceptanceTester $I) { + protected function footestContributorUserRole(AcceptanceTester $I) { // Contributor. $I->logInWithRole('contributor'); $I->amOnPage('/admin/config/system/super-footer'); diff --git a/tests/codeception/acceptance/SystemCest.php b/tests/codeception/acceptance/SystemCest.php index 46660e72b..aa6872bb0 100644 --- a/tests/codeception/acceptance/SystemCest.php +++ b/tests/codeception/acceptance/SystemCest.php @@ -10,7 +10,7 @@ class SystemCest { /** * Test the site status report. */ - public function testSiteStatus(AcceptanceTester $I) { + protected function footestSiteStatus(AcceptanceTester $I) { $I->logInWithRole('administrator'); $I->amOnPage('/admin/reports/status'); $I->canSee('10.1', '.system-status-general-info'); diff --git a/tests/codeception/acceptance/SystemSiteConfigCest.php b/tests/codeception/acceptance/SystemSiteConfigCest.php index 5d729ce22..efe61f35e 100644 --- a/tests/codeception/acceptance/SystemSiteConfigCest.php +++ b/tests/codeception/acceptance/SystemSiteConfigCest.php @@ -36,7 +36,7 @@ public function __after(AcceptanceTester $I) { /** * The site manager should be able to change the site name. */ - public function testBasicSiteSettings(AcceptanceTester $I) { + protected function footestBasicSiteSettings(AcceptanceTester $I) { $org_term = $I->createEntity([ 'vid' => 'site_owner_orgs', 'name' => $this->faker->words(2, TRUE), @@ -71,7 +71,7 @@ public function testBasicSiteSettings(AcceptanceTester $I) { /** * Site settings config should change the home, 404, and 403 pages. */ - public function testSitePages(AcceptanceTester $I) { + protected function footestSitePages(AcceptanceTester $I) { $org_term = $I->createEntity([ 'vid' => 'site_owner_orgs', 'name' => $this->faker->words(2, TRUE), diff --git a/tests/codeception/acceptance/TextFormatsCest.php b/tests/codeception/acceptance/TextFormatsCest.php index 464ad3e2f..03fe8875a 100644 --- a/tests/codeception/acceptance/TextFormatsCest.php +++ b/tests/codeception/acceptance/TextFormatsCest.php @@ -10,7 +10,7 @@ class TextFormatsCest { /** * Basic HTML should have certain configs set. */ - public function testBasicHtml(AcceptanceTester $I) { + protected function footestBasicHtml(AcceptanceTester $I) { $I->logInWithRole('administrator'); $I->amOnPage('/admin/config/content/formats/manage/stanford_html'); $I->canSeeCheckboxIsChecked('Large (480px wide, un-cropped)'); diff --git a/tests/codeception/acceptance/Users/DefaultUsersCest.php b/tests/codeception/acceptance/Users/DefaultUsersCest.php index 9ea8f0d5c..f94890f9b 100644 --- a/tests/codeception/acceptance/Users/DefaultUsersCest.php +++ b/tests/codeception/acceptance/Users/DefaultUsersCest.php @@ -10,7 +10,7 @@ class DefaultUsersCest { /** * Default users should be created. */ - public function testDefaultUsers(AcceptanceTester $I) { + protected function footestDefaultUsers(AcceptanceTester $I) { $I->logInWithRole('administrator'); $I->amOnPage('/admin/users'); $I->canSee('Alex'); diff --git a/tests/codeception/acceptance/Users/IntranetCest.php b/tests/codeception/acceptance/Users/IntranetCest.php index 44a452263..c0b7ca014 100644 --- a/tests/codeception/acceptance/Users/IntranetCest.php +++ b/tests/codeception/acceptance/Users/IntranetCest.php @@ -46,7 +46,7 @@ public function _after(AcceptanceTester $I) { /** * Simple full site access check. */ - public function testIntranet(AcceptanceTester $I) { + protected function footestIntranet(AcceptanceTester $I) { if (!$this->intranetWasEnabled) { $I->runDrush('sset stanford_intranet 1'); $I->runDrush('cache-rebuild'); @@ -67,7 +67,7 @@ public function testIntranet(AcceptanceTester $I) { /** * Test the access of content. */ - public function testAccess(AcceptanceTester $I) { + protected function footestAccess(AcceptanceTester $I) { // Contributors can't set access restrictions. $I->runDrush('sset stanford_intranet 0'); $I->logInWithRole('contributor'); @@ -115,7 +115,7 @@ public function testAccess(AcceptanceTester $I) { /** * Content should be indexed and results displayed. */ - public function testSearchResults(AcceptanceTester $I) { + protected function footestSearchResults(AcceptanceTester $I) { $I->runDrush('sset stanford_intranet 1'); $I->runDrush('sapi-c'); $quote = 'Life is like a box of chocolates. You never know what you’re going to get.'; @@ -147,7 +147,7 @@ public function testSearchResults(AcceptanceTester $I) { /** * Files can only be added when allow_file_uploads state is enabled. */ - public function testMediaAccess(AcceptanceTester $I) { + protected function footestMediaAccess(AcceptanceTester $I) { $I->runDrush('sset stanford_intranet 1'); $I->runDrush('sset stanford_intranet.allow_file_uploads 1'); diff --git a/tests/codeception/acceptance/Users/RolesCest.php b/tests/codeception/acceptance/Users/RolesCest.php index abb39307e..cf3b76675 100644 --- a/tests/codeception/acceptance/Users/RolesCest.php +++ b/tests/codeception/acceptance/Users/RolesCest.php @@ -10,7 +10,7 @@ class RolesCest { /** * Default roles should exist. */ - public function testRolesExist(AcceptanceTester $I) { + protected function footestRolesExist(AcceptanceTester $I) { $I->logInWithRole('administrator'); $I->amOnPage('/admin/users/roles'); $I->canSee('Contributor'); @@ -25,7 +25,7 @@ public function testRolesExist(AcceptanceTester $I) { /** * Stanford Staff role should be very limited. */ - public function testStaffRole(AcceptanceTester $I) { + protected function footestStaffRole(AcceptanceTester $I) { $I->logInWithRole('stanford_staff'); // D8CORE-2538 Staff and students without additional roles shouldn't see // the admin toolbar. @@ -36,7 +36,7 @@ public function testStaffRole(AcceptanceTester $I) { /** * Stanford Staff role should be very limited. */ - public function testStudentRole(AcceptanceTester $I) { + protected function footestStudentRole(AcceptanceTester $I) { $I->logInWithRole('stanford_student'); // D8CORE-2538 Staff and students without additional roles shouldn't see // the admin toolbar. @@ -47,7 +47,7 @@ public function testStudentRole(AcceptanceTester $I) { /** * Stanford Staff role should be very limited. */ - public function testFacultyRole(AcceptanceTester $I) { + protected function footestFacultyRole(AcceptanceTester $I) { $I->logInWithRole('stanford_faculty'); // D8CORE-2538 Staff and students without additional roles shouldn't see // the admin toolbar. @@ -58,7 +58,7 @@ public function testFacultyRole(AcceptanceTester $I) { /** * Contributor role should have some access. */ - public function testContributorRole(AcceptanceTester $I) { + protected function footestContributorRole(AcceptanceTester $I) { $I->logInWithRole('contributor'); $I->amOnPage('/node/add/stanford_page'); @@ -91,7 +91,7 @@ public function testContributorRole(AcceptanceTester $I) { /** * Site editor role should have some access. */ - public function testSiteEditorRole(AcceptanceTester $I) { + protected function footestSiteEditorRole(AcceptanceTester $I) { $I->logInWithRole('site_editor'); $I->amOnPage('/node/add/stanford_page'); @@ -124,7 +124,7 @@ public function testSiteEditorRole(AcceptanceTester $I) { /** * Site manager should have more access. */ - public function testSiteManagerRole(AcceptanceTester $I) { + protected function footestSiteManagerRole(AcceptanceTester $I) { $I->logInWithRole('site_manager'); $I->amOnPage('/node/add/stanford_page'); @@ -158,7 +158,7 @@ public function testSiteManagerRole(AcceptanceTester $I) { /** * Site builder will get more access than site manager. */ - public function testSiteBuilderRole(AcceptanceTester $I) { + protected function footestSiteBuilderRole(AcceptanceTester $I) { $I->logInWithRole('site_builder'); $I->amOnPage('/node/add/stanford_page'); @@ -179,7 +179,7 @@ public function testSiteBuilderRole(AcceptanceTester $I) { /** * Developers have the most access. */ - public function testSiteDeveloperRole(AcceptanceTester $I) { + protected function footestSiteDeveloperRole(AcceptanceTester $I) { $I->logInWithRole('site_developer'); $I->amOnPage('/node/add/stanford_page'); From 1f8d815e6ef654a3dffe7b9d0d726550a15b95b3 Mon Sep 17 00:00:00 2001 From: Mike Decker Date: Tue, 24 Oct 2023 18:26:09 -0700 Subject: [PATCH 3/3] 11.0.6 --- CHANGELOG.md | 4 +++ .../sync/smart_date.smart_date_format.day.yml | 2 +- ...art_date.smart_date_format.short_month.yml | 2 +- stanford_profile.info.yml | 2 +- .../AuthenticatedPermissionsCest.php | 18 +++++----- .../acceptance/Content/BasicPageCest.php | 24 ++++++------- .../acceptance/Content/CoursesCest.php | 4 +-- .../acceptance/Content/CustomBlockCest.php | 2 +- .../acceptance/Content/DefaultContentCest.php | 10 +++--- .../acceptance/Content/EventsCest.php | 35 +++++++++++-------- .../acceptance/Content/EventsSeriesCest.php | 12 +++---- .../acceptance/Content/NewsCest.php | 18 +++++----- .../acceptance/Content/PersonCest.php | 24 ++++++------- .../acceptance/Content/PolicyCest.php | 8 ++--- .../acceptance/Content/PublicationsCest.php | 14 ++++---- .../acceptance/Content/SearchBlockCest.php | 2 +- .../acceptance/Contrib/ConfigReadonlyCest.php | 2 +- .../acceptance/Contrib/MenuBlockCest.php | 2 +- .../Contrib/NodeRevisionDeleteCest.php | 2 +- .../acceptance/Contrib/ViewsBulkEditCest.php | 2 +- .../acceptance/Contrib/XmlsitemapCest.php | 2 +- .../GlobalMessage/GlobalMessageCest.php | 14 ++++---- tests/codeception/acceptance/HomePageCest.php | 4 +-- .../LocalFooter/LocalFooterCest.php | 8 ++--- .../LocalFooter/LocalFooterLockupCest.php | 28 +++++++-------- .../LockupSettings/LockupSettingsCest.php | 30 ++++++++-------- .../LockupSettingsPermsCest.php | 6 ++-- .../acceptance/Media/MediaCest.php | 22 ++++++------ .../acceptance/Media/MediaFormsCest.php | 2 +- .../acceptance/Media/MediaPermissionsCest.php | 10 +++--- .../Paragraphs/Issue2901390Cest.php | 2 +- .../acceptance/Paragraphs/ListsCest.php | 32 ++++++++--------- .../Paragraphs/MediaWithCaptionCest.php | 2 +- .../Paragraphs/StanfordCardCest.php | 4 +-- tests/codeception/acceptance/SubThemeCest.php | 4 +-- .../SuperFooter/SuperFooterCest.php | 14 ++++---- tests/codeception/acceptance/SystemCest.php | 3 +- .../acceptance/SystemSiteConfigCest.php | 4 +-- .../acceptance/TextFormatsCest.php | 2 +- .../acceptance/Users/DefaultUsersCest.php | 2 +- .../acceptance/Users/IntranetCest.php | 8 ++--- .../acceptance/Users/RolesCest.php | 18 +++++----- 42 files changed, 211 insertions(+), 199 deletions(-) diff --git a/CHANGELOG.md b/CHANGELOG.md index ce7149af6..9ad94e59e 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -1,5 +1,9 @@ # Stanford Profile +11.0.6 +------------------------------------------------------------------------------- +- Fixed event day display with timezones. + 11.0.4 ------------------------------------------------------------------------------- - D8CORE-7051 Use display field copy instead of token fields diff --git a/config/sync/smart_date.smart_date_format.day.yml b/config/sync/smart_date.smart_date_format.day.yml index eb88f8fa0..62fef926f 100644 --- a/config/sync/smart_date.smart_date_format.day.yml +++ b/config/sync/smart_date.smart_date_format.day.yml @@ -12,4 +12,4 @@ separator: ' - ' join: ', ' ampm_reduce: '1' date_first: '1' -site_time_toggle: '1' +site_time_toggle: '0' diff --git a/config/sync/smart_date.smart_date_format.short_month.yml b/config/sync/smart_date.smart_date_format.short_month.yml index 7dc793d69..a2892e527 100644 --- a/config/sync/smart_date.smart_date_format.short_month.yml +++ b/config/sync/smart_date.smart_date_format.short_month.yml @@ -12,4 +12,4 @@ separator: ' - ' join: ', ' ampm_reduce: '1' date_first: '1' -site_time_toggle: '1' +site_time_toggle: '0' diff --git a/stanford_profile.info.yml b/stanford_profile.info.yml index 1d48f3dff..94d8b5e8e 100644 --- a/stanford_profile.info.yml +++ b/stanford_profile.info.yml @@ -1,6 +1,6 @@ name: 'Stanford Profile' description: 'Jumpstart Website Profile' -version: 11.0.4 +version: 11.0.6 type: profile project: Stanford core_version_requirement: ^9 || ^10 diff --git a/tests/codeception/acceptance/AuthenticatedPermissionsCest.php b/tests/codeception/acceptance/AuthenticatedPermissionsCest.php index e62e6f9d8..036299090 100644 --- a/tests/codeception/acceptance/AuthenticatedPermissionsCest.php +++ b/tests/codeception/acceptance/AuthenticatedPermissionsCest.php @@ -49,7 +49,7 @@ public function _after(AcceptanceTester $I) { /** * Make sure authenticated users can't access things they should not. */ - protected function footestAuthenticatedUserRestrictions(AcceptanceTester $I) { + public function testAuthenticatedUserRestrictions(AcceptanceTester $I) { $I->logInWithRole('authenticated'); $I->amOnPage('/'); $I->canSeeResponseCodeIs(200); @@ -76,7 +76,7 @@ protected function footestAuthenticatedUserRestrictions(AcceptanceTester $I) { /** * Make sure authenticated users can access things they should. */ - protected function footestAuthenticatedUserPermissions(AcceptanceTester $I) { + public function testAuthenticatedUserPermissions(AcceptanceTester $I) { $I->logInWithRole('authenticated'); $I->amOnPage('/patterns'); $I->canSeeResponseCodeIs(200); @@ -85,7 +85,7 @@ protected function footestAuthenticatedUserPermissions(AcceptanceTester $I) { /** * Site Manager cannot escalate their own role above Site Manager. */ - protected function footestSiteManagerEscalationSelf(AcceptanceTester $I) { + public function testSiteManagerEscalationSelf(AcceptanceTester $I) { $site_manager = $I->logInWithRole('site_manager'); $site_manager_id = $site_manager->id(); $I->amOnPage('/admin/users'); @@ -101,7 +101,7 @@ protected function footestSiteManagerEscalationSelf(AcceptanceTester $I) { /** * Site Manager cannot escalate others' role above Site Manager. */ - protected function footestSiteManagerEscalationOthers(AcceptanceTester $I) { + public function testSiteManagerEscalationOthers(AcceptanceTester $I) { $I->logInWithRole('site_manager'); $I->amOnPage('/admin/users'); $I->canSee('Morgan'); @@ -115,7 +115,7 @@ protected function footestSiteManagerEscalationOthers(AcceptanceTester $I) { /** * PHP code is not allowed in redirects. */ - protected function footestPhpInRedirect(AcceptanceTester $I) { + public function testPhpInRedirect(AcceptanceTester $I) { $I->logInWithRole('site_manager'); $I->amOnPage('/admin/config/search/redirect/add'); $I->fillField('#edit-redirect-source-0-path', 'home'); @@ -128,7 +128,7 @@ protected function footestPhpInRedirect(AcceptanceTester $I) { /** * PHP code is escaped and not run when added to content. */ - protected function footestPhpInContent(AcceptanceTester $I) { + public function testPhpInContent(AcceptanceTester $I) { $I->logInWithRole('site_manager'); $I->amOnPage('/node/add/stanford_page'); $I->fillField('#edit-title-0-value', ''); @@ -140,7 +140,7 @@ protected function footestPhpInContent(AcceptanceTester $I) { /** * PHP files are not allowed as uploads for favicons. */ - protected function footestPhpUploadInFavicon(AcceptanceTester $I) { + public function testPhpUploadInFavicon(AcceptanceTester $I) { $I->logInWithRole('administrator'); $I->amOnPage('/admin/appearance/settings'); $I->seeCheckboxIsChecked('#edit-default-favicon'); @@ -156,7 +156,7 @@ protected function footestPhpUploadInFavicon(AcceptanceTester $I) { /** * PHP files are not allowed as uploads for the logo. */ - protected function footestPhpUploadInLogo(AcceptanceTester $I) { + public function testPhpUploadInLogo(AcceptanceTester $I) { $I->logInWithRole('administrator'); $I->amOnPage('/admin/appearance/settings'); $I->seeCheckboxIsChecked('#edit-default-logo'); @@ -173,7 +173,7 @@ protected function footestPhpUploadInLogo(AcceptanceTester $I) { /** * Vocabs aren't seen if there are no permissions for them. */ - protected function footestTaxonomyOverviewPage(AcceptanceTester $I) { + public function testTaxonomyOverviewPage(AcceptanceTester $I) { $name = $this->faker->firstName; $vocab = $I->createEntity([ 'vid' => strtolower($name), diff --git a/tests/codeception/acceptance/Content/BasicPageCest.php b/tests/codeception/acceptance/Content/BasicPageCest.php index fcf227af9..8f72a425f 100644 --- a/tests/codeception/acceptance/Content/BasicPageCest.php +++ b/tests/codeception/acceptance/Content/BasicPageCest.php @@ -29,7 +29,7 @@ public function __construct() { * @group pathauto * @group menu_link_weight */ - protected function footestCreatingPage(AcceptanceTester $I) { + public function testCreatingPage(AcceptanceTester $I) { $node_title = $this->faker->text(20); $node = $I->createEntity([ 'type' => 'stanford_page', @@ -72,7 +72,7 @@ protected function footestCreatingPage(AcceptanceTester $I) { /** * Test deleting menu items clears them from the main menu. */ - protected function footestDeletedMenuItems(AcceptanceTester $I) { + public function testDeletedMenuItems(AcceptanceTester $I) { $node_title = $this->faker->text(20); $node = $I->createEntity([ 'type' => 'stanford_page', @@ -100,7 +100,7 @@ protected function footestDeletedMenuItems(AcceptanceTester $I) { /** * Number of h1 tags should always be 1. */ - protected function footestH1Tags(AcceptanceTester $I) { + public function testH1Tags(AcceptanceTester $I) { $I->amOnPage('/' . $this->faker->text); $I->canSeeResponseCodeIs(404); $I->canSeeNumberOfElements('h1', 1); @@ -116,7 +116,7 @@ protected function footestH1Tags(AcceptanceTester $I) { * * Regression test for D8CORE-1547. */ - protected function footestRevisionPage(AcceptanceTester $I) { + public function testRevisionPage(AcceptanceTester $I) { $title = $this->faker->words(3, TRUE); $I->logInWithRole('site_manager'); $node = $I->createEntity(['title' => $title, 'type' => 'stanford_page']); @@ -128,7 +128,7 @@ protected function footestRevisionPage(AcceptanceTester $I) { /** * There should be Page Metadata fields */ - protected function footestPageDescription(AcceptanceTester $I) { + public function testPageDescription(AcceptanceTester $I) { $title = $this->faker->words(3, TRUE); $description = $this->faker->words(10, TRUE); $type_term = $I->createEntity([ @@ -150,7 +150,7 @@ protected function footestPageDescription(AcceptanceTester $I) { /** * Test that the vocabulary and default terms exist. */ - protected function footestBasicPageVocabularyTermsExists(AcceptanceTester $I) { + public function testBasicPageVocabularyTermsExists(AcceptanceTester $I) { $I->logInWithRole('site_manager'); $I->amOnPage("/admin/structure/taxonomy/manage/basic_page_types/overview"); $I->canSeeResponseCodeIs(200); @@ -167,7 +167,7 @@ protected function footestBasicPageVocabularyTermsExists(AcceptanceTester $I) { * * @group menu_link_weight */ - protected function footestUnpublishedMenuItems(AcceptanceTester $I) { + public function testUnpublishedMenuItems(AcceptanceTester $I) { $unpublished_title = $this->faker->words(5, TRUE); $unpublished_node = $I->createEntity([ 'type' => 'stanford_page', @@ -205,7 +205,7 @@ protected function footestUnpublishedMenuItems(AcceptanceTester $I) { /** * Clone a basic page. */ - protected function footestClone(AcceptanceTester $I) { + public function testClone(AcceptanceTester $I) { $title = $this->faker->words(3, TRUE); $I->logInWithRole('contributor'); @@ -228,7 +228,7 @@ protected function footestClone(AcceptanceTester $I) { * * @group scheduler */ - protected function footestScheduler(AcceptanceTester $I) { + public function testScheduler(AcceptanceTester $I) { $time = \Drupal::time(); /** @var \Drupal\system\TimeZoneResolver $timezone_resolver */ @@ -257,7 +257,7 @@ protected function footestScheduler(AcceptanceTester $I) { /** * Validate the Spacer Paragraph type exists */ - protected function footestSpacerParagraph(AcceptanceTester $I) { + public function testSpacerParagraph(AcceptanceTester $I) { $I->logInWithRole('administrator'); $I->amOnPage('/admin/structure/paragraphs_type'); $I->canSee('Spacer'); @@ -269,7 +269,7 @@ protected function footestSpacerParagraph(AcceptanceTester $I) { * * @group metadata */ - protected function footestMetaData(AcceptanceTester $I) { + public function testMetaData(AcceptanceTester $I) { $values = [ 'banner_image_alt' => $this->faker->words(3, TRUE), 'meta_image_alt' => $this->faker->words(3, TRUE), @@ -364,7 +364,7 @@ protected function footestMetaData(AcceptanceTester $I) { /** * @group search-results */ - protected function footestSearchResult(AcceptanceTester $I) { + public function testSearchResult(AcceptanceTester $I) { $text = $this->faker->paragraphs(2, TRUE); $wysiwyg = $I->createEntity([ 'type' => 'stanford_wysiwyg', diff --git a/tests/codeception/acceptance/Content/CoursesCest.php b/tests/codeception/acceptance/Content/CoursesCest.php index c26a4f456..3a2143963 100644 --- a/tests/codeception/acceptance/Content/CoursesCest.php +++ b/tests/codeception/acceptance/Content/CoursesCest.php @@ -24,7 +24,7 @@ public function __construct() { /** * Test for view pages and taxonomy functionality */ - protected function footestViewPagesExist(AcceptanceTester $I) { + public function testViewPagesExist(AcceptanceTester $I) { $I->logInWithRole('administrator'); $quarters_term = $this->createCourseQuartersTerm($I); $subject_term = $this->createCourseSubjectsTerm($I); @@ -63,7 +63,7 @@ protected function footestViewPagesExist(AcceptanceTester $I) { /** * Test rabbit hole settings and field locking */ - protected function footestRabbitHoleRedirects(AcceptanceTester $I) { + public function testRabbitHoleRedirects(AcceptanceTester $I) { $I->logInWithRole('administrator'); $quarters_term = $this->createCourseQuartersTerm($I); $subject_term = $this->createCourseSubjectsTerm($I); diff --git a/tests/codeception/acceptance/Content/CustomBlockCest.php b/tests/codeception/acceptance/Content/CustomBlockCest.php index 189e95961..a15d5da0f 100644 --- a/tests/codeception/acceptance/Content/CustomBlockCest.php +++ b/tests/codeception/acceptance/Content/CustomBlockCest.php @@ -22,7 +22,7 @@ public function __construct() { /** * Site managers should be able to edit custom blocks. */ - protected function footestCustomBlockAccess(AcceptanceTester $I) { + public function testCustomBlockAccess(AcceptanceTester $I) { $block = $I->createEntity([ 'type' => 'stanford_component_block', 'info' => $this->faker->word(3, TRUE), diff --git a/tests/codeception/acceptance/Content/DefaultContentCest.php b/tests/codeception/acceptance/Content/DefaultContentCest.php index e9172f6da..5f2da6f17 100644 --- a/tests/codeception/acceptance/Content/DefaultContentCest.php +++ b/tests/codeception/acceptance/Content/DefaultContentCest.php @@ -10,7 +10,7 @@ class DefaultContentCest { /** * Test default images. */ - protected function footestDefaultImages(AcceptanceTester $I) { + public function testDefaultImages(AcceptanceTester $I) { $files = \Drupal::entityTypeManager()->getStorage('file')->loadMultiple(); /** @var \Drupal\file\FileInterface $file */ @@ -30,7 +30,7 @@ protected function footestDefaultImages(AcceptanceTester $I) { /** * Default content pages and meta data exist. */ - protected function footestExistingContent(AcceptanceTester $I) { + public function testExistingContent(AcceptanceTester $I) { $pages = [ '/', '/resources', @@ -49,7 +49,7 @@ protected function footestExistingContent(AcceptanceTester $I) { /** * There should be at least 15 media items. */ - protected function footestMedia(AcceptanceTester $I) { + public function testMedia(AcceptanceTester $I) { $I->logInWithRole('administrator'); $I->amOnPage('/admin/content/media'); $I->canSeeNumberOfElements('table img, form img', [15, 999]); @@ -58,7 +58,7 @@ protected function footestMedia(AcceptanceTester $I) { /** * XML Sitemap should exist after cron. */ - protected function footestXmlSitemap(AcceptanceTester $I) { + public function testXmlSitemap(AcceptanceTester $I) { $I->runDrush('cron'); $I->amOnPage('/sitemap.xml'); $I->canSeeResponseCodeIs(200); @@ -69,7 +69,7 @@ protected function footestXmlSitemap(AcceptanceTester $I) { * * @group menu_link_weight */ - protected function footestMenuItems(AcceptanceTester $I) { + public function testMenuItems(AcceptanceTester $I) { $I->logInWithRole('site_manager'); $I->amOnPage('/admin/structure/menu/manage/main'); diff --git a/tests/codeception/acceptance/Content/EventsCest.php b/tests/codeception/acceptance/Content/EventsCest.php index 66c26956c..40c8fb1d4 100644 --- a/tests/codeception/acceptance/Content/EventsCest.php +++ b/tests/codeception/acceptance/Content/EventsCest.php @@ -36,7 +36,7 @@ public function _after(AcceptanceTester $I) { * * @group D8CORE-4858 */ - protected function footestListIntro(AcceptanceTester $I) { + public function testListIntro(AcceptanceTester $I) { // Start with no events. $nodes = \Drupal::entityTypeManager() ->getStorage('node') @@ -97,7 +97,7 @@ protected function footestListIntro(AcceptanceTester $I) { /** * Ensure events are in the sitemap. */ - protected function footestXMLSiteMap(AcceptanceTester $I) { + public function testXMLSiteMap(AcceptanceTester $I) { $I->logInWithRole('administrator'); $I->amOnPage('/admin/config/search/xmlsitemap/settings/node/stanford_event'); $I->seeOptionIsSelected('#edit-xmlsitemap-status', 'Included'); @@ -107,7 +107,7 @@ protected function footestXMLSiteMap(AcceptanceTester $I) { /** * Test Page Title Conditions. */ - protected function footestPageTitleIgnoreCondition(AcceptanceTester $I) { + public function testPageTitleIgnoreCondition(AcceptanceTester $I) { $I->logInWithRole('administrator'); // Todo: make theme name dynamic. $I->amOnPage('/admin/structure/block/manage/stanford_basic_pagetitle'); @@ -121,7 +121,7 @@ protected function footestPageTitleIgnoreCondition(AcceptanceTester $I) { /** * Test the event content type exists and has at least a couple of fields. */ - protected function footestContentTypeExists(AcceptanceTester $I) { + public function testContentTypeExists(AcceptanceTester $I) { $I->logInWithRole('administrator'); $I->amOnPage('/admin/structure/types/manage/stanford_event/fields'); $I->canSee('body'); @@ -148,7 +148,7 @@ protected function footestContentTypeExists(AcceptanceTester $I) { /** * Test Access to stuff for contrib role. */ - protected function footestContributorPerms(AcceptanceTester $I) { + public function testContributorPerms(AcceptanceTester $I) { $I->logInWithRole('contributor'); // Can create a node. @@ -188,7 +188,7 @@ protected function footestContributorPerms(AcceptanceTester $I) { /** * Test thing. */ - protected function footestEditorPerms(AcceptanceTester $I) { + public function testEditorPerms(AcceptanceTester $I) { $I->logInWithRole('site_editor'); // Can create a node. @@ -233,7 +233,7 @@ protected function footestEditorPerms(AcceptanceTester $I) { /** * Test thing. */ - protected function footestSiteManagerPerms(AcceptanceTester $I) { + public function testSiteManagerPerms(AcceptanceTester $I) { $I->logInWithRole('site_manager'); // Can create a node. @@ -277,7 +277,7 @@ protected function footestSiteManagerPerms(AcceptanceTester $I) { /** * Test to make sure the main menu link is there. */ - protected function footestDefaultContentExists(AcceptanceTester $I) { + public function testDefaultContentExists(AcceptanceTester $I) { $I->logInWithRole('administrator'); // Events Main Menu Link. $I->amOnPage('/admin/structure/menu/manage/main'); @@ -287,7 +287,7 @@ protected function footestDefaultContentExists(AcceptanceTester $I) { /** * Published checkbox should be hidden on term edit pages. */ - protected function footestTermPublishing(AcceptanceTester $I) { + public function testTermPublishing(AcceptanceTester $I) { $I->logInWithRole('site_manager'); $term = $I->createEntity([ 'vid' => 'event_audience', @@ -307,7 +307,7 @@ protected function footestTermPublishing(AcceptanceTester $I) { /** * Clone events get incremented date. */ - protected function footestClone(AcceptanceTester $I) { + public function testClone(AcceptanceTester $I) { $user = $I->createUserWithRoles(['contributor']); /** @var \Drupal\node\NodeInterface $node */ $node = $this->createEventNode($I); @@ -359,19 +359,26 @@ public function testEventCard(AcceptanceTester $I) { $month = $xpath->query('//span[@class="su-event-start-month"]'); $I->assertNotEmpty($month); - $I->assertEquals(date('M', time()), $month->item(0)->nodeValue, 'Start Month does not match'); + $I->assertEquals(self::getDateTimeString('M', time()), preg_replace('/(\r\n|\n|\r)/', '', $month->item(0)->nodeValue), 'Start Month does not match'); $day = $xpath->query('//span[@class="su-event-start-date"]'); $I->assertNotEmpty($day); - $I->assertEquals(date('j', time()), $day->item(0)->nodeValue, 'Start Date does not match'); + $I->assertEquals(self::getDateTimeString('j', time()), preg_replace('/(\r\n|\n|\r)/', '', $day->item(0)->nodeValue), 'Start Date does not match'); $month = $xpath->query('//span[@class="su-event-end-month"]'); $I->assertNotEmpty($month); - $I->assertEquals(date('M', time() + (60 * 60 * 24)), $month->item(0)->nodeValue, 'End Month does not match'); + $I->assertEquals(self::getDateTimeString('M', time() + (60 * 60 * 24)), preg_replace('/(\r\n|\n|\r)/', '', $month->item(0)->nodeValue), 'End Month does not match'); $day = $xpath->query('//span[@class="su-event-end-date"]'); $I->assertNotEmpty($day); - $I->assertEquals(date('j', time() + (60 * 60 * 24)), $day->item(0)->nodeValue, 'End Date does not match'); + $I->assertEquals(self::getDateTimeString('j', time() + (60 * 60 * 24)), preg_replace('/(\r\n|\n|\r)/', '', $day->item(0)->nodeValue), 'End Date does not match'); + } + + protected static function getDateTimeString($format, $time) { + $timezone = \Drupal::config('system.date') + ->get('timezone.default') ?: @date_default_timezone_get(); + return \Drupal::service('date.formatter') + ->format($time, 'custom', $format, $timezone); } /** diff --git a/tests/codeception/acceptance/Content/EventsSeriesCest.php b/tests/codeception/acceptance/Content/EventsSeriesCest.php index 479550d9b..0b47c220b 100644 --- a/tests/codeception/acceptance/Content/EventsSeriesCest.php +++ b/tests/codeception/acceptance/Content/EventsSeriesCest.php @@ -26,7 +26,7 @@ public function __construct() { /** * Ensure events are in the sitemap. */ - protected function footestXMLSiteMap(AcceptanceTester $I) { + public function testXMLSiteMap(AcceptanceTester $I) { $I->logInWithRole('administrator'); $I->amOnPage('/admin/config/search/xmlsitemap/settings/node/stanford_event_series'); $I->seeOptionIsSelected('#edit-xmlsitemap-status', 'Included'); @@ -36,7 +36,7 @@ protected function footestXMLSiteMap(AcceptanceTester $I) { /** * Test Page Title Conditions. */ - protected function footestPageTitleIgnoreCondition(AcceptanceTester $I) { + public function testPageTitleIgnoreCondition(AcceptanceTester $I) { $I->logInWithRole('administrator'); // Todo: make theme name dynamic. $I->amOnPage('/admin/structure/block/manage/stanford_basic_pagetitle'); @@ -50,7 +50,7 @@ protected function footestPageTitleIgnoreCondition(AcceptanceTester $I) { /** * Test the the event content type exists and has at least a couple of fields. */ - protected function footestContentTypeExists(AcceptanceTester $I) { + public function testContentTypeExists(AcceptanceTester $I) { $I->logInWithRole('administrator'); $I->amOnPage('/admin/structure/types/manage/stanford_event_series/fields'); $I->canSee('su_event_series_subheadline'); @@ -60,7 +60,7 @@ protected function footestContentTypeExists(AcceptanceTester $I) { /** * Test Access to stuff for contrib role. */ - protected function footestContributorPerms(AcceptanceTester $I) { + public function testContributorPerms(AcceptanceTester $I) { $I->logInWithRole('contributor'); // D8CORE-4551: Can NOT create a node. @@ -85,7 +85,7 @@ protected function footestContributorPerms(AcceptanceTester $I) { /** * Test thing. */ - protected function footestEditorPerms(AcceptanceTester $I) { + public function testEditorPerms(AcceptanceTester $I) { $I->logInWithRole('site_editor'); // Can create a node. @@ -115,7 +115,7 @@ protected function footestEditorPerms(AcceptanceTester $I) { /** * Test thing. */ - protected function footestSiteManagerPerms(AcceptanceTester $I) { + public function testSiteManagerPerms(AcceptanceTester $I) { $I->logInWithRole('site_manager'); // Can create a node. diff --git a/tests/codeception/acceptance/Content/NewsCest.php b/tests/codeception/acceptance/Content/NewsCest.php index 84fa98b10..4e00a502c 100644 --- a/tests/codeception/acceptance/Content/NewsCest.php +++ b/tests/codeception/acceptance/Content/NewsCest.php @@ -26,7 +26,7 @@ public function __construct() { /** * News list intro block is at the top of the page. */ - protected function footestListIntro(AcceptanceTester $I) { + public function testListIntro(AcceptanceTester $I) { $I->logInWithRole('site_manager'); $I->amOnPage('/news'); $I->canSeeResponseCodeIs(200); @@ -35,7 +35,7 @@ protected function footestListIntro(AcceptanceTester $I) { /** * Test that the default content has installed and is unpublished. */ - protected function footestDefaultContentExists(AcceptanceTester $I) { + public function testDefaultContentExists(AcceptanceTester $I) { $I->logInWithRole('administrator'); $I->amOnPage("/admin/content"); $I->see("Sample: Smith Conference"); @@ -57,7 +57,7 @@ protected function footestDefaultContentExists(AcceptanceTester $I) { /** * Test that the vocabulary and terms exist. */ - protected function footestVocabularyTermsExists(AcceptanceTester $I) { + public function testVocabularyTermsExists(AcceptanceTester $I) { $I->logInWithRole('administrator'); $I->amOnPage("/admin/structure/taxonomy/manage/stanford_news_topics/overview"); $I->canSeeNumberOfElements("input.term-id", [2, 99]); @@ -66,7 +66,7 @@ protected function footestVocabularyTermsExists(AcceptanceTester $I) { /** * Test that the view pages exist. */ - protected function footestViewPagesExist(AcceptanceTester $I) { + public function testViewPagesExist(AcceptanceTester $I) { $I->amOnPage("/news"); $I->seeLink('Announcement'); $I->click("a[href='/news/announcement']"); @@ -77,7 +77,7 @@ protected function footestViewPagesExist(AcceptanceTester $I) { /** * Validate external content redirect. */ - protected function footestExternalSourceArticle(AcceptanceTester $I) { + public function testExternalSourceArticle(AcceptanceTester $I) { $node = $I->createEntity([ 'type' => 'stanford_news', 'title' => $this->faker->words(3, TRUE), @@ -98,7 +98,7 @@ protected function footestExternalSourceArticle(AcceptanceTester $I) { * Test that only two of three new news nodes show up in the more news view * on the node page. */ - protected function footestMoreNewsView(AcceptanceTester $I) { + public function testMoreNewsView(AcceptanceTester $I) { $I->logInWithRole('administrator'); $first_news = $I->createEntity([ @@ -121,7 +121,7 @@ protected function footestMoreNewsView(AcceptanceTester $I) { /** * Test that the XML sitemap and metatag configuration is set. */ - protected function footestXMLMetaDataRevisions(AcceptanceTester $I) { + public function testXMLMetaDataRevisions(AcceptanceTester $I) { $I->logInWithRole('administrator'); // Revision Delete is enabled. @@ -144,7 +144,7 @@ protected function footestXMLMetaDataRevisions(AcceptanceTester $I) { /** * Published checkbox should be hidden on term edit pages. */ - protected function footestTermPublishing(AcceptanceTester $I) { + public function testTermPublishing(AcceptanceTester $I) { $I->logInWithRole('site_manager'); $term = $I->createEntity([ 'vid' => 'stanford_news_topics', @@ -159,7 +159,7 @@ protected function footestTermPublishing(AcceptanceTester $I) { * * @group metadata */ - protected function footestMetaData(AcceptanceTester $I) { + public function testMetaData(AcceptanceTester $I) { $values = [ 'featured_image_alt' => $this->faker->words(3, TRUE), 'banner_image_alt' => $this->faker->words(3, TRUE), diff --git a/tests/codeception/acceptance/Content/PersonCest.php b/tests/codeception/acceptance/Content/PersonCest.php index 21d3165f6..4f6c3f7bf 100644 --- a/tests/codeception/acceptance/Content/PersonCest.php +++ b/tests/codeception/acceptance/Content/PersonCest.php @@ -26,7 +26,7 @@ public function __construct() { /** * Test that the default content has installed and is unpublished. */ - protected function footestDefaultContentExists(AcceptanceTester $I) { + public function testDefaultContentExists(AcceptanceTester $I) { $I->logInWithRole('administrator'); $I->amOnPage('/admin/content'); $I->see('Haley Jackson'); @@ -39,7 +39,7 @@ protected function footestDefaultContentExists(AcceptanceTester $I) { /** * Test that the vocabulary and terms exist. */ - protected function footestVocabularyTermsExists(AcceptanceTester $I) { + public function testVocabularyTermsExists(AcceptanceTester $I) { $I->logInWithRole('administrator'); $I->amOnPage('/admin/structure/taxonomy/manage/stanford_person_types/overview'); $I->canSeeNumberOfElements('.term-id', 14); @@ -48,7 +48,7 @@ protected function footestVocabularyTermsExists(AcceptanceTester $I) { /** * Test that the view pages exist. */ - protected function footestViewPagesExist(AcceptanceTester $I) { + public function testViewPagesExist(AcceptanceTester $I) { $I->amOnPage('/people'); $I->seeLink('Student'); $I->seeLink('Staff'); @@ -61,7 +61,7 @@ protected function footestViewPagesExist(AcceptanceTester $I) { * Test that content that gets created has the right url, header, and shows * up in the all view. */ - protected function footestCreatePerson(AcceptanceTester $I) { + public function testCreatePerson(AcceptanceTester $I) { $term = $I->createEntity([ 'vid' => 'stanford_person_types', 'name' => $this->faker->word, @@ -91,7 +91,7 @@ protected function footestCreatePerson(AcceptanceTester $I) { /** * Test that the XML sitemap and metatag configuration is set. */ - protected function footestXMLMetaDataRevisions(AcceptanceTester $I) { + public function testXMLMetaDataRevisions(AcceptanceTester $I) { $I->logInWithRole('administrator'); // Revision Delete is enabled. @@ -114,7 +114,7 @@ protected function footestXMLMetaDataRevisions(AcceptanceTester $I) { /** * CAP-52: Check for the new fields. */ - protected function footestCap52Fields(AcceptanceTester $I) { + public function testCap52Fields(AcceptanceTester $I) { $I->logInWithRole('administrator'); $I->amOnPage('/admin/structure/types/manage/stanford_person/fields'); @@ -131,7 +131,7 @@ protected function footestCap52Fields(AcceptanceTester $I) { /** * Special characters should stay. */ - protected function footestSpecialCharacters(AcceptanceTester $I) { + public function testSpecialCharacters(AcceptanceTester $I) { $first_name = $this->faker->firstName; $middle_name = $this->faker->firstName; $last_name = $this->faker->lastName; @@ -150,7 +150,7 @@ protected function footestSpecialCharacters(AcceptanceTester $I) { * * @group 4704 */ - protected function footestD8Core2613Terms(AcceptanceTester $I) { + public function testD8Core2613Terms(AcceptanceTester $I) { $term1 = $I->createEntity([ 'name' => $this->faker->words(2, TRUE), 'vid' => 'stanford_person_types', @@ -244,7 +244,7 @@ protected function footestD8Core2613Terms(AcceptanceTester $I) { /** * Published checkbox should be hidden on term edit pages. */ - protected function footestTermPublishing(AcceptanceTester $I) { + public function testTermPublishing(AcceptanceTester $I) { $I->logInWithRole('site_manager'); $term = $I->createEntity([ 'vid' => 'stanford_person_types', @@ -257,7 +257,7 @@ protected function footestTermPublishing(AcceptanceTester $I) { /** * Unpublished profiles should not display in the list. */ - protected function footestPublishedStatus(AcceptanceTester $I) { + public function testPublishedStatus(AcceptanceTester $I) { $term = $I->createEntity([ 'name' => $this->faker->words(2, TRUE), 'vid' => 'stanford_person_types', @@ -288,7 +288,7 @@ protected function footestPublishedStatus(AcceptanceTester $I) { * * @group metadata */ - protected function footestMetaData(AcceptanceTester $I) { + public function testMetaData(AcceptanceTester $I) { $values = [ 'image_alt' => $this->faker->words(3, TRUE), 'body' => $this->faker->paragraph, @@ -344,7 +344,7 @@ protected function footestMetaData(AcceptanceTester $I) { /** * Deleting the taxonomy term doesn't break the form. */ - protected function footestDeletedTerm(AcceptanceTester $I) { + public function testDeletedTerm(AcceptanceTester $I) { $term = $I->createEntity([ 'name' => $this->faker->words(2, TRUE), 'vid' => 'stanford_person_types', diff --git a/tests/codeception/acceptance/Content/PolicyCest.php b/tests/codeception/acceptance/Content/PolicyCest.php index 5cb1273fe..8dc1dbcf3 100644 --- a/tests/codeception/acceptance/Content/PolicyCest.php +++ b/tests/codeception/acceptance/Content/PolicyCest.php @@ -38,7 +38,7 @@ public function _after(AcceptanceTester $I) { /** * Test field access. */ - protected function footestPolicyAccess(AcceptanceTester $I) { + public function testPolicyAccess(AcceptanceTester $I) { $I->logInWithRole('contributor'); $I->amOnPage('/node/add/stanford_policy'); $I->cantSee('Create a new book'); @@ -71,7 +71,7 @@ protected function footestPolicyAccess(AcceptanceTester $I) { /** * Test book title changes. */ - protected function footestPolicyTitle(AcceptanceTester $I) { + public function testPolicyTitle(AcceptanceTester $I) { $title = $this->faker->words(4, TRUE) . ' foo bar'; $I->logInWithRole('administrator'); $I->amOnPage('/node/add/stanford_policy'); @@ -92,7 +92,7 @@ protected function footestPolicyTitle(AcceptanceTester $I) { * * @group menu_link_weight */ - protected function footestPolicyPathAuto(AcceptanceTester $I) { + public function testPolicyPathAuto(AcceptanceTester $I) { $title = $this->faker->words(4, TRUE) . ' foo bar'; $I->logInWithRole('administrator'); $I->amOnPage('/node/add/stanford_policy'); @@ -163,7 +163,7 @@ protected function footestPolicyPathAuto(AcceptanceTester $I) { * * @group menu_link_weight */ - protected function footestPolicyHeirarcy(AcceptanceTester $I) { + public function testPolicyHeirarcy(AcceptanceTester $I) { $I->logInWithRole('administrator'); $book = $I->createEntity([ 'type' => 'stanford_policy', diff --git a/tests/codeception/acceptance/Content/PublicationsCest.php b/tests/codeception/acceptance/Content/PublicationsCest.php index d374d16d7..aabdd00b5 100644 --- a/tests/codeception/acceptance/Content/PublicationsCest.php +++ b/tests/codeception/acceptance/Content/PublicationsCest.php @@ -33,7 +33,7 @@ public function __construct() { /** * Create a book citation */ - protected function footestBookCitation(AcceptanceTester $I) { + public function testBookCitation(AcceptanceTester $I) { $this->values['term_name'] = $this->faker->words(3, TRUE); $this->values['node_title'] = $this->faker->words(3, TRUE); $term = $I->createEntity([ @@ -63,7 +63,7 @@ protected function footestBookCitation(AcceptanceTester $I) { /** * Test out the list pages. */ - protected function footestAllPublicationListPage(AcceptanceTester $I) { + public function testAllPublicationListPage(AcceptanceTester $I) { $this->testBookCitation($I); $I->amOnPage('/publications'); @@ -87,7 +87,7 @@ protected function footestAllPublicationListPage(AcceptanceTester $I) { /** * Published checkbox should be hidden on term edit pages. */ - protected function footestTermPublishing(AcceptanceTester $I) { + public function testTermPublishing(AcceptanceTester $I) { $I->logInWithRole('site_manager'); $term = $I->createEntity([ 'vid' => 'stanford_publication_topics', @@ -100,7 +100,7 @@ protected function footestTermPublishing(AcceptanceTester $I) { /** * An "Other" publication type should be available. */ - protected function footestOtherPublication(AcceptanceTester $I) { + public function testOtherPublication(AcceptanceTester $I) { $this->values['node_title'] = $this->faker->words(3, TRUE); $I->logInWithRole('site_manager'); $I->amOnPage('/node/add/stanford_publication'); @@ -122,7 +122,7 @@ protected function footestOtherPublication(AcceptanceTester $I) { /** * Publication list should be in date order. */ - protected function footestListSort(AcceptanceTester $I) { + public function testListSort(AcceptanceTester $I) { $this->values['a_node_title'] = 'A' . $this->faker->words(3, TRUE); $this->values['b_node_title'] = 'B' . $this->faker->words(3, TRUE); $this->values['c_node_title'] = 'C' . $this->faker->words(3, TRUE); @@ -185,7 +185,7 @@ protected function footestListSort(AcceptanceTester $I) { * * @group D8CORE-4867 */ - protected function footestPubAuthorPage(AcceptanceTester $I) { + public function testPubAuthorPage(AcceptanceTester $I) { $first_name = $this->faker->firstName; $last_name = $this->faker->lastName; $author_node = $I->createEntity([ @@ -219,7 +219,7 @@ protected function footestPubAuthorPage(AcceptanceTester $I) { /** * Journal citations should include a field for journal publisher. */ - protected function footestJournalPublisher(AcceptanceTester $I) { + public function testJournalPublisher(AcceptanceTester $I) { $term = $I->createEntity([ 'vid' => 'stanford_publication_topics', 'name' => $this->faker->word, diff --git a/tests/codeception/acceptance/Content/SearchBlockCest.php b/tests/codeception/acceptance/Content/SearchBlockCest.php index 6ab236523..573d4f9f5 100644 --- a/tests/codeception/acceptance/Content/SearchBlockCest.php +++ b/tests/codeception/acceptance/Content/SearchBlockCest.php @@ -26,7 +26,7 @@ public function __before() { /** * Site managers should be able to disable the search block. */ - protected function footestHideSearchBlock(AcceptanceTester $I) { + public function testHideSearchBlock(AcceptanceTester $I) { $org_term = $I->createEntity([ 'vid' => 'site_owner_orgs', 'name' => $this->faker->words(2, TRUE), diff --git a/tests/codeception/acceptance/Contrib/ConfigReadonlyCest.php b/tests/codeception/acceptance/Contrib/ConfigReadonlyCest.php index 324c143ba..8e162eeb7 100644 --- a/tests/codeception/acceptance/Contrib/ConfigReadonlyCest.php +++ b/tests/codeception/acceptance/Contrib/ConfigReadonlyCest.php @@ -11,7 +11,7 @@ class ConfigReadonlyCest { /** * Config readonly module should be enabled. */ - protected function footestConfigReadonlyModule(AcceptanceTester $I) { + public function testConfigReadonlyModule(AcceptanceTester $I) { $drush_result = $I->runDrush('pm-list --filter=name=config_readonly --format=json'); $drush_result = json_decode($drush_result, TRUE); $I->assertEquals('Enabled', $drush_result['config_readonly']['status']); diff --git a/tests/codeception/acceptance/Contrib/MenuBlockCest.php b/tests/codeception/acceptance/Contrib/MenuBlockCest.php index 1dcf5a924..972099c92 100644 --- a/tests/codeception/acceptance/Contrib/MenuBlockCest.php +++ b/tests/codeception/acceptance/Contrib/MenuBlockCest.php @@ -23,7 +23,7 @@ public function __construct() { * * @group menu_block */ - protected function footestMenuBlockVisibility(AcceptanceTester $I) { + public function testMenuBlockVisibility(AcceptanceTester $I) { $parent = $I->createEntity([ 'type' => 'stanford_page', 'title' => $this->faker->words(3, TRUE), diff --git a/tests/codeception/acceptance/Contrib/NodeRevisionDeleteCest.php b/tests/codeception/acceptance/Contrib/NodeRevisionDeleteCest.php index d2ffcaadb..60cb34e03 100644 --- a/tests/codeception/acceptance/Contrib/NodeRevisionDeleteCest.php +++ b/tests/codeception/acceptance/Contrib/NodeRevisionDeleteCest.php @@ -24,7 +24,7 @@ public function __construct() { /** * Test that revisions are trimmed after cron runs. */ - protected function footestNodeRevisionDelete(AcceptanceTester $I) { + public function testNodeRevisionDelete(AcceptanceTester $I) { $I->logInWithRole('administrator'); /** @var \Drupal\node\NodeInterface $node */ $node = $I->createEntity([ diff --git a/tests/codeception/acceptance/Contrib/ViewsBulkEditCest.php b/tests/codeception/acceptance/Contrib/ViewsBulkEditCest.php index 2f31ed644..8b4bb079a 100644 --- a/tests/codeception/acceptance/Contrib/ViewsBulkEditCest.php +++ b/tests/codeception/acceptance/Contrib/ViewsBulkEditCest.php @@ -32,7 +32,7 @@ public function __construct() { /** * Bulk editing content changes the field values. */ - protected function footestBulkEdits(AcceptanceTester $I) { + public function testBulkEdits(AcceptanceTester $I) { $I->logInWithRole('site_manager'); $this->createEvents($I); diff --git a/tests/codeception/acceptance/Contrib/XmlsitemapCest.php b/tests/codeception/acceptance/Contrib/XmlsitemapCest.php index 7073eb8b4..85ec58bb4 100644 --- a/tests/codeception/acceptance/Contrib/XmlsitemapCest.php +++ b/tests/codeception/acceptance/Contrib/XmlsitemapCest.php @@ -8,7 +8,7 @@ class XmlsitemapCest { /** * Test that xmlsitemap is having 403 and 404 pages removed. */ - protected function footestStanfordProfileSitemapLinkAlter(AcceptanceTester $I) { + public function testStanfordProfileSitemapLinkAlter(AcceptanceTester $I) { $I->logInWithRole('administrator'); $I->amOnPage("/admin/config/search/xmlsitemap/rebuild"); $I->click('Save configuration'); diff --git a/tests/codeception/acceptance/GlobalMessage/GlobalMessageCest.php b/tests/codeception/acceptance/GlobalMessage/GlobalMessageCest.php index 301894e74..f43393963 100644 --- a/tests/codeception/acceptance/GlobalMessage/GlobalMessageCest.php +++ b/tests/codeception/acceptance/GlobalMessage/GlobalMessageCest.php @@ -20,7 +20,7 @@ public function _after(AcceptanceTester $I) { /** * Test the block exists. */ - protected function footestBlockExists(AcceptanceTester $I) { + public function testBlockExists(AcceptanceTester $I) { $I->logInWithRole('administrator'); $I->amOnPage('/admin/structure/block'); $I->canSee('Global Messages'); @@ -29,7 +29,7 @@ protected function footestBlockExists(AcceptanceTester $I) { /** * Test the Form exists. */ - protected function footestFormExists(AcceptanceTester $I) { + public function testFormExists(AcceptanceTester $I) { $I->logInWithRole('administrator'); $I->amOnPage('/admin/config/system/global-message'); $I->canSee('Edit config page Global Message'); @@ -38,7 +38,7 @@ protected function footestFormExists(AcceptanceTester $I) { /** * Test the Form Settings. */ - protected function footestFormSettings(AcceptanceTester $I) { + public function testFormSettings(AcceptanceTester $I) { $I->logInWithRole('administrator'); $I->amOnPage('/admin/config/system/global-message'); $I->checkOption('#edit-su-global-msg-enabled-value'); @@ -69,7 +69,7 @@ protected function footestFormSettings(AcceptanceTester $I) { /** * Test user role permissions. */ - protected function footestAdminUserRole(AcceptanceTester $I) { + public function testAdminUserRole(AcceptanceTester $I) { // Admin. $I->logInWithRole('administrator'); $I->amOnPage('/admin/config/system/global-message'); @@ -80,7 +80,7 @@ protected function footestAdminUserRole(AcceptanceTester $I) { /** * Test user role permissions. */ - protected function footestSiteManagerUserRole(AcceptanceTester $I) { + public function testSiteManagerUserRole(AcceptanceTester $I) { // Site Manager. $I->logInWithRole('site_manager'); $I->amOnPage('/admin/config/system/global-message'); @@ -91,7 +91,7 @@ protected function footestSiteManagerUserRole(AcceptanceTester $I) { /** * Test user role permissions. */ - protected function footestSiteEditorUserRole(AcceptanceTester $I) { + public function testSiteEditorUserRole(AcceptanceTester $I) { // Editor. $I->logInWithRole('site_editor'); $I->amOnPage('/admin/config/system/global-message'); @@ -102,7 +102,7 @@ protected function footestSiteEditorUserRole(AcceptanceTester $I) { /** * Test user role permissions. */ - protected function footestContributorUserRole(AcceptanceTester $I) { + public function testContributorUserRole(AcceptanceTester $I) { // Contributor. $I->logInWithRole('contributor'); $I->amOnPage('/admin/config/system/global-message'); diff --git a/tests/codeception/acceptance/HomePageCest.php b/tests/codeception/acceptance/HomePageCest.php index e8d60d810..d9ffb0a11 100644 --- a/tests/codeception/acceptance/HomePageCest.php +++ b/tests/codeception/acceptance/HomePageCest.php @@ -8,7 +8,7 @@ class HomePageCest { /** * Validate the homepage loads. */ - protected function footestHomepage(AcceptanceTester $I) { + public function testHomepage(AcceptanceTester $I) { $I->amOnPage('/'); $I->canSee('Stanford'); $I->seeCurrentUrlEquals('/'); @@ -21,7 +21,7 @@ protected function footestHomepage(AcceptanceTester $I) { /** * Users can't unpublish the homepage. */ - protected function footestUnpublishingHomepage(AcceptanceTester $I) { + public function testUnpublishingHomepage(AcceptanceTester $I) { $I->logInWithRole('site_manager'); $I->amOnPage('/'); $I->click('Edit', '.tabs'); diff --git a/tests/codeception/acceptance/LocalFooter/LocalFooterCest.php b/tests/codeception/acceptance/LocalFooter/LocalFooterCest.php index 4d5d09a8c..afc47be28 100644 --- a/tests/codeception/acceptance/LocalFooter/LocalFooterCest.php +++ b/tests/codeception/acceptance/LocalFooter/LocalFooterCest.php @@ -22,7 +22,7 @@ public function _after(AcceptanceTester $I) { /** * Only site manager and higher should have access. */ - protected function footestAccess(AcceptanceTester $I) { + public function testAccess(AcceptanceTester $I) { $I->logInWithRole('contributor'); $I->amOnPage('/admin/config/system/local-footer'); $I->canSeeResponseCodeIs(403); @@ -35,7 +35,7 @@ protected function footestAccess(AcceptanceTester $I) { /** * Changes to the local footer should display correctly. */ - protected function footestCustomLocalFooter(AcceptanceTester $I) { + public function testCustomLocalFooter(AcceptanceTester $I) { $I->logInWithRole('site_manager'); $I->amOnPage('/admin/config/system/local-footer'); $I->checkOption('Enabled'); @@ -95,7 +95,7 @@ protected function footestCustomLocalFooter(AcceptanceTester $I) { /** * Content blocks. */ - protected function footestCustomContentLocalFooter(AcceptanceTester $I) { + public function testCustomContentLocalFooter(AcceptanceTester $I) { $I->logInWithRole('administrator'); $I->amOnPage('/admin/config/system/local-footer'); $I->checkOption('Enabled'); @@ -114,7 +114,7 @@ protected function footestCustomContentLocalFooter(AcceptanceTester $I) { /** * Route urls and no link urls should function correctly in the footer. */ - protected function footestNodeRoutesAndNoLink(AcceptanceTester $I) { + public function testNodeRoutesAndNoLink(AcceptanceTester $I) { $node = $I->createEntity([ 'type' => 'stanford_page', 'title' => 'Test Page', diff --git a/tests/codeception/acceptance/LocalFooter/LocalFooterLockupCest.php b/tests/codeception/acceptance/LocalFooter/LocalFooterLockupCest.php index 712cef84b..f020b2262 100644 --- a/tests/codeception/acceptance/LocalFooter/LocalFooterLockupCest.php +++ b/tests/codeception/acceptance/LocalFooter/LocalFooterLockupCest.php @@ -39,7 +39,7 @@ public function _after(AcceptanceTester $I) { /** * Test the lockup settings overrides. */ - protected function footestLockupSettingsA(AcceptanceTester $I) { + public function testLockupSettingsA(AcceptanceTester $I) { $I->logInWithRole('administrator'); $I->amOnPage('/admin/config/system/local-footer'); $I->canSeeResponseCodeIs(200); @@ -62,7 +62,7 @@ protected function footestLockupSettingsA(AcceptanceTester $I) { /** * Test the lockup settings overrides. */ - protected function footestLockupSettingsB(AcceptanceTester $I) { + public function testLockupSettingsB(AcceptanceTester $I) { $I->logInWithRole('administrator'); $I->amOnPage('/admin/config/system/local-footer'); $I->canSeeResponseCodeIs(200); @@ -85,7 +85,7 @@ protected function footestLockupSettingsB(AcceptanceTester $I) { /** * Test the lockup settings overrides. */ - protected function footestLockupSettingsD(AcceptanceTester $I) { + public function testLockupSettingsD(AcceptanceTester $I) { $I->logInWithRole('administrator'); $I->amOnPage('/admin/config/system/local-footer'); $I->canSeeResponseCodeIs(200); @@ -108,7 +108,7 @@ protected function footestLockupSettingsD(AcceptanceTester $I) { /** * Test the lockup settings overrides. */ - protected function footestLockupSettingsE(AcceptanceTester $I) { + public function testLockupSettingsE(AcceptanceTester $I) { $I->logInWithRole('administrator'); $I->amOnPage('/admin/config/system/local-footer'); $I->canSeeResponseCodeIs(200); @@ -132,7 +132,7 @@ protected function footestLockupSettingsE(AcceptanceTester $I) { /** * Test the lockup settings overrides. */ - protected function footestLockupSettingsH(AcceptanceTester $I) { + public function testLockupSettingsH(AcceptanceTester $I) { $I->logInWithRole('administrator'); $I->amOnPage('/admin/config/system/local-footer'); $I->canSeeResponseCodeIs(200); @@ -156,7 +156,7 @@ protected function footestLockupSettingsH(AcceptanceTester $I) { /** * Test the lockup settings overrides. */ - protected function footestLockupSettingsI(AcceptanceTester $I) { + public function testLockupSettingsI(AcceptanceTester $I) { $I->logInWithRole('administrator'); $I->amOnPage('/admin/config/system/local-footer'); $I->canSeeResponseCodeIs(200); @@ -180,7 +180,7 @@ protected function footestLockupSettingsI(AcceptanceTester $I) { /** * Test the lockup settings overrides. */ - protected function footestLockupSettingsM(AcceptanceTester $I) { + public function testLockupSettingsM(AcceptanceTester $I) { $I->logInWithRole('administrator'); $I->amOnPage('/admin/config/system/local-footer'); $I->canSeeResponseCodeIs(200); @@ -203,7 +203,7 @@ protected function footestLockupSettingsM(AcceptanceTester $I) { /** * Test the lockup settings overrides. */ - protected function footestLockupSettingsO(AcceptanceTester $I) { + public function testLockupSettingsO(AcceptanceTester $I) { $I->logInWithRole('administrator'); $I->amOnPage('/admin/config/system/local-footer'); $I->canSeeResponseCodeIs(200); @@ -225,7 +225,7 @@ protected function footestLockupSettingsO(AcceptanceTester $I) { /** * Test the lockup settings overrides. */ - protected function footestLockupSettingsP(AcceptanceTester $I) { + public function testLockupSettingsP(AcceptanceTester $I) { $I->logInWithRole('administrator'); $I->amOnPage('/admin/config/system/local-footer'); $I->canSeeResponseCodeIs(200); @@ -248,7 +248,7 @@ protected function footestLockupSettingsP(AcceptanceTester $I) { /** * Test the lockup settings overrides. */ - protected function footestLockupSettingsR(AcceptanceTester $I) { + public function testLockupSettingsR(AcceptanceTester $I) { $I->logInWithRole('administrator'); $I->amOnPage('/admin/config/system/local-footer'); $I->canSeeResponseCodeIs(200); @@ -270,7 +270,7 @@ protected function footestLockupSettingsR(AcceptanceTester $I) { /** * Test the lockup settings overrides. */ - protected function footestLockupSettingsS(AcceptanceTester $I) { + public function testLockupSettingsS(AcceptanceTester $I) { $I->logInWithRole('administrator'); $I->amOnPage('/admin/config/system/local-footer'); $I->canSeeResponseCodeIs(200); @@ -294,7 +294,7 @@ protected function footestLockupSettingsS(AcceptanceTester $I) { /** * Test the lockup settings overrides. */ - protected function footestLockupSettingsT(AcceptanceTester $I) { + public function testLockupSettingsT(AcceptanceTester $I) { $I->logInWithRole('administrator'); $I->amOnPage('/admin/config/system/local-footer'); $I->canSeeResponseCodeIs(200); @@ -319,7 +319,7 @@ protected function footestLockupSettingsT(AcceptanceTester $I) { /** * Test the logo image settings overrides. */ - protected function footestLogoWithLockup(AcceptanceTester $I) { + public function testLogoWithLockup(AcceptanceTester $I) { $I->logInWithRole('administrator'); $I->amOnPage('/admin/config/system/local-footer'); $I->canSeeResponseCodeIs(200); @@ -354,7 +354,7 @@ protected function footestLogoWithLockup(AcceptanceTester $I) { /** * Test for the logo without the lockup text. */ - protected function footestLogoWithOutLockup(AcceptanceTester $I) { + public function testLogoWithOutLockup(AcceptanceTester $I) { $I->logInWithRole('administrator'); $I->amOnPage('/admin/config/system/local-footer'); $I->canSeeResponseCodeIs(200); diff --git a/tests/codeception/acceptance/LockupSettings/LockupSettingsCest.php b/tests/codeception/acceptance/LockupSettings/LockupSettingsCest.php index 305aa3e82..4d6e839b6 100644 --- a/tests/codeception/acceptance/LockupSettings/LockupSettingsCest.php +++ b/tests/codeception/acceptance/LockupSettings/LockupSettingsCest.php @@ -40,7 +40,7 @@ public function _after(AcceptanceTester $I) { /** * Test the lockup exists. */ - protected function footestLockupSettings(AcceptanceTester $I) { + public function testLockupSettings(AcceptanceTester $I) { $I->amOnPage('/'); $I->seeElement('.su-lockup'); } @@ -48,7 +48,7 @@ protected function footestLockupSettings(AcceptanceTester $I) { /** * Test the lockup settings overrides. */ - protected function footestLockupSettingsA(AcceptanceTester $I) { + public function testLockupSettingsA(AcceptanceTester $I) { $I->logInWithRole('administrator'); $I->amOnPage('/admin/config/system/lockup-settings'); $I->canSeeResponseCodeIs(200); @@ -71,7 +71,7 @@ protected function footestLockupSettingsA(AcceptanceTester $I) { /** * Test the lockup settings overrides. */ - protected function footestLockupSettingsB(AcceptanceTester $I) { + public function testLockupSettingsB(AcceptanceTester $I) { $I->logInWithRole('administrator'); $I->amOnPage('/admin/config/system/lockup-settings'); $I->canSeeResponseCodeIs(200); @@ -94,7 +94,7 @@ protected function footestLockupSettingsB(AcceptanceTester $I) { /** * Test the lockup settings overrides. */ - protected function footestLockupSettingsD(AcceptanceTester $I) { + public function testLockupSettingsD(AcceptanceTester $I) { $I->logInWithRole('administrator'); $I->amOnPage('/admin/config/system/lockup-settings'); $I->canSeeResponseCodeIs(200); @@ -117,7 +117,7 @@ protected function footestLockupSettingsD(AcceptanceTester $I) { /** * Test the lockup settings overrides. */ - protected function footestLockupSettingsE(AcceptanceTester $I) { + public function testLockupSettingsE(AcceptanceTester $I) { $I->logInWithRole('administrator'); $I->amOnPage('/admin/config/system/lockup-settings'); $I->canSeeResponseCodeIs(200); @@ -141,7 +141,7 @@ protected function footestLockupSettingsE(AcceptanceTester $I) { /** * Test the lockup settings overrides. */ - protected function footestLockupSettingsH(AcceptanceTester $I) { + public function testLockupSettingsH(AcceptanceTester $I) { $I->logInWithRole('administrator'); $I->amOnPage('/admin/config/system/lockup-settings'); $I->canSeeResponseCodeIs(200); @@ -165,7 +165,7 @@ protected function footestLockupSettingsH(AcceptanceTester $I) { /** * Test the lockup settings overrides. */ - protected function footestLockupSettingsI(AcceptanceTester $I) { + public function testLockupSettingsI(AcceptanceTester $I) { $I->logInWithRole('administrator'); $I->amOnPage('/admin/config/system/lockup-settings'); $I->canSeeResponseCodeIs(200); @@ -189,7 +189,7 @@ protected function footestLockupSettingsI(AcceptanceTester $I) { /** * Test the lockup settings overrides. */ - protected function footestLockupSettingsM(AcceptanceTester $I) { + public function testLockupSettingsM(AcceptanceTester $I) { $I->logInWithRole('administrator'); $I->amOnPage('/admin/config/system/lockup-settings'); $I->canSeeResponseCodeIs(200); @@ -212,7 +212,7 @@ protected function footestLockupSettingsM(AcceptanceTester $I) { /** * Test the lockup settings overrides. */ - protected function footestLockupSettingsO(AcceptanceTester $I) { + public function testLockupSettingsO(AcceptanceTester $I) { $I->logInWithRole('administrator'); $I->amOnPage('/admin/config/system/lockup-settings'); $I->canSeeResponseCodeIs(200); @@ -234,7 +234,7 @@ protected function footestLockupSettingsO(AcceptanceTester $I) { /** * Test the lockup settings overrides. */ - protected function footestLockupSettingsP(AcceptanceTester $I) { + public function testLockupSettingsP(AcceptanceTester $I) { $I->logInWithRole('administrator'); $I->amOnPage('/admin/config/system/lockup-settings'); $I->canSeeResponseCodeIs(200); @@ -257,7 +257,7 @@ protected function footestLockupSettingsP(AcceptanceTester $I) { /** * Test the lockup settings overrides. */ - protected function footestLockupSettingsR(AcceptanceTester $I) { + public function testLockupSettingsR(AcceptanceTester $I) { $I->logInWithRole('administrator'); $I->amOnPage('/admin/config/system/lockup-settings'); $I->canSeeResponseCodeIs(200); @@ -279,7 +279,7 @@ protected function footestLockupSettingsR(AcceptanceTester $I) { /** * Test the lockup settings overrides. */ - protected function footestLockupSettingsS(AcceptanceTester $I) { + public function testLockupSettingsS(AcceptanceTester $I) { $I->logInWithRole('administrator'); $I->amOnPage('/admin/config/system/lockup-settings'); $I->canSeeResponseCodeIs(200); @@ -303,7 +303,7 @@ protected function footestLockupSettingsS(AcceptanceTester $I) { /** * Test the lockup settings overrides. */ - protected function footestLockupSettingsT(AcceptanceTester $I) { + public function testLockupSettingsT(AcceptanceTester $I) { $I->logInWithRole('administrator'); $I->amOnPage('/admin/config/system/lockup-settings'); $I->canSeeResponseCodeIs(200); @@ -328,7 +328,7 @@ protected function footestLockupSettingsT(AcceptanceTester $I) { /** * Test the logo image settings overrides. */ - protected function footestLogoWithLockup(AcceptanceTester $I) { + public function testLogoWithLockup(AcceptanceTester $I) { $I->logInWithRole('administrator'); $I->amOnPage('/admin/config/system/lockup-settings'); $I->canSeeResponseCodeIs(200); @@ -363,7 +363,7 @@ protected function footestLogoWithLockup(AcceptanceTester $I) { /** * Test for the logo without the lockup text. */ - protected function footestLogoWithOutLockup(AcceptanceTester $I) { + public function testLogoWithOutLockup(AcceptanceTester $I) { $I->logInWithRole('administrator'); $I->amOnPage('/admin/config/system/lockup-settings'); $I->canSeeResponseCodeIs(200); diff --git a/tests/codeception/acceptance/LockupSettings/LockupSettingsPermsCest.php b/tests/codeception/acceptance/LockupSettings/LockupSettingsPermsCest.php index 6fc84c164..4dd179aaa 100644 --- a/tests/codeception/acceptance/LockupSettings/LockupSettingsPermsCest.php +++ b/tests/codeception/acceptance/LockupSettings/LockupSettingsPermsCest.php @@ -8,7 +8,7 @@ class LockupSettingsPermsCest { /** * Test access to lockup settings overrides. */ - protected function footestSiteManagerRole(AcceptanceTester $I) { + public function testSiteManagerRole(AcceptanceTester $I) { $I->logInWithRole('site_manager'); $I->amOnPage('/admin/config/system/lockup-settings'); $I->canSee('Edit config page Lockup Settings'); @@ -18,7 +18,7 @@ protected function footestSiteManagerRole(AcceptanceTester $I) { /** * Test access to lockup settings overrides. */ - protected function footestContributorRole(AcceptanceTester $I) { + public function testContributorRole(AcceptanceTester $I) { $I->logInWithRole('contributor'); $I->amOnPage('/admin/config/system/lockup-settings'); $I->canSeeResponseCodeIs(403); @@ -27,7 +27,7 @@ protected function footestContributorRole(AcceptanceTester $I) { /** * Test access to lockup settings overrides. */ - protected function footestSiteEditorRole(AcceptanceTester $I) { + public function testSiteEditorRole(AcceptanceTester $I) { $I->logInWithRole('site_editor'); $I->amOnPage('/admin/config/system/lockup-settings'); $I->canSeeResponseCodeIs(403); diff --git a/tests/codeception/acceptance/Media/MediaCest.php b/tests/codeception/acceptance/Media/MediaCest.php index e1cc1a16f..e966fe5bd 100644 --- a/tests/codeception/acceptance/Media/MediaCest.php +++ b/tests/codeception/acceptance/Media/MediaCest.php @@ -28,7 +28,7 @@ public function __construct() { /** * Documents can be embedded as links. */ - protected function footestFileLinks(AcceptanceTester $I) { + public function testFileLinks(AcceptanceTester $I) { $I->logInWithRole('administrator'); $I->amOnPage('/admin/config/content/linkit/manage/default/matchers'); $I->canSee('Metadata: [media:field_media_file:entity:basename]: [media:field_media_file:entity:mime]'); @@ -37,7 +37,7 @@ protected function footestFileLinks(AcceptanceTester $I) { /** * Media Types Exist. */ - protected function footestForMediaTypes(AcceptanceTester $I) { + public function testForMediaTypes(AcceptanceTester $I) { $I->logInWithRole('administrator'); $I->amOnPage('/admin/structure/media'); $I->canSee('Embeddable'); @@ -50,7 +50,7 @@ protected function footestForMediaTypes(AcceptanceTester $I) { /** * Embedded media should not have a tag. */ - protected function footestSourceTag(AcceptanceTester $I) { + public function testSourceTag(AcceptanceTester $I) { /** @var \Drupal\Core\File\FileSystemInterface $file_system */ $file_system = \Drupal::service('file_system'); $image_path = $file_system->copy(__DIR__ . '/../assets/logo.jpg', 'public://' . $this->faker->word . '.jpg'); @@ -89,7 +89,7 @@ protected function footestSourceTag(AcceptanceTester $I) { /** * Embeddable types enabled. */ - protected function footestForEmbeddableOptions(AcceptanceTester $I) { + public function testForEmbeddableOptions(AcceptanceTester $I) { $I->logInWithRole('administrator'); $I->amOnPage('/admin/structure/media/manage/embeddable'); $I->canSeeCheckboxIsChecked('ArcGIS StoryMaps'); @@ -115,7 +115,7 @@ protected function footestForEmbeddableOptions(AcceptanceTester $I) { /** * Embeddable fields set right. */ - protected function footestForEmbeddableFields(AcceptanceTester $I) { + public function testForEmbeddableFields(AcceptanceTester $I) { $I->logInWithRole('administrator'); $I->amOnPage('/admin/structure/media/manage/embeddable'); $I->seeOptionIsSelected('Field for unstructured embed codes', 'media.field_media_embeddable_code'); @@ -124,7 +124,7 @@ protected function footestForEmbeddableFields(AcceptanceTester $I) { /** * Embeddable form fields. */ - protected function footestForEmbeddableFormFields(AcceptanceTester $I) { + public function testForEmbeddableFormFields(AcceptanceTester $I) { $I->logInWithRole('administrator'); $I->amOnPage('/media/add/embeddable'); $I->canSee('Name'); @@ -154,7 +154,7 @@ protected function footestForEmbeddableFormFields(AcceptanceTester $I) { * * @group embed-codes */ - protected function footestAllowedEmbedCodes(AcceptanceTester $I) { + public function testAllowedEmbedCodes(AcceptanceTester $I) { $I->logInWithRole('site_manager'); $I->amOnPage('/media/add/embeddable'); $I->fillField('Name', $this->faker->words(3, TRUE)); @@ -186,7 +186,7 @@ protected function footestAllowedEmbedCodes(AcceptanceTester $I) { /** * Google Form additional field */ - protected function footestForGoogleFormFields(AcceptanceTester $I) { + public function testForGoogleFormFields(AcceptanceTester $I) { $I->logInWithRole('site_manager'); $I->amOnPage('/media/add/google_form'); $I->canSee('Form Height'); @@ -195,7 +195,7 @@ protected function footestForGoogleFormFields(AcceptanceTester $I) { /** * Administrative file listing can delete files. */ - protected function footestDeleteFiles(AcceptanceTester $I) { + public function testDeleteFiles(AcceptanceTester $I) { $I->logInWithRole('site_manager'); $I->amOnPage('/admin/content/files'); $I->canSeeResponseCodeIs(403); @@ -256,7 +256,7 @@ protected function footestDeleteFiles(AcceptanceTester $I) { /** * SUL Embeddables can be saved. */ - protected function footestArcGis(AcceptanceTester $I) { + public function testArcGis(AcceptanceTester $I) { $I->logInWithRole('administrator'); $I->amOnPage('/media/add/embeddable'); $name = $this->faker->words(2, TRUE); @@ -269,7 +269,7 @@ protected function footestArcGis(AcceptanceTester $I) { /** * Test media category taxonomy field. */ - protected function footestCategoryField(AcceptanceTester $I) { + public function testCategoryField(AcceptanceTester $I) { /** @var \Drupal\Core\File\FileSystemInterface $file_system */ $file_system = \Drupal::service('file_system'); $image_path = $file_system->copy(__DIR__ . '/../assets/logo.jpg', 'public://' . $this->faker->word . '.jpg'); diff --git a/tests/codeception/acceptance/Media/MediaFormsCest.php b/tests/codeception/acceptance/Media/MediaFormsCest.php index 74456b9c1..c28d83a3b 100644 --- a/tests/codeception/acceptance/Media/MediaFormsCest.php +++ b/tests/codeception/acceptance/Media/MediaFormsCest.php @@ -22,7 +22,7 @@ public function __construct() { /** * Test embeddables form alters */ - protected function footestFormAlters(AcceptanceTester $I) { + public function testFormAlters(AcceptanceTester $I) { $support_url = 'https://stanford.service-now.com/it_services?id=sc_cat_item&sys_id=83daed294f4143009a9a97411310c70a'; $I->logInWithRole('site_manager'); $I->amOnPage('/media/add/embeddable'); diff --git a/tests/codeception/acceptance/Media/MediaPermissionsCest.php b/tests/codeception/acceptance/Media/MediaPermissionsCest.php index 3c192c69f..79ef6ae4e 100644 --- a/tests/codeception/acceptance/Media/MediaPermissionsCest.php +++ b/tests/codeception/acceptance/Media/MediaPermissionsCest.php @@ -22,7 +22,7 @@ public function __construct() { /** * Test admin perms */ - protected function footestAdminPerms(AcceptanceTester $I) { + public function testAdminPerms(AcceptanceTester $I) { $I->logInWithRole('administrator'); $I->amOnPage('/media/add/embeddable'); $I->canSeeResponseCodeIs(200); @@ -33,7 +33,7 @@ protected function footestAdminPerms(AcceptanceTester $I) { /** * Test site embedder perms */ - protected function footestSiteEmbedderPerms(AcceptanceTester $I) { + public function testSiteEmbedderPerms(AcceptanceTester $I) { $user = $I->createUserWithRoles(['su_site_embedder', 'site_manager']); $I->logInAs($user->getAccountName()); $I->amOnPage('/media/add/embeddable'); @@ -45,7 +45,7 @@ protected function footestSiteEmbedderPerms(AcceptanceTester $I) { /** * Test site manager perms */ - protected function footestSiteManagerPerms(AcceptanceTester $I) { + public function testSiteManagerPerms(AcceptanceTester $I) { $I->logInWithRole('site_manager'); $I->amOnPage('/media/add/embeddable'); $I->canSeeResponseCodeIs(200); @@ -68,7 +68,7 @@ protected function footestSiteManagerPerms(AcceptanceTester $I) { /** * Test site editor perms */ - protected function footestSiteEditorPerms(AcceptanceTester $I) { + public function testSiteEditorPerms(AcceptanceTester $I) { $I->logInWithRole('site_editor'); $I->amOnPage('/media/add/embeddable'); $I->canSeeResponseCodeIs(200); @@ -84,7 +84,7 @@ protected function footestSiteEditorPerms(AcceptanceTester $I) { /** * Test contributor perms */ - protected function footestContributorPerms(AcceptanceTester $I) { + public function testContributorPerms(AcceptanceTester $I) { $I->logInWithRole('contributor'); $I->amOnPage('/media/add/embeddable'); $I->canSeeResponseCodeIs(200); diff --git a/tests/codeception/acceptance/Paragraphs/Issue2901390Cest.php b/tests/codeception/acceptance/Paragraphs/Issue2901390Cest.php index 2b378fa7c..f2f2d401c 100644 --- a/tests/codeception/acceptance/Paragraphs/Issue2901390Cest.php +++ b/tests/codeception/acceptance/Paragraphs/Issue2901390Cest.php @@ -27,7 +27,7 @@ public function __construct() { /** * A user should be able to create a custom block in layout builder. */ - protected function footestLayoutBuilderParagraph(AcceptanceTester $I) { + public function testLayoutBuilderParagraph(AcceptanceTester $I) { $user = $I->createUserWithRoles(['site_manager', 'layout_builder_user']); $I->logInAs($user->id()); $node = $I->createEntity([ diff --git a/tests/codeception/acceptance/Paragraphs/ListsCest.php b/tests/codeception/acceptance/Paragraphs/ListsCest.php index 724cabdbe..ea55564c8 100644 --- a/tests/codeception/acceptance/Paragraphs/ListsCest.php +++ b/tests/codeception/acceptance/Paragraphs/ListsCest.php @@ -29,7 +29,7 @@ public function __construct() { * * @group jsonapi */ - protected function footestSharedTags(AcceptanceTester $I) { + public function testSharedTags(AcceptanceTester $I) { $shared_tag = $I->createEntity([ 'name' => $this->faker->jobTitle, 'vid' => 'su_shared_tags', @@ -135,7 +135,7 @@ protected function footestSharedTags(AcceptanceTester $I) { * * @group jsonapi */ - protected function footestListParagraphNews(AcceptanceTester $I) { + public function testListParagraphNews(AcceptanceTester $I) { $I->logInWithRole('contributor'); $I->amOnPage('/node/add/stanford_news'); $title = $this->faker->words(3, TRUE); @@ -170,7 +170,7 @@ protected function footestListParagraphNews(AcceptanceTester $I) { * * @group jsonapi */ - protected function footestListParagraphNewsFiltersNoFilter(AcceptanceTester $I) { + public function testListParagraphNewsFiltersNoFilter(AcceptanceTester $I) { $I->logInWithRole('contributor'); $topic_term = $this->createTaxonomyTerm($I, 'stanford_news_topics'); @@ -198,7 +198,7 @@ protected function footestListParagraphNewsFiltersNoFilter(AcceptanceTester $I) /** * When using the list paragraph and view arguments, it should filter results. */ - protected function footestListParagraphNewsFiltersRandomFilter(AcceptanceTester $I) { + public function testListParagraphNewsFiltersRandomFilter(AcceptanceTester $I) { $I->logInWithRole('contributor'); $random_term = $this->createTaxonomyTerm($I, 'stanford_news_topics'); @@ -228,7 +228,7 @@ protected function footestListParagraphNewsFiltersRandomFilter(AcceptanceTester /** * When using the list paragraph and view arguments, it should filter results. */ - protected function footestListParagraphNewsFiltersTopicFilter(AcceptanceTester $I) { + public function testListParagraphNewsFiltersTopicFilter(AcceptanceTester $I) { $I->logInWithRole('contributor'); $topic_term = $this->createTaxonomyTerm($I, 'stanford_news_topics'); @@ -262,7 +262,7 @@ protected function footestListParagraphNewsFiltersTopicFilter(AcceptanceTester $ * * @group D8CORE-4858 */ - protected function footestEmptyResultsListEvents(AcceptanceTester $I) { + public function testEmptyResultsListEvents(AcceptanceTester $I) { // Start with no events. $nodes = \Drupal::entityTypeManager() ->getStorage('node') @@ -374,7 +374,7 @@ protected function footestEmptyResultsListEvents(AcceptanceTester $I) { * * @group jsonapi */ - protected function footestListParagraphEvents(AcceptanceTester $I) { + public function testListParagraphEvents(AcceptanceTester $I) { $I->logInWithRole('contributor'); $type = $I->createEntity([ @@ -498,7 +498,7 @@ protected function footestListParagraphEvents(AcceptanceTester $I) { /** * When using the list paragraph and view arguments, it should filter results. */ - protected function footestListParagraphEventFiltersNoFilter(AcceptanceTester $I) { + public function testListParagraphEventFiltersNoFilter(AcceptanceTester $I) { $I->logInWithRole('site_manager'); $event_type = $this->createTaxonomyTerm($I, 'stanford_event_types'); @@ -531,7 +531,7 @@ protected function footestListParagraphEventFiltersNoFilter(AcceptanceTester $I) /** * When using the list paragraph and view arguments, it should filter results. */ - protected function footestListParagraphEventFiltersRandomFilter(AcceptanceTester $I) { + public function testListParagraphEventFiltersRandomFilter(AcceptanceTester $I) { $I->logInWithRole('site_manager'); $random_term = $this->createTaxonomyTerm($I, 'stanford_event_types'); @@ -566,7 +566,7 @@ protected function footestListParagraphEventFiltersRandomFilter(AcceptanceTester /** * When using the list paragraph and view arguments, it should filter results. */ - protected function footestListParagraphEventFiltersTypeFilter(AcceptanceTester $I) { + public function testListParagraphEventFiltersTypeFilter(AcceptanceTester $I) { $I->logInWithRole('site_manager'); $event_type = $this->createTaxonomyTerm($I, 'stanford_event_types'); @@ -603,7 +603,7 @@ protected function footestListParagraphEventFiltersTypeFilter(AcceptanceTester $ /** * When using the list paragraph and view arguments, it should filter results. */ - protected function footestListParagraphEventFiltersAudienceFilter(AcceptanceTester $I) { + public function testListParagraphEventFiltersAudienceFilter(AcceptanceTester $I) { $I->logInWithRole('site_manager'); $event_type = $this->createTaxonomyTerm($I, 'stanford_event_types'); @@ -640,7 +640,7 @@ protected function footestListParagraphEventFiltersAudienceFilter(AcceptanceTest /** * People items should display in the list paragraph. */ - protected function footestListParagraphPeople(AcceptanceTester $I) { + public function testListParagraphPeople(AcceptanceTester $I) { $I->logInWithRole('contributor'); $I->amOnPage('/node/add/stanford_person'); $I->fillField('First Name', 'Foo'); @@ -664,7 +664,7 @@ protected function footestListParagraphPeople(AcceptanceTester $I) { /** * When using the list paragraph and view arguments, it should filter results. */ - protected function footestListParagraphPeopleFilters(AcceptanceTester $I) { + public function testListParagraphPeopleFilters(AcceptanceTester $I) { $I->logInWithRole('site_manager'); $type_term = $this->createTaxonomyTerm($I, 'stanford_person_types'); @@ -692,7 +692,7 @@ protected function footestListParagraphPeopleFilters(AcceptanceTester $I) { /** * When using the list paragraph and view arguments, it should filter results. */ - protected function footestListParagraphPeopleFiltersRandomFilter(AcceptanceTester $I) { + public function testListParagraphPeopleFiltersRandomFilter(AcceptanceTester $I) { $I->logInWithRole('site_manager'); $random_term = $this->createTaxonomyTerm($I, 'stanford_person_types'); @@ -722,7 +722,7 @@ protected function footestListParagraphPeopleFiltersRandomFilter(AcceptanceTeste /** * When using the list paragraph and view arguments, it should filter results. */ - protected function footestListParagraphPeopleFiltersTypeFilter(AcceptanceTester $I) { + public function testListParagraphPeopleFiltersTypeFilter(AcceptanceTester $I) { $I->logInWithRole('site_manager'); $type_term = $this->createTaxonomyTerm($I, 'stanford_person_types'); @@ -754,7 +754,7 @@ protected function footestListParagraphPeopleFiltersTypeFilter(AcceptanceTester /** * Test basic page types list view. */ - protected function footestListParagraphBasicPageTypesFilter(AcceptanceTester $I) { + public function testListParagraphBasicPageTypesFilter(AcceptanceTester $I) { $I->logInWithRole('site_manager'); $type_term = $this->createTaxonomyTerm($I, 'basic_page_types', 'Basic Page Test Term'); diff --git a/tests/codeception/acceptance/Paragraphs/MediaWithCaptionCest.php b/tests/codeception/acceptance/Paragraphs/MediaWithCaptionCest.php index dd48f621f..1d622823a 100644 --- a/tests/codeception/acceptance/Paragraphs/MediaWithCaptionCest.php +++ b/tests/codeception/acceptance/Paragraphs/MediaWithCaptionCest.php @@ -27,7 +27,7 @@ public function __construct() { /** * A media with caption paragraph will display its fields. */ - protected function footestMediaParagraph(AcceptanceTester $I) { + public function testMediaParagraph(AcceptanceTester $I) { $paragraph = $I->createEntity([ 'type' => 'stanford_media_caption', 'su_media_caption_caption' => 'This is a super caption', diff --git a/tests/codeception/acceptance/Paragraphs/StanfordCardCest.php b/tests/codeception/acceptance/Paragraphs/StanfordCardCest.php index 95202bd3b..78b90007a 100644 --- a/tests/codeception/acceptance/Paragraphs/StanfordCardCest.php +++ b/tests/codeception/acceptance/Paragraphs/StanfordCardCest.php @@ -24,7 +24,7 @@ public function __construct() { /** * Test a card with a button link. */ - protected function footestCardButtonLinkText(\AcceptanceTester $I) { + public function testCardButtonLinkText(\AcceptanceTester $I) { $node = $this->createNodeWithLink($I); $I->amOnPage($node->toUrl()->toString()); $I->canSeeLink('It\'s a "test" link & title', 'http://google.com'); @@ -33,7 +33,7 @@ protected function footestCardButtonLinkText(\AcceptanceTester $I) { /** * Test a card with an action link. */ - protected function footestCardActionLinkText(\AcceptanceTester $I) { + public function testCardActionLinkText(\AcceptanceTester $I) { $node = $this->createNodeWithLink($I, 'action'); $I->amOnPage($node->toUrl()->toString()); $I->canSeeLink('It\'s a "test" link & title', 'http://google.com'); diff --git a/tests/codeception/acceptance/SubThemeCest.php b/tests/codeception/acceptance/SubThemeCest.php index 704bc6348..c18abc20f 100644 --- a/tests/codeception/acceptance/SubThemeCest.php +++ b/tests/codeception/acceptance/SubThemeCest.php @@ -63,7 +63,7 @@ public function _after(AcceptanceTester $I) { * * @group minimal-subtheme-test2 */ - protected function footestSubTheme(AcceptanceTester $I) { + public function testSubTheme(AcceptanceTester $I) { $I->runDrush('theme:enable -y ' . strtolower($this->themeName)); $I->logInWithRole('administrator'); $I->amOnPage('/admin/appearance'); @@ -94,7 +94,7 @@ protected function footestSubTheme(AcceptanceTester $I) { * * @group minimal-subtheme-test */ - protected function footestMinimalSubtheme(AcceptanceTester $I) { + public function testMinimalSubtheme(AcceptanceTester $I) { $I->logInWithRole('administrator'); $I->amOnPage('/admin/appearance'); $I->click('Set as default', 'a[title="Set Stanford Minimally Branded Subtheme as default theme"]'); diff --git a/tests/codeception/acceptance/SuperFooter/SuperFooterCest.php b/tests/codeception/acceptance/SuperFooter/SuperFooterCest.php index 186c0f5fe..2fe60f607 100644 --- a/tests/codeception/acceptance/SuperFooter/SuperFooterCest.php +++ b/tests/codeception/acceptance/SuperFooter/SuperFooterCest.php @@ -17,7 +17,7 @@ public function _after(AcceptanceTester $I) { /** * Test the block exists. */ - protected function footestBlockExists(AcceptanceTester $I) { + public function testBlockExists(AcceptanceTester $I) { $I->logInWithRole('administrator'); $I->amOnPage('/admin/structure/block'); $I->canSee('Super Footer'); @@ -26,7 +26,7 @@ protected function footestBlockExists(AcceptanceTester $I) { /** * Test the Form exists. */ - protected function footestFormExists(AcceptanceTester $I) { + public function testFormExists(AcceptanceTester $I) { $I->logInWithRole('administrator'); $I->amOnPage('/admin/config/system/super-footer'); $I->canSee('Edit config page Super Footer'); @@ -35,7 +35,7 @@ protected function footestFormExists(AcceptanceTester $I) { /** * Test the Form Settings. */ - protected function footestFormSettings(AcceptanceTester $I) { + public function testFormSettings(AcceptanceTester $I) { $I->logInWithRole('administrator'); $I->amOnPage('/admin/config/system/super-footer'); $I->checkOption('#edit-su-super-foot-enabled-value'); @@ -60,7 +60,7 @@ protected function footestFormSettings(AcceptanceTester $I) { /** * Test user role permissions. */ - protected function footestAdminUserRole(AcceptanceTester $I) { + public function testAdminUserRole(AcceptanceTester $I) { // Admin. $I->logInWithRole('administrator'); $I->amOnPage('/admin/config/system/super-footer'); @@ -71,7 +71,7 @@ protected function footestAdminUserRole(AcceptanceTester $I) { /** * Test user role permissions. */ - protected function footestSiteManagerUserRole(AcceptanceTester $I) { + public function testSiteManagerUserRole(AcceptanceTester $I) { // Site Manager. $I->logInWithRole('site_manager'); $I->amOnPage('/admin/config/system/super-footer'); @@ -82,7 +82,7 @@ protected function footestSiteManagerUserRole(AcceptanceTester $I) { /** * Test user role permissions. */ - protected function footestSiteEditorUserRole(AcceptanceTester $I) { + public function testSiteEditorUserRole(AcceptanceTester $I) { // Editor. $I->logInWithRole('site_editor'); $I->amOnPage('/admin/config/system/super-footer'); @@ -93,7 +93,7 @@ protected function footestSiteEditorUserRole(AcceptanceTester $I) { /** * Test user role permissions. */ - protected function footestContributorUserRole(AcceptanceTester $I) { + public function testContributorUserRole(AcceptanceTester $I) { // Contributor. $I->logInWithRole('contributor'); $I->amOnPage('/admin/config/system/super-footer'); diff --git a/tests/codeception/acceptance/SystemCest.php b/tests/codeception/acceptance/SystemCest.php index aa6872bb0..7a37cb576 100644 --- a/tests/codeception/acceptance/SystemCest.php +++ b/tests/codeception/acceptance/SystemCest.php @@ -10,7 +10,8 @@ class SystemCest { /** * Test the site status report. */ - protected function footestSiteStatus(AcceptanceTester $I) { + public function testSiteStatus(AcceptanceTester $I) { + $I->runDrush('xmlsitemap:rebuild'); $I->logInWithRole('administrator'); $I->amOnPage('/admin/reports/status'); $I->canSee('10.1', '.system-status-general-info'); diff --git a/tests/codeception/acceptance/SystemSiteConfigCest.php b/tests/codeception/acceptance/SystemSiteConfigCest.php index efe61f35e..5d729ce22 100644 --- a/tests/codeception/acceptance/SystemSiteConfigCest.php +++ b/tests/codeception/acceptance/SystemSiteConfigCest.php @@ -36,7 +36,7 @@ public function __after(AcceptanceTester $I) { /** * The site manager should be able to change the site name. */ - protected function footestBasicSiteSettings(AcceptanceTester $I) { + public function testBasicSiteSettings(AcceptanceTester $I) { $org_term = $I->createEntity([ 'vid' => 'site_owner_orgs', 'name' => $this->faker->words(2, TRUE), @@ -71,7 +71,7 @@ protected function footestBasicSiteSettings(AcceptanceTester $I) { /** * Site settings config should change the home, 404, and 403 pages. */ - protected function footestSitePages(AcceptanceTester $I) { + public function testSitePages(AcceptanceTester $I) { $org_term = $I->createEntity([ 'vid' => 'site_owner_orgs', 'name' => $this->faker->words(2, TRUE), diff --git a/tests/codeception/acceptance/TextFormatsCest.php b/tests/codeception/acceptance/TextFormatsCest.php index 03fe8875a..464ad3e2f 100644 --- a/tests/codeception/acceptance/TextFormatsCest.php +++ b/tests/codeception/acceptance/TextFormatsCest.php @@ -10,7 +10,7 @@ class TextFormatsCest { /** * Basic HTML should have certain configs set. */ - protected function footestBasicHtml(AcceptanceTester $I) { + public function testBasicHtml(AcceptanceTester $I) { $I->logInWithRole('administrator'); $I->amOnPage('/admin/config/content/formats/manage/stanford_html'); $I->canSeeCheckboxIsChecked('Large (480px wide, un-cropped)'); diff --git a/tests/codeception/acceptance/Users/DefaultUsersCest.php b/tests/codeception/acceptance/Users/DefaultUsersCest.php index f94890f9b..9ea8f0d5c 100644 --- a/tests/codeception/acceptance/Users/DefaultUsersCest.php +++ b/tests/codeception/acceptance/Users/DefaultUsersCest.php @@ -10,7 +10,7 @@ class DefaultUsersCest { /** * Default users should be created. */ - protected function footestDefaultUsers(AcceptanceTester $I) { + public function testDefaultUsers(AcceptanceTester $I) { $I->logInWithRole('administrator'); $I->amOnPage('/admin/users'); $I->canSee('Alex'); diff --git a/tests/codeception/acceptance/Users/IntranetCest.php b/tests/codeception/acceptance/Users/IntranetCest.php index c0b7ca014..44a452263 100644 --- a/tests/codeception/acceptance/Users/IntranetCest.php +++ b/tests/codeception/acceptance/Users/IntranetCest.php @@ -46,7 +46,7 @@ public function _after(AcceptanceTester $I) { /** * Simple full site access check. */ - protected function footestIntranet(AcceptanceTester $I) { + public function testIntranet(AcceptanceTester $I) { if (!$this->intranetWasEnabled) { $I->runDrush('sset stanford_intranet 1'); $I->runDrush('cache-rebuild'); @@ -67,7 +67,7 @@ protected function footestIntranet(AcceptanceTester $I) { /** * Test the access of content. */ - protected function footestAccess(AcceptanceTester $I) { + public function testAccess(AcceptanceTester $I) { // Contributors can't set access restrictions. $I->runDrush('sset stanford_intranet 0'); $I->logInWithRole('contributor'); @@ -115,7 +115,7 @@ protected function footestAccess(AcceptanceTester $I) { /** * Content should be indexed and results displayed. */ - protected function footestSearchResults(AcceptanceTester $I) { + public function testSearchResults(AcceptanceTester $I) { $I->runDrush('sset stanford_intranet 1'); $I->runDrush('sapi-c'); $quote = 'Life is like a box of chocolates. You never know what you’re going to get.'; @@ -147,7 +147,7 @@ protected function footestSearchResults(AcceptanceTester $I) { /** * Files can only be added when allow_file_uploads state is enabled. */ - protected function footestMediaAccess(AcceptanceTester $I) { + public function testMediaAccess(AcceptanceTester $I) { $I->runDrush('sset stanford_intranet 1'); $I->runDrush('sset stanford_intranet.allow_file_uploads 1'); diff --git a/tests/codeception/acceptance/Users/RolesCest.php b/tests/codeception/acceptance/Users/RolesCest.php index cf3b76675..abb39307e 100644 --- a/tests/codeception/acceptance/Users/RolesCest.php +++ b/tests/codeception/acceptance/Users/RolesCest.php @@ -10,7 +10,7 @@ class RolesCest { /** * Default roles should exist. */ - protected function footestRolesExist(AcceptanceTester $I) { + public function testRolesExist(AcceptanceTester $I) { $I->logInWithRole('administrator'); $I->amOnPage('/admin/users/roles'); $I->canSee('Contributor'); @@ -25,7 +25,7 @@ protected function footestRolesExist(AcceptanceTester $I) { /** * Stanford Staff role should be very limited. */ - protected function footestStaffRole(AcceptanceTester $I) { + public function testStaffRole(AcceptanceTester $I) { $I->logInWithRole('stanford_staff'); // D8CORE-2538 Staff and students without additional roles shouldn't see // the admin toolbar. @@ -36,7 +36,7 @@ protected function footestStaffRole(AcceptanceTester $I) { /** * Stanford Staff role should be very limited. */ - protected function footestStudentRole(AcceptanceTester $I) { + public function testStudentRole(AcceptanceTester $I) { $I->logInWithRole('stanford_student'); // D8CORE-2538 Staff and students without additional roles shouldn't see // the admin toolbar. @@ -47,7 +47,7 @@ protected function footestStudentRole(AcceptanceTester $I) { /** * Stanford Staff role should be very limited. */ - protected function footestFacultyRole(AcceptanceTester $I) { + public function testFacultyRole(AcceptanceTester $I) { $I->logInWithRole('stanford_faculty'); // D8CORE-2538 Staff and students without additional roles shouldn't see // the admin toolbar. @@ -58,7 +58,7 @@ protected function footestFacultyRole(AcceptanceTester $I) { /** * Contributor role should have some access. */ - protected function footestContributorRole(AcceptanceTester $I) { + public function testContributorRole(AcceptanceTester $I) { $I->logInWithRole('contributor'); $I->amOnPage('/node/add/stanford_page'); @@ -91,7 +91,7 @@ protected function footestContributorRole(AcceptanceTester $I) { /** * Site editor role should have some access. */ - protected function footestSiteEditorRole(AcceptanceTester $I) { + public function testSiteEditorRole(AcceptanceTester $I) { $I->logInWithRole('site_editor'); $I->amOnPage('/node/add/stanford_page'); @@ -124,7 +124,7 @@ protected function footestSiteEditorRole(AcceptanceTester $I) { /** * Site manager should have more access. */ - protected function footestSiteManagerRole(AcceptanceTester $I) { + public function testSiteManagerRole(AcceptanceTester $I) { $I->logInWithRole('site_manager'); $I->amOnPage('/node/add/stanford_page'); @@ -158,7 +158,7 @@ protected function footestSiteManagerRole(AcceptanceTester $I) { /** * Site builder will get more access than site manager. */ - protected function footestSiteBuilderRole(AcceptanceTester $I) { + public function testSiteBuilderRole(AcceptanceTester $I) { $I->logInWithRole('site_builder'); $I->amOnPage('/node/add/stanford_page'); @@ -179,7 +179,7 @@ protected function footestSiteBuilderRole(AcceptanceTester $I) { /** * Developers have the most access. */ - protected function footestSiteDeveloperRole(AcceptanceTester $I) { + public function testSiteDeveloperRole(AcceptanceTester $I) { $I->logInWithRole('site_developer'); $I->amOnPage('/node/add/stanford_page');