185a3fe5167439dde78c45c52bdbcd3fba06e7a9
[yaffs-website] / web / core / tests / Drupal / KernelTests / Core / Updater / UpdaterTest.php
1 <?php
2
3 namespace Drupal\KernelTests\Core\Updater;
4
5 use Drupal\Core\Updater\Updater;
6 use Drupal\KernelTests\KernelTestBase;
7
8 /**
9  * Tests InfoParser class and exception.
10  *
11  * Files for this test are stored in core/modules/system/tests/fixtures and end
12  * with .info.txt instead of info.yml in order not not be considered as real
13  * extensions.
14  *
15  * @group Extension
16  */
17 class UpdaterTest extends KernelTestBase {
18
19   /**
20    * Tests project and child project showing correct title.
21    *
22    * @see https://drupal.org/node/2409515
23    */
24   public function testGetProjectTitleWithChild() {
25     // Get the project title from it's directory. If it can't find the title
26     // it will choose the first project title in the directory.
27     $directory = \Drupal::root() . '/core/modules/system/tests/modules/module_handler_test_multiple';
28     $title = Updater::getProjectTitle($directory);
29     $this->assertEqual('module handler test multiple', $title);
30   }
31
32 }