You are here

protected function HelpTopicTest::getTopicList in Drupal 9

Same name and namespace in other branches
  1. 8 core/modules/help_topics/tests/src/Functional/HelpTopicTest.php \Drupal\Tests\help_topics\Functional\HelpTopicTest::getTopicList()

Gets a list of topic IDs to test.

Return value

array A list of topics to test, in the order in which they should appear. The keys are the machine names of the topics. The values are arrays with the following elements:

  • name: Displayed name.
  • tags: Cache tags to test for.
2 calls to HelpTopicTest::getTopicList()
HelpTopicTest::testHelp in core/modules/help_topics/tests/src/Functional/HelpTopicTest.php
Tests the main help page and individual pages for topics.
HelpTopicTest::verifyHelp in core/modules/help_topics/tests/src/Functional/HelpTopicTest.php
Verifies the logged in user has access to various help links and pages.

File

core/modules/help_topics/tests/src/Functional/HelpTopicTest.php, line 256

Class

HelpTopicTest
Verifies help topic display and user access to help based on permissions.

Namespace

Drupal\Tests\help_topics\Functional

Code

protected function getTopicList() {
  return [
    'help_topics_test.test' => [
      'name' => 'ABC Help Test module',
      'tags' => [
        'core.extension',
      ],
    ],
    'help_topics_derivatives:test_derived_topic' => [
      'name' => 'Label for test_derived_topic',
      'tags' => [
        'foobar',
      ],
    ],
    'help_topics_test_direct_yml' => [
      'name' => 'Test direct yaml topic label',
      'tags' => [
        'foobar',
      ],
    ],
  ];
}