Update to Drupal 8.0.0-beta15. For more information, see: https://www.drupal.org/node/2563023
This commit is contained in:
parent
2720a9ec4b
commit
f3791f1da3
1898 changed files with 54300 additions and 11481 deletions
|
|
@ -0,0 +1,55 @@
|
|||
<?php
|
||||
|
||||
/**
|
||||
* @file
|
||||
* Contains \Drupal\language\Tests\EntityTypeWithoutLanguageFormTest.
|
||||
*/
|
||||
|
||||
namespace Drupal\language\Tests;
|
||||
|
||||
use Drupal\simpletest\WebTestBase;
|
||||
|
||||
/**
|
||||
* Tests entity type without language support.
|
||||
*
|
||||
* This is to ensure that an entity type without language support can not
|
||||
* enable the language select from the content language settings page.
|
||||
*
|
||||
* @group language
|
||||
*/
|
||||
class EntityTypeWithoutLanguageFormTest extends WebTestBase {
|
||||
|
||||
/**
|
||||
* Modules to enable.
|
||||
*
|
||||
* @var array
|
||||
*/
|
||||
public static $modules = array(
|
||||
'language',
|
||||
'language_test',
|
||||
);
|
||||
|
||||
/**
|
||||
* {@inheritdoc}
|
||||
*/
|
||||
protected function setUp() {
|
||||
parent::setUp();
|
||||
|
||||
// Create and login administrative user.
|
||||
$admin_user = $this->drupalCreateUser(array(
|
||||
'administer languages',
|
||||
));
|
||||
$this->drupalLogin($admin_user);
|
||||
}
|
||||
|
||||
/**
|
||||
* Tests configuration options with an entity without language definition.
|
||||
*/
|
||||
public function testEmptyLangcode() {
|
||||
// Assert that we can not enable language select from
|
||||
// content language settings page.
|
||||
$this->drupalGet('admin/config/regional/content-language');
|
||||
$this->assertNoField('entity_types[no_language_entity_test]');
|
||||
}
|
||||
|
||||
}
|
||||
|
|
@ -21,7 +21,7 @@ class LanguagePathMonolingualTest extends WebTestBase {
|
|||
*
|
||||
* @var array
|
||||
*/
|
||||
public static $modules = array('language', 'path');
|
||||
public static $modules = ['block', 'language', 'path'];
|
||||
|
||||
protected function setUp() {
|
||||
parent::setUp();
|
||||
|
|
@ -56,6 +56,7 @@ class LanguagePathMonolingualTest extends WebTestBase {
|
|||
// Set language detection to URL.
|
||||
$edit = array('language_interface[enabled][language-url]' => TRUE);
|
||||
$this->drupalPostForm('admin/config/regional/language/detection', $edit, t('Save settings'));
|
||||
$this->drupalPlaceBlock('local_actions_block');
|
||||
}
|
||||
|
||||
/**
|
||||
|
|
|
|||
|
|
@ -28,7 +28,7 @@ class LanguageTourTest extends TourTestBase {
|
|||
*
|
||||
* @var array
|
||||
*/
|
||||
public static $modules = array('language', 'tour');
|
||||
public static $modules = ['block', 'language', 'tour'];
|
||||
|
||||
/**
|
||||
* {@inheritdoc}
|
||||
|
|
@ -37,6 +37,7 @@ class LanguageTourTest extends TourTestBase {
|
|||
parent::setUp();
|
||||
$this->adminUser = $this->drupalCreateUser(array('administer languages', 'access tour'));
|
||||
$this->drupalLogin($this->adminUser);
|
||||
$this->drupalPlaceBlock('local_actions_block');
|
||||
}
|
||||
|
||||
/**
|
||||
|
|
|
|||
|
|
@ -0,0 +1,43 @@
|
|||
<?php
|
||||
|
||||
/**
|
||||
* @file
|
||||
* Contains \Drupal\language\Tests\Migrate\d7\MigrateLanguageNegotiationSettingsTest.
|
||||
*/
|
||||
|
||||
namespace Drupal\language\Tests\Migrate\d7;
|
||||
|
||||
use Drupal\migrate_drupal\Tests\d7\MigrateDrupal7TestBase;
|
||||
|
||||
/**
|
||||
* Tests migration of language negotiation variables.
|
||||
*
|
||||
* @group language
|
||||
*/
|
||||
class MigrateLanguageNegotiationSettingsTest extends MigrateDrupal7TestBase {
|
||||
|
||||
/**
|
||||
* Modules to enable.
|
||||
*
|
||||
* @var array
|
||||
*/
|
||||
public static $modules = ['language'];
|
||||
|
||||
/**
|
||||
* {@inheritdoc}
|
||||
*/
|
||||
protected function setUp() {
|
||||
parent::setUp();
|
||||
$this->executeMigration('d7_language_negotiation_settings');
|
||||
}
|
||||
|
||||
/**
|
||||
* Tests migration of language negotiation variables to language.negotiation.yml.
|
||||
*/
|
||||
public function testLanguageNegotiation() {
|
||||
$config = $this->config('language.negotiation');
|
||||
$this->assertIdentical($config->get('session.parameter'), 'language');
|
||||
$this->assertIdentical($config->get('url.source'), 'domain');
|
||||
}
|
||||
|
||||
}
|
||||
|
|
@ -8,12 +8,12 @@
|
|||
namespace Drupal\language\Tests\Views;
|
||||
|
||||
use Drupal\language\Entity\ConfigurableLanguage;
|
||||
use Drupal\views\Tests\ViewUnitTestBase;
|
||||
use Drupal\views\Tests\ViewKernelTestBase;
|
||||
|
||||
/**
|
||||
* Defines the base class for all Language handler tests.
|
||||
*/
|
||||
abstract class LanguageTestBase extends ViewUnitTestBase {
|
||||
abstract class LanguageTestBase extends ViewKernelTestBase {
|
||||
|
||||
/**
|
||||
* Modules to enable.
|
||||
|
|
|
|||
Reference in a new issue