Mercurial > hg > cmmr2012-drupal-site
comparison core/modules/system/tests/src/Traits/TestTrait.php @ 5:12f9dff5fda9 tip
Update to Drupal core 8.7.1
author | Chris Cannam |
---|---|
date | Thu, 09 May 2019 15:34:47 +0100 |
parents | |
children |
comparison
equal
deleted
inserted
replaced
4:a9cd425dd02b | 5:12f9dff5fda9 |
---|---|
1 <?php | |
2 | |
3 namespace Drupal\Tests\system\Traits; | |
4 | |
5 /** | |
6 * A nothing trait, but declared in the Drupal\Tests namespace. | |
7 * | |
8 * We use this trait to test autoloading of traits outside of the normal test | |
9 * suite namespaces. | |
10 * | |
11 * @see \Drupal\Tests\system\Unit\TraitAccessTest | |
12 */ | |
13 trait TestTrait { | |
14 | |
15 /** | |
16 * Random string for a not very interesting trait. | |
17 * | |
18 * @var string | |
19 */ | |
20 protected $stuff = 'stuff'; | |
21 | |
22 /** | |
23 * Return a test string to a trait user. | |
24 * | |
25 * @return string | |
26 * Just a random sort of string. | |
27 */ | |
28 protected function getStuff() { | |
29 return $this->stuff; | |
30 } | |
31 | |
32 } |