@@ -19,7 +19,7 @@ function config_help($route_name, RouteMatchInterface $route_match) {
$output.='<h3>'.t('Uses').'</h3>';
$output.='<dl>';
$output.='<dt>'.t('Exporting the full configuration').'</dt>';
$output.='<dd>'.t('You can create and download an archive consisting of all your site\'s configuration exported as <em>*.yml</em> files on the <a href=":url">Export</a> page.',array(':url'=>\Drupal::url('config.export_full'))).'</dd>';
$output.='<dd>'.t('You can create and download an archive consisting of all your site\'s configuration exported as <em>*.yml</em> files on the <a href=":url">Export</a> page.',array(':url'=>\Drupal::url('config.export_full'))).'</dd>';
$output.='<dt>'.t('Importing a full configuration').'</dt>';
$output.='<dd>'.t('You can upload a full site configuration from an archive file on the <a href=":url">Import</a> page. When importing data from a different environment, the site and import files must have matching configuration values for UUID in the <em>system.site</em> configuration item. That means that your other environments should initially be set up as clones of the target site. Migrations are not supported.',array(':url'=>\Drupal::url('config.import_full'))).'</dd>';
@@ -54,7 +54,7 @@ function testFieldAttachSaveLoad() {
$this->assertEqual(count($entity->{$this->fieldTestData->field_name}),$cardinality,'Current revision: expected number of values');
for($delta=0;$delta<$cardinality;$delta++){
// The field value loaded matches the one inserted or updated.
$this->assertEqual($entity->{$this->fieldTestData->field_name}[$delta]->value,$values[$current_revision][$delta]['value'],format_string('Current revision: expected value %delta was found.',array('%delta'=>$delta)));
$this->assertEqual($entity->{$this->fieldTestData->field_name}[$delta]->value,$values[$current_revision][$delta]['value'],format_string('Current revision: expected value %delta was found.',array('%delta'=>$delta)));
$this->assertIdentical($config['description'],'','Description defaults to empty string.');
// Check that default settings are set.
$this->assertEqual($config['settings'],$field_type_manager->getDefaultFieldSettings($this->fieldStorageDefinition['type']),'Default field settings have been written.');
$this->assertEqual($config['settings'],$field_type_manager->getDefaultFieldSettings($this->fieldStorageDefinition['type']),'Default field settings have been written.');
// Check that the denormalized 'field_type' was properly written.
@@ -33,7 +33,7 @@ function language_help($route_name, RouteMatchInterface $route_match) {
$output.='<h3>'.t('Uses').'</h3>';
$output.='<dl>';
$output.='<dt>'.t('Adding languages').'</dt>';
$output.='<dd>'.t('You can add languages on the <a href=":language_list">Languages</a> page by selecting <em>Add language</em> and choosing a language from the drop-down menu. This language is then displayed in the languages list, where it can be configured further. If the <a href=":interface">Interface translation module</a> is enabled, and the <em>translation server</em> is set as a translation source, then the interface translation for this language is automatically downloaded as well.',array(':language_list'=>\Drupal::url('entity.configurable_language.collection'),':interface'=>(\Drupal::moduleHandler()->moduleExists('locale'))?\Drupal::url('help.page',array('name'=>'locale')):'#')).'</dd>';
$output.='<dd>'.t('You can add languages on the <a href=":language_list">Languages</a> page by selecting <em>Add language</em> and choosing a language from the drop-down menu. This language is then displayed in the languages list, where it can be configured further. If the <a href=":interface">Interface translation module</a> is enabled, and the <em>translation server</em> is set as a translation source, then the interface translation for this language is automatically downloaded as well.',array(':language_list'=>\Drupal::url('entity.configurable_language.collection'),':interface'=>(\Drupal::moduleHandler()->moduleExists('locale'))?\Drupal::url('help.page',array('name'=>'locale')):'#')).'</dd>';
$output.='<dd>'.t('You can add a language that is not provided in the drop-down list by choosing <em>Custom language</em> at the end of the list. You then have to configure its language code, name, and direction in the form provided.').'</dd>';
$this->assertTrue(strpos($rendered_js,'core/assets/vendor/backbone/backbone-min.js?v=1.2.3')>0&&strpos($rendered_js,'core/assets/vendor/domready/ready.min.js?v=1.0.8')>0,'JavaScript version identifiers correctly appended to URLs');
$this->assertTrue(strpos($rendered_js,'core/assets/vendor/backbone/backbone-min.js?v=1.2.3')>0&&strpos($rendered_js,'core/assets/vendor/domready/ready.min.js?v=1.0.8')>0,'JavaScript version identifiers correctly appended to URLs');
$output.='<dd>'.t('Users who have the <em>Administer vocabularies and terms</em> permission can add and edit vocabularies from the <a href=":taxonomy_admin">Taxonomy administration page</a>. Vocabularies can be deleted from their <em>Edit vocabulary</em> page. Users with the <em>Taxonomy term: Administer fields</em> permission may add additional fields for terms in that vocabulary using the <a href=":field_ui">Field UI module</a>.',array(':taxonomy_admin'=>\Drupal::url('entity.taxonomy_vocabulary.collection'),':field_ui'=>$field_ui_url)).'</dd>';
$output.='<dd>'.t('Users who have the <em>Administer vocabularies and terms</em> permission can add and edit vocabularies from the <a href=":taxonomy_admin">Taxonomy administration page</a>. Vocabularies can be deleted from their <em>Edit vocabulary</em> page. Users with the <em>Taxonomy term: Administer fields</em> permission may add additional fields for terms in that vocabulary using the <a href=":field_ui">Field UI module</a>.',array(':taxonomy_admin'=>\Drupal::url('entity.taxonomy_vocabulary.collection'),':field_ui'=>$field_ui_url)).'</dd>';
$output.='<dt>'.t('Managing terms').'</dt>';
$output.='<dd>'.t('Users who have the <em>Administer vocabularies and terms</em> permission or the <em>Edit terms</em> permission for a particular vocabulary can add, edit, and organize the terms in a vocabulary from a vocabulary\'s term listing page, which can be accessed by going to the <a href=":taxonomy_admin">Taxonomy administration page</a> and clicking <em>List terms</em> in the <em>Operations</em> column. Users must have the <em>Administer vocabularies and terms</em> permission or the <em>Delete terms</em> permission for a particular vocabulary to delete terms.',array(':taxonomy_admin'=>\Drupal::url('entity.taxonomy_vocabulary.collection'))).' </dd>';
$output.='<dd>'.t('Users who have the <em>Administer vocabularies and terms</em> permission or the <em>Edit terms</em> permission for a particular vocabulary can add, edit, and organize the terms in a vocabulary from a vocabulary\'s term listing page, which can be accessed by going to the <a href=":taxonomy_admin">Taxonomy administration page</a> and clicking <em>List terms</em> in the <em>Operations</em> column. Users must have the <em>Administer vocabularies and terms</em> permission or the <em>Delete terms</em> permission for a particular vocabulary to delete terms.',array(':taxonomy_admin'=>\Drupal::url('entity.taxonomy_vocabulary.collection'))).' </dd>';
$output.='<dd>'.t('A user with the <em>Administer fields</em> permission for a certain entity type may add <em>Taxonomy term</em> reference fields to the entity type, which will allow entities to be classified using taxonomy terms. See the <a href=":entity_reference">Entity Reference help</a> for more information about reference fields. See the <a href=":field">Field module help</a> and the <a href=":field_ui">Field UI help</a> pages for general information on fields and how to create and manage them.',array(':field_ui'=>$field_ui_url,':field'=>\Drupal::url('help.page',array('name'=>'field')),':entity_reference'=>\Drupal::url('help.page',array('name'=>'entity_reference')))).'</dd>';
$output.='<dd>'.t('A user with the <em>Administer fields</em> permission for a certain entity type may add <em>Taxonomy term</em> reference fields to the entity type, which will allow entities to be classified using taxonomy terms. See the <a href=":entity_reference">Entity Reference help</a> for more information about reference fields. See the <a href=":field">Field module help</a> and the <a href=":field_ui">Field UI help</a> pages for general information on fields and how to create and manage them.',array(':field_ui'=>$field_ui_url,':field'=>\Drupal::url('help.page',array('name'=>'field')),':entity_reference'=>\Drupal::url('help.page',array('name'=>'entity_reference')))).'</dd>';
$output.='<dt>'.t('Adding new terms during content creation').'</dt>';
$output.='<dd>'.t('Allowing users to add new terms gradually builds a vocabulary as content is added and edited. Users can add new terms if either of the two <em>Autocomplete</em> widgets is chosen for the Taxonomy term reference field in the <em>Manage form display</em> page for the field. You will also need to enable the <em>Create referenced entities if they don\'t already exist</em> option, and restrict the field to one vocabulary.').'</dd>';
$output.='<dt>'.t('Configuring displays and form displays').'</dt>';
@@ -34,7 +34,7 @@ public function testUserMail() {
$this->assertIdentical('Account details for [user:name] at [site:name] (approved)',$config->get('status_activated.subject'));
$this->assertIdentical("[user:name],\n\nYour account at [site:name] has been activated.\n\nYou may now log in by clicking on this link or copying and pasting it in your browser:\n\n[user:one-time-login-url]\n\nThis is a one-time login, so it can be used only once.\n\nAfter logging in, you will be redirected to [user:edit-url] so you can change your password.\n\nOnce you have set your own password, you will be able to log in to [site:login-url] in the future using:\n\nusername: [user:name]\n",$config->get('status_activated.body'));
$this->assertIdentical('Replacement login information for [user:name] at [site:name]',$config->get('password_reset.subject'));
$this->assertIdentical("[user:name],\n\nA request to reset the password for your account has been made at [site:name].\n\nYou may now log in to [site:url-brief] by clicking on this link or copying and pasting it in your browser:\n\n[user:one-time-login-url]\n\nThis is a one-time login, so it can be used only once. It expires after one day and nothing will happen if it's not used.\n\nAfter logging in, you will be redirected to [user:edit-url] so you can change your password.",$config->get('password_reset.body'));
$this->assertIdentical("[user:name],\n\nA request to reset the password for your account has been made at [site:name].\n\nYou may now log in to [site:url-brief] by clicking on this link or copying and pasting it in your browser:\n\n[user:one-time-login-url]\n\nThis is a one-time login, so it can be used only once. It expires after one day and nothing will happen if it's not used.\n\nAfter logging in, you will be redirected to [user:edit-url] so you can change your password.",$config->get('password_reset.body'));
$this->assertIdentical('Account details for [user:name] at [site:name] (deleted)',$config->get('cancel_confirm.subject'));
$this->assertIdentical("[user:name],\n\nYour account on [site:name] has been deleted.",$config->get('cancel_confirm.body'));
$this->assertIdentical('An administrator created an account for you at [site:name]',$config->get('register_admin_created.subject'));
// Test that the statistics and query are rendered above the preview.
$this->assertTrue(strpos($this->getRawContent(),'views-query-info')<strpos($this->getRawContent(),'view-test-preview'),'Statistics shown above the preview.');
$this->assertTrue(strpos($this->getRawContent(),'views-query-info')<strpos($this->getRawContent(),'view-test-preview'),'Statistics shown above the preview.');
// Test that statistics and query rendered below the preview.
$this->assertTrue(isset($build['#cache'])&&array_keys($build['#cache'])==['tags','contexts','max-age','keys','bin'],'A view mode with render cache enabled has the correct output (cache tags, keys, contexts, max-age and bin).');
$this->assertTrue(isset($build['#cache'])&&array_keys($build['#cache'])==['tags','contexts','max-age','keys','bin'],'A view mode with render cache enabled has the correct output (cache tags, keys, contexts, max-age and bin).');
// Test that a view mode can opt out of render caching.