diff --git a/core/lib/Drupal/Core/Datetime/DateHelper.php b/core/lib/Drupal/Core/Datetime/DateHelper.php index 0b0490674469..9c5b5f4956b1 100644 --- a/core/lib/Drupal/Core/Datetime/DateHelper.php +++ b/core/lib/Drupal/Core/Datetime/DateHelper.php @@ -2,6 +2,12 @@ /** * @file * Contains \Drupal\Core\Datetime\DateHelper. + */ + +namespace Drupal\Core\Datetime; + +/** + * Defines Gregorian Calendar date values. * * Lots of helpful functions for use in massaging dates, specific to the * Gregorian calendar system. The values include both translated and @@ -14,12 +20,6 @@ * translation should be hard-coded and wrapped in t() so the translation system * will be able to process them. */ - -namespace Drupal\Core\Datetime; - -/** - * Defines Gregorian Calendar date values. - */ class DateHelper { /** diff --git a/core/lib/Drupal/Core/Routing/UrlGeneratorTrait.php b/core/lib/Drupal/Core/Routing/UrlGeneratorTrait.php index 31dd2864cd60..2dba9d8fcea9 100644 --- a/core/lib/Drupal/Core/Routing/UrlGeneratorTrait.php +++ b/core/lib/Drupal/Core/Routing/UrlGeneratorTrait.php @@ -3,9 +3,6 @@ /** * @file * Contains \Drupal\Core\Routing\UrlGeneratorTrait. - * - * @deprecated in Drupal 8.0.0 and will be removed before Drupal 9.0.0. - * Use \Drupal\Core\Url instead. */ namespace Drupal\Core\Routing; @@ -19,6 +16,9 @@ use Symfony\Component\HttpFoundation\RedirectResponse; * classes that would implement ContainerInjectionInterface. Services registered * in the Container should not use this trait but inject the appropriate service * directly for easier testing. + * + * @deprecated in Drupal 8.0.0 and will be removed before Drupal 9.0.0. + * Use \Drupal\Core\Url instead. */ trait UrlGeneratorTrait { diff --git a/core/lib/Drupal/Core/StreamWrapper/StreamWrapperInterface.php b/core/lib/Drupal/Core/StreamWrapper/StreamWrapperInterface.php index f13cfb80fc9c..e23c0ee86248 100644 --- a/core/lib/Drupal/Core/StreamWrapper/StreamWrapperInterface.php +++ b/core/lib/Drupal/Core/StreamWrapper/StreamWrapperInterface.php @@ -3,9 +3,16 @@ /** * @file * Contains \Drupal\Core\StreamWrapper\StreamWrapperInterface. + */ + +namespace Drupal\Core\StreamWrapper; + +/** + * Defines a Drupal stream wrapper extension. * * Provides a Drupal interface and classes to implement PHP stream wrappers for - * public, private, and temporary files. + * public, private, and temporary files. Extends the StreamWrapperInterface + * with methods expected by Drupal stream wrapper classes. * * A stream wrapper is an abstraction of a file system that allows Drupal to * use the same set of methods to access both local files and remote resources. @@ -18,15 +25,6 @@ * @see http://www.faqs.org/rfcs/rfc3986.html * @see http://bugs.php.net/bug.php?id=47070 */ - -namespace Drupal\Core\StreamWrapper; - -/** - * Defines a Drupal stream wrapper extension. - * - * Extends the StreamWrapperInterface with methods expected by Drupal stream - * wrapper classes. - */ interface StreamWrapperInterface extends PhpStreamWrapperInterface { /** diff --git a/core/lib/Drupal/Core/Template/TwigExtension.php b/core/lib/Drupal/Core/Template/TwigExtension.php index 63410cd1100a..01a3d1aa4b39 100644 --- a/core/lib/Drupal/Core/Template/TwigExtension.php +++ b/core/lib/Drupal/Core/Template/TwigExtension.php @@ -3,11 +3,6 @@ /** * @file * Contains \Drupal\Core\Template\TwigExtension. - * - * This provides a Twig extension that registers various Drupal specific - * extensions to Twig. - * - * @see \Drupal\Core\CoreServiceProvider */ namespace Drupal\Core\Template; @@ -24,7 +19,8 @@ use Drupal\Core\Url; /** * A class providing Drupal Twig extensions. * - * Specifically Twig functions, filter and node visitors. + * This provides a Twig extension that registers various Drupal-specific + * extensions to Twig, specifically Twig functions, filter, and node visitors. * * @see \Drupal\Core\CoreServiceProvider */ diff --git a/core/lib/Drupal/Core/Template/TwigNodeTrans.php b/core/lib/Drupal/Core/Template/TwigNodeTrans.php index 9d747b722aa5..b2cffa6e374c 100644 --- a/core/lib/Drupal/Core/Template/TwigNodeTrans.php +++ b/core/lib/Drupal/Core/Template/TwigNodeTrans.php @@ -3,6 +3,12 @@ /** * @file * Contains \Drupal\Core\Template\TwigNodeTrans. + */ + +namespace Drupal\Core\Template; + +/** + * A class that defines the Twig 'trans' tag for Drupal. * * This Twig extension was originally based on Twig i18n extension. It has been * severely modified to work properly with the complexities of the Drupal @@ -11,12 +17,6 @@ * @see http://twig.sensiolabs.org/doc/extensions/i18n.html * @see https://github.com/fabpot/Twig-extensions */ - -namespace Drupal\Core\Template; - -/** - * A class that defines the Twig 'trans' tag for Drupal. - */ class TwigNodeTrans extends \Twig_Node { /** diff --git a/core/modules/block/src/Tests/BlockHookOperationTest.php b/core/modules/block/src/Tests/BlockHookOperationTest.php index c83882c81f38..727aa877da72 100644 --- a/core/modules/block/src/Tests/BlockHookOperationTest.php +++ b/core/modules/block/src/Tests/BlockHookOperationTest.php @@ -3,8 +3,6 @@ /** * @file * Contains \Drupal\block\Tests\BlockHookOperationTest. - * - * Tests for Block module regarding hook_entity_operations_alter(). */ namespace Drupal\block\Tests; @@ -13,7 +11,7 @@ use Drupal\Component\Utility\Unicode; use Drupal\simpletest\WebTestBase; /** - * Implement hook entity operations alter. + * Tests for Block module regarding hook_entity_operations_alter(). * * @group block */ diff --git a/core/modules/field/src/Tests/Views/FieldTestBase.php b/core/modules/field/src/Tests/Views/FieldTestBase.php index 4e9cfc227459..06158cd270e5 100644 --- a/core/modules/field/src/Tests/Views/FieldTestBase.php +++ b/core/modules/field/src/Tests/Views/FieldTestBase.php @@ -5,18 +5,6 @@ * Contains \Drupal\field\Tests\Views\FieldTestBase. */ -/** - * @TODO - * - Test on a generic entity not on a node. - * - * What has to be tested: - * - Make sure that every wanted field is added to the according entity type. - * - Make sure the joins are done correctly. - * - Use basic fields and make sure that the full wanted object is built. - * - Use relationships between different entity types, for example node and - * the node author(user). - */ - namespace Drupal\field\Tests\Views; use Drupal\field\Entity\FieldConfig; @@ -27,6 +15,13 @@ use Drupal\field\Entity\FieldStorageConfig; /** * Provides some helper methods for testing fieldapi integration into views. + * + * @todo Test on a generic entity not on a node. What has to be tested: + * - Make sure that every wanted field is added to the according entity type. + * - Make sure the joins are done correctly. + * - Use basic fields and make sure that the full wanted object is built. + * - Use relationships between different entity types, for example node and + * the node author(user). */ abstract class FieldTestBase extends ViewTestBase { diff --git a/core/modules/filter/tests/filter_test_plugin/src/Plugin/Filter/FilterSparkles.php b/core/modules/filter/tests/filter_test_plugin/src/Plugin/Filter/FilterSparkles.php index 5edd60790f34..338a531a638f 100644 --- a/core/modules/filter/tests/filter_test_plugin/src/Plugin/Filter/FilterSparkles.php +++ b/core/modules/filter/tests/filter_test_plugin/src/Plugin/Filter/FilterSparkles.php @@ -3,11 +3,6 @@ /** * @file * Contains \Drupal\filter_test_plugin\Plugin\Filter\FilterSparkles. - * - * This filter does not do anything, but enabling of its module is done in a - * test. - * - * @see \Drupal\filter\Tests\FilterFormTest::testFilterForm() */ namespace Drupal\filter_test_plugin\Plugin\Filter; @@ -18,6 +13,11 @@ use Drupal\filter\Plugin\FilterBase; /** * Provides a filter to limit allowed HTML tags. * + * This filter does not do anything, but enabling of its module is done in a + * test. + * + * @see \Drupal\filter\Tests\FilterFormTest::testFilterForm() + * * @Filter( * id = "filter_sparkles", * title = @Translation("Sparkles filter"), diff --git a/core/tests/Drupal/Tests/Component/Utility/NumberTest.php b/core/tests/Drupal/Tests/Component/Utility/NumberTest.php index bce38736ad5e..786abec53ce2 100644 --- a/core/tests/Drupal/Tests/Component/Utility/NumberTest.php +++ b/core/tests/Drupal/Tests/Component/Utility/NumberTest.php @@ -3,8 +3,6 @@ /** * @file * Contains \Drupal\Tests\Component\Utility\NumberTest. - * - * @see \Drupal\Component\Utility\Number */ namespace Drupal\Tests\Component\Utility; @@ -18,6 +16,8 @@ use Drupal\Tests\UnitTestCase; * @group Utility * * @coversDefaultClass \Drupal\Component\Utility\Number + * + * @see \Drupal\Component\Utility\Number */ class NumberTest extends UnitTestCase { diff --git a/core/tests/Drupal/Tests/Listeners/DrupalStandardsListener.php b/core/tests/Drupal/Tests/Listeners/DrupalStandardsListener.php index 4bcc2e107aab..325fadf47001 100644 --- a/core/tests/Drupal/Tests/Listeners/DrupalStandardsListener.php +++ b/core/tests/Drupal/Tests/Listeners/DrupalStandardsListener.php @@ -3,15 +3,14 @@ /** * @file * Contains \Drupal\Tests\Listeners\DrupalStandardsListener. - * - * Listener for PHPUnit tests, to enforce various coding standards within test - * runs. */ namespace Drupal\Tests\Listeners; /** * Listens for PHPUnit tests and fails those with invalid coverage annotations. + * + * Enforces various coding standards within test runs. */ class DrupalStandardsListener extends \PHPUnit_Framework_BaseTestListener {