Update to Drupal 8.1.0. For more information, see https://www.drupal.org/drupal-8.1.0-release-notes
This commit is contained in:
parent
b11a755ba8
commit
c0a0d5a94c
6920 changed files with 64395 additions and 57312 deletions
|
@ -1,10 +1,5 @@
|
|||
<?php
|
||||
|
||||
/**
|
||||
* @file
|
||||
* Contains \Drupal\forum\Breadcrumb\ForumBreadcrumbBuilderBase.
|
||||
*/
|
||||
|
||||
namespace Drupal\forum\Breadcrumb;
|
||||
|
||||
use Drupal\Core\Breadcrumb\BreadcrumbBuilderInterface;
|
||||
|
|
|
@ -1,10 +1,5 @@
|
|||
<?php
|
||||
|
||||
/**
|
||||
* @file
|
||||
* Contains \Drupal\forum\Breadcrumb\ForumListingBreadcrumbBuilder.
|
||||
*/
|
||||
|
||||
namespace Drupal\forum\Breadcrumb;
|
||||
|
||||
use Drupal\Core\Link;
|
||||
|
|
|
@ -1,10 +1,5 @@
|
|||
<?php
|
||||
|
||||
/**
|
||||
* @file
|
||||
* Contains \Drupal\forum\Breadcrumb\ForumNodeBreadcrumbBuilder.
|
||||
*/
|
||||
|
||||
namespace Drupal\forum\Breadcrumb;
|
||||
|
||||
use Drupal\Core\Link;
|
||||
|
|
|
@ -1,10 +1,5 @@
|
|||
<?php
|
||||
|
||||
/**
|
||||
* @file
|
||||
* Contains \Drupal\forum\Controller\ForumController.
|
||||
*/
|
||||
|
||||
namespace Drupal\forum\Controller;
|
||||
|
||||
use Drupal\Core\Cache\Cache;
|
||||
|
|
|
@ -1,10 +1,5 @@
|
|||
<?php
|
||||
|
||||
/**
|
||||
* @file
|
||||
* Contains \Drupal\forum\Form\ContainerForm.
|
||||
*/
|
||||
|
||||
namespace Drupal\forum\Form;
|
||||
|
||||
use Drupal\Core\Form\FormStateInterface;
|
||||
|
|
|
@ -1,10 +1,5 @@
|
|||
<?php
|
||||
|
||||
/**
|
||||
* @file
|
||||
* Contains \Drupal\forum\Form\DeleteForm.
|
||||
*/
|
||||
|
||||
namespace Drupal\forum\Form;
|
||||
|
||||
use Drupal\Core\Form\ConfirmFormBase;
|
||||
|
|
|
@ -1,10 +1,5 @@
|
|||
<?php
|
||||
|
||||
/**
|
||||
* @file
|
||||
* Contains \Drupal\forum\Form\ForumForm.
|
||||
*/
|
||||
|
||||
namespace Drupal\forum\Form;
|
||||
|
||||
use Drupal\Core\Form\FormStateInterface;
|
||||
|
|
|
@ -1,10 +1,5 @@
|
|||
<?php
|
||||
|
||||
/**
|
||||
* @file
|
||||
* Contains \Drupal\forum\Form\Overview.
|
||||
*/
|
||||
|
||||
namespace Drupal\forum\Form;
|
||||
|
||||
use Drupal\Core\Entity\EntityManagerInterface;
|
||||
|
|
|
@ -1,10 +1,5 @@
|
|||
<?php
|
||||
|
||||
/**
|
||||
* @file
|
||||
* Contains \Drupal\forum\ForumIndexStorage.
|
||||
*/
|
||||
|
||||
namespace Drupal\forum;
|
||||
use Drupal\comment\CommentInterface;
|
||||
use Drupal\Core\Database\Connection;
|
||||
|
|
|
@ -1,8 +1,5 @@
|
|||
<?php
|
||||
/**
|
||||
* @file
|
||||
* Contains \Drupal\forum\ForumIndexStorageInterface.
|
||||
*/
|
||||
|
||||
namespace Drupal\forum;
|
||||
|
||||
use Drupal\node\NodeInterface;
|
||||
|
|
|
@ -1,10 +1,5 @@
|
|||
<?php
|
||||
|
||||
/**
|
||||
* @file
|
||||
* Contains \Drupal\forum\ForumManager.
|
||||
*/
|
||||
|
||||
namespace Drupal\forum;
|
||||
|
||||
use Drupal\Core\Config\ConfigFactoryInterface;
|
||||
|
|
|
@ -1,10 +1,5 @@
|
|||
<?php
|
||||
|
||||
/**
|
||||
* @file
|
||||
* Contains \Drupal\forum\ForumManagerInterface.
|
||||
*/
|
||||
|
||||
namespace Drupal\forum;
|
||||
|
||||
use Drupal\Core\Session\AccountInterface;
|
||||
|
|
|
@ -1,10 +1,5 @@
|
|||
<?php
|
||||
|
||||
/**
|
||||
* @file
|
||||
* Contains \Drupal\forum\ForumSettingsForm.
|
||||
*/
|
||||
|
||||
namespace Drupal\forum;
|
||||
|
||||
use Drupal\Core\Form\ConfigFormBase;
|
||||
|
|
|
@ -1,10 +1,5 @@
|
|||
<?php
|
||||
|
||||
/**
|
||||
* @file
|
||||
* Contains \Drupal\forum\ForumUninstallValidator.
|
||||
*/
|
||||
|
||||
namespace Drupal\forum;
|
||||
|
||||
use Drupal\Core\Config\ConfigFactoryInterface;
|
||||
|
@ -52,7 +47,7 @@ class ForumUninstallValidator implements ModuleUninstallValidatorInterface {
|
|||
* @param \Drupal\Core\Entity\Query\QueryFactory $query_factory
|
||||
* The entity query factory.
|
||||
* @param \Drupal\Core\Config\ConfigFactoryInterface $config_factory
|
||||
* The config factory.
|
||||
* The config factory.
|
||||
* @param \Drupal\Core\StringTranslation\TranslationInterface $string_translation
|
||||
* The string translation service.
|
||||
*/
|
||||
|
|
|
@ -1,10 +1,5 @@
|
|||
<?php
|
||||
|
||||
/**
|
||||
* @file
|
||||
* Contains \Drupal\forum\Plugin\Block\ActiveTopicsBlock.
|
||||
*/
|
||||
|
||||
namespace Drupal\forum\Plugin\Block;
|
||||
|
||||
/**
|
||||
|
|
|
@ -1,10 +1,5 @@
|
|||
<?php
|
||||
|
||||
/**
|
||||
* @file
|
||||
* Contains \Drupal\forum\Plugin\Block\ForumBlockBase.
|
||||
*/
|
||||
|
||||
namespace Drupal\forum\Plugin\Block;
|
||||
|
||||
use Drupal\Core\Access\AccessResult;
|
||||
|
|
|
@ -1,10 +1,5 @@
|
|||
<?php
|
||||
|
||||
/**
|
||||
* @file
|
||||
* Contains \Drupal\forum\Plugin\Block\NewTopicsBlock.
|
||||
*/
|
||||
|
||||
namespace Drupal\forum\Plugin\Block;
|
||||
|
||||
/**
|
||||
|
|
|
@ -1,10 +1,5 @@
|
|||
<?php
|
||||
|
||||
/**
|
||||
* @file
|
||||
* Contains \Drupal\forum\Plugin\Validation\Constraint\ForumLeafConstraint.
|
||||
*/
|
||||
|
||||
namespace Drupal\forum\Plugin\Validation\Constraint;
|
||||
|
||||
use Symfony\Component\Validator\Constraint;
|
||||
|
|
|
@ -1,10 +1,5 @@
|
|||
<?php
|
||||
|
||||
/**
|
||||
* @file
|
||||
* Contains \Drupal\forum\Plugin\Validation\Constraint\ForumLeafConstraintValidator.
|
||||
*/
|
||||
|
||||
namespace Drupal\forum\Plugin\Validation\Constraint;
|
||||
|
||||
use Symfony\Component\Validator\Constraint;
|
||||
|
|
|
@ -1,9 +1,5 @@
|
|||
<?php
|
||||
|
||||
/**
|
||||
* @file
|
||||
* Contains \Drupal\forum\ProxyClass\ForumUninstallValidator.
|
||||
*/
|
||||
// @codingStandardsIgnoreFile
|
||||
|
||||
/**
|
||||
* This file was generated via php core/scripts/generate-proxy-class.php 'Drupal\forum\ForumUninstallValidator' "core/modules/forum/src".
|
||||
|
|
|
@ -1,14 +1,10 @@
|
|||
<?php
|
||||
|
||||
/**
|
||||
* @file
|
||||
* Contains \Drupal\forum\Tests\ForumBlockTest.
|
||||
*/
|
||||
|
||||
namespace Drupal\forum\Tests;
|
||||
|
||||
use Drupal\simpletest\WebTestBase;
|
||||
use Drupal\Core\Datetime\DrupalDateTime;
|
||||
use Drupal\comment\Entity\Comment;
|
||||
|
||||
/**
|
||||
* Tests the forum blocks.
|
||||
|
@ -97,7 +93,7 @@ class ForumBlockTest extends WebTestBase {
|
|||
// Get the node from the topic title.
|
||||
$node = $this->drupalGetNodeByTitle($topics[$index]);
|
||||
$date->modify('+1 minute');
|
||||
$comment = entity_create('comment', array(
|
||||
$comment = Comment::create(array(
|
||||
'entity_id' => $node->id(),
|
||||
'field_name' => 'comment_forum',
|
||||
'entity_type' => 'node',
|
||||
|
|
|
@ -1,10 +1,5 @@
|
|||
<?php
|
||||
|
||||
/**
|
||||
* @file
|
||||
* Contains \Drupal\forum\Tests\ForumIndexTest.
|
||||
*/
|
||||
|
||||
namespace Drupal\forum\Tests;
|
||||
|
||||
use Drupal\simpletest\WebTestBase;
|
||||
|
|
|
@ -1,10 +1,5 @@
|
|||
<?php
|
||||
|
||||
/**
|
||||
* @file
|
||||
* Contains \Drupal\forum\Tests\ForumNodeAccessTest.
|
||||
*/
|
||||
|
||||
namespace Drupal\forum\Tests;
|
||||
|
||||
use Drupal\simpletest\WebTestBase;
|
||||
|
|
|
@ -1,12 +1,5 @@
|
|||
<?php
|
||||
|
||||
/**
|
||||
* @file
|
||||
* Contains \Drupal\forum\Tests\ForumTest.
|
||||
*
|
||||
* Tests for forum.module.
|
||||
*/
|
||||
|
||||
namespace Drupal\forum\Tests;
|
||||
|
||||
use Drupal\Core\Entity\Entity\EntityFormDisplay;
|
||||
|
@ -18,6 +11,8 @@ use Drupal\Core\Url;
|
|||
use Drupal\taxonomy\Entity\Vocabulary;
|
||||
|
||||
/**
|
||||
* Tests for forum.module.
|
||||
*
|
||||
* Create, view, edit, delete, and change forum entries and verify its
|
||||
* consistency in the database.
|
||||
*
|
||||
|
@ -339,13 +334,13 @@ class ForumTest extends WebTestBase {
|
|||
// Create a default vocabulary named "Tags".
|
||||
$description = 'Use tags to group articles on similar topics into categories.';
|
||||
$help = 'Enter a comma-separated list of words to describe your content.';
|
||||
$vocabulary = entity_create('taxonomy_vocabulary', array(
|
||||
$vocabulary = Vocabulary::create([
|
||||
'name' => 'Tags',
|
||||
'description' => $description,
|
||||
'vid' => 'tags',
|
||||
'langcode' => \Drupal::languageManager()->getDefaultLanguage()->getId(),
|
||||
'help' => $help,
|
||||
));
|
||||
]);
|
||||
$vocabulary->save();
|
||||
// Test tags vocabulary form is not affected.
|
||||
$this->drupalGet('admin/structure/taxonomy/manage/tags');
|
||||
|
|
|
@ -1,16 +1,13 @@
|
|||
<?php
|
||||
|
||||
/**
|
||||
* @file
|
||||
* Contains \Drupal\forum\Tests\ForumUninstallTest.
|
||||
*/
|
||||
|
||||
namespace Drupal\forum\Tests;
|
||||
|
||||
use Drupal\comment\CommentInterface;
|
||||
use Drupal\field\Entity\FieldStorageConfig;
|
||||
use Drupal\node\Entity\NodeType;
|
||||
use Drupal\simpletest\WebTestBase;
|
||||
use Drupal\comment\Entity\Comment;
|
||||
use Drupal\taxonomy\Entity\Term;
|
||||
|
||||
/**
|
||||
* Tests forum module uninstallation.
|
||||
|
@ -36,14 +33,14 @@ class ForumUninstallTest extends WebTestBase {
|
|||
$this->assertNotNull($field_storage, 'The taxonomy_forums field storage exists.');
|
||||
|
||||
// Create a taxonomy term.
|
||||
$term = entity_create('taxonomy_term', array(
|
||||
$term = Term::create([
|
||||
'name' => t('A term'),
|
||||
'langcode' => \Drupal::languageManager()->getDefaultLanguage()->getId(),
|
||||
'description' => '',
|
||||
'parent' => array(0),
|
||||
'vid' => 'forums',
|
||||
'forum_container' => 0,
|
||||
));
|
||||
]);
|
||||
$term->save();
|
||||
|
||||
// Create a forum node.
|
||||
|
@ -54,7 +51,7 @@ class ForumUninstallTest extends WebTestBase {
|
|||
));
|
||||
|
||||
// Create at least one comment against the forum node.
|
||||
$comment = entity_create('comment', array(
|
||||
$comment = Comment::create(array(
|
||||
'entity_id' => $node->nid->value,
|
||||
'entity_type' => 'node',
|
||||
'field_name' => 'comment_forum',
|
||||
|
|
|
@ -1,10 +1,5 @@
|
|||
<?php
|
||||
|
||||
/**
|
||||
* @file
|
||||
* Contains \Drupal\forum\Tests\ForumValidationTest.
|
||||
*/
|
||||
|
||||
namespace Drupal\forum\Tests;
|
||||
|
||||
use Drupal\node\Entity\Node;
|
||||
|
|
|
@ -1,10 +1,5 @@
|
|||
<?php
|
||||
|
||||
/**
|
||||
* @file
|
||||
* Contains \Drupal\forum\Tests\Views\ForumIntegrationTest.
|
||||
*/
|
||||
|
||||
namespace Drupal\forum\Tests\Views;
|
||||
|
||||
use Drupal\views\Views;
|
||||
|
|
|
@ -1,14 +1,9 @@
|
|||
<?php
|
||||
|
||||
/**
|
||||
* @file
|
||||
* Contains \Drupal\forum\Tests\Migrate\d6\MigrateForumConfigsTest.
|
||||
*/
|
||||
|
||||
namespace Drupal\forum\Tests\Migrate\d6;
|
||||
namespace Drupal\Tests\forum\Kernel\Migrate\d6;
|
||||
|
||||
use Drupal\config\Tests\SchemaCheckTestTrait;
|
||||
use Drupal\migrate_drupal\Tests\d6\MigrateDrupal6TestBase;
|
||||
use Drupal\Tests\migrate_drupal\Kernel\d6\MigrateDrupal6TestBase;
|
||||
|
||||
/**
|
||||
* Upgrade variables to forum.settings.yml.
|
|
@ -1,13 +1,8 @@
|
|||
<?php
|
||||
|
||||
/**
|
||||
* @file
|
||||
* Contains \Drupal\forum\Tests\Migrate\d7\MigrateForumSettingsTest.
|
||||
*/
|
||||
namespace Drupal\Tests\forum\Kernel\Migrate\d7;
|
||||
|
||||
namespace Drupal\forum\Tests\Migrate\d7;
|
||||
|
||||
use Drupal\migrate_drupal\Tests\d7\MigrateDrupal7TestBase;
|
||||
use Drupal\Tests\migrate_drupal\Kernel\d7\MigrateDrupal7TestBase;
|
||||
|
||||
/**
|
||||
* Tests migration of Forum's variables to configuration.
|
|
@ -1,10 +1,5 @@
|
|||
<?php
|
||||
|
||||
/**
|
||||
* @file
|
||||
* Contains \Drupal\Tests\forum\Unit\Breadcrumb\ForumBreadcrumbBuilderBaseTest.
|
||||
*/
|
||||
|
||||
namespace Drupal\Tests\forum\Unit\Breadcrumb;
|
||||
|
||||
use Drupal\Core\Cache\Cache;
|
||||
|
|
|
@ -1,10 +1,5 @@
|
|||
<?php
|
||||
|
||||
/**
|
||||
* @file
|
||||
* Contains \Drupal\Tests\forum\Unit\Breadcrumb\ForumListingBreadcrumbBuilderTest.
|
||||
*/
|
||||
|
||||
namespace Drupal\Tests\forum\Unit\Breadcrumb;
|
||||
|
||||
use Drupal\Core\Cache\Cache;
|
||||
|
|
|
@ -1,10 +1,5 @@
|
|||
<?php
|
||||
|
||||
/**
|
||||
* @file
|
||||
* Contains \Drupal\Tests\forum\Unit\Breadcrumb\ForumNodeBreadcrumbBuilderTest.
|
||||
*/
|
||||
|
||||
namespace Drupal\Tests\forum\Unit\Breadcrumb;
|
||||
|
||||
use Drupal\Core\Cache\Cache;
|
||||
|
|
|
@ -1,10 +1,5 @@
|
|||
<?php
|
||||
|
||||
/**
|
||||
* @file
|
||||
* Contains \Drupal\Tests\forum\Unit\ForumManagerTest.
|
||||
*/
|
||||
|
||||
namespace Drupal\Tests\forum\Unit;
|
||||
|
||||
use Drupal\Tests\UnitTestCase;
|
||||
|
|
|
@ -1,10 +1,5 @@
|
|||
<?php
|
||||
|
||||
/**
|
||||
* @file
|
||||
* Contains \Drupal\Tests\forum\Unit\ForumUninstallValidatorTest.
|
||||
*/
|
||||
|
||||
namespace Drupal\Tests\forum\Unit;
|
||||
|
||||
use Drupal\simpletest\AssertHelperTrait;
|
||||
|
|
Reference in a new issue