From db56c09587d19ec68d3d947c9d5c7a6421fee6b1 Mon Sep 17 00:00:00 2001 From: Pantheon Automation Date: Wed, 4 Jan 2017 16:50:53 -0800 Subject: [PATCH] Update to Drupal 8.2.5. For more information, see https://www.drupal.org/project/drupal/releases/8.2.5 --- core/MAINTAINERS.txt | 1 - core/includes/schema.inc | 2 +- core/lib/Drupal.php | 5 +- core/lib/Drupal/Core/Render/Element/Date.php | 1 + core/lib/Drupal/Core/Render/Element/Email.php | 1 + .../lib/Drupal/Core/Render/Element/Number.php | 1 + .../Drupal/Core/Render/Element/Password.php | 3 + .../Core/Render/Element/PasswordConfirm.php | 3 + .../lib/Drupal/Core/Render/Element/Select.php | 53 ++-- core/lib/Drupal/Core/Render/Element/Table.php | 1 + core/lib/Drupal/Core/Render/Element/Tel.php | 3 + core/lib/Drupal/Core/Render/Element/Url.php | 1 + core/lib/Drupal/Core/Render/theme.api.php | 47 ++-- .../big_pipe/src/Render/BigPipeInterface.php | 6 + .../big_pipe/src/Render/BigPipeResponse.php | 5 +- core/modules/ckeditor/js/ckeditor.js | 14 + .../CKEditorIntegrationTest.php | 121 ++++++++ .../migration_templates/d7_field_instance.yml | 1 + core/modules/file/file.install | 6 +- core/modules/file/file.module | 2 +- .../Plugin/Field/FieldWidget/FileWidget.php | 15 + .../d7_filter_settings.yml | 13 + .../Migrate/d7/MigrateFilterSettingsTest.php | 32 +++ .../FormErrorHandlerCKEditorTest.php | 111 ++++++++ .../migration_templates/d7_menu_links.yml | 2 +- .../src/Plugin/migrate/process/LinkUri.php | 3 + .../Plugin/migrate/process/d7/InternalUri.php | 40 +-- .../Kernel/Migrate/d7/MigrateMenuLinkTest.php | 10 +- .../Plugin/migrate/process/LinkUriTest.php | 4 + .../migrate/process/d7/InternalUriTest.php | 73 ----- .../src/Plugin/migrate/process/Download.php | 9 +- .../src/Plugin/migrate/process/FileCopy.php | 21 +- .../src/Plugin/migrate/process/Iterator.php | 18 +- .../migrate/source/SourcePluginBase.php | 13 +- .../src/Plugin/migrate/source/SqlBase.php | 165 +++++++---- .../migrate_query_batch_test.info.yml | 7 + .../Plugin/migrate/source/QueryBatchTest.php | 45 +++ .../process/DownloadFunctionalTest.php | 81 ++++++ .../tests/src/Kernel/QueryBatchTest.php | 261 ++++++++++++++++++ .../tests/src/Kernel/process/FileCopyTest.php | 29 ++ .../migrate_drupal/tests/fixtures/drupal7.php | 49 ++++ .../src/Form/MigrateUpgradeForm.php | 4 + .../src/Tests/d7/MigrateUpgrade7Test.php | 4 +- .../modules/node/src/Form/NodePreviewForm.php | 2 +- core/modules/node/src/NodeForm.php | 27 +- .../node/src/Tests/PagePreviewTest.php | 113 +++++++- .../tests/modules/node_test/node_test.module | 15 + .../OutsideInBlockFormTest.php | 145 +++++----- .../OutsideInJavascriptTestBase.php | 13 + ...-rest_post_update_resource_granularity.php | Bin 5317 -> 5199 bytes .../update/drupal-8.rest-rest_update_8201.php | 18 +- .../update/drupal-8.rest-rest_update_8203.php | 11 +- .../rest-export-with-authentication.php | 10 - .../EntityResource/EntityResourceTestBase.php | 7 +- .../system/src/Form/ModulesListForm.php | 1 + .../Tests/Module/ExperimentalModuleTest.php | 8 + .../src/Tests/Update/UpdatePathTestBase.php | 24 ++ ...rimental_module_requirements_test.info.yml | 6 + ...erimental_module_requirements_test.install | 20 ++ ...perimental_module_requirements_test.module | 18 ++ .../migration_templates/d6_taxonomy_term.yml | 2 +- .../migration_templates/d7_taxonomy_term.yml | 5 +- .../Plugin/migrate/D7TaxonomyTermDeriver.php | 130 +++++++++ .../src/Plugin/migrate/source/Term.php | 6 +- .../src/Plugin/migrate/source/d6/Term.php | 74 +++++ .../src/Plugin/migrate/source/d7/Term.php | 84 ++++++ .../Migrate/d7/MigrateTaxonomyTermTest.php | 40 ++- .../TermSourceWithVocabularyFilterTest.php | 6 +- .../migrate/source/{ => d6}/TermTest.php | 65 ++++- .../d7/TermSourceWithVocabularyFilterTest.php | 56 ++++ .../Plugin/migrate/source/d7/TermTest.php | 258 +++++++++++++++++ .../migration_templates/d6_profile_values.yml | 4 - .../UserAuthenticationController.php | 2 +- .../views/argument/ArgumentPluginBase.php | 2 +- .../src/Plugin/views/filter/InOperator.php | 2 +- .../views/src/Tests/Plugin/FilterTest.php | 28 +- core/modules/views/src/Views.php | 2 +- .../FunctionalJavascriptTests/JSWebAssert.php | 199 +++++++++++++ .../Drupal/KernelTests/KernelTestBase.php | 2 +- core/tests/Drupal/Tests/BrowserTestBase.php | 2 +- sites/default/default.settings.php | 6 - vendor/autoload.php | 2 +- vendor/composer/ClassLoader.php | 48 +++- vendor/composer/LICENSE | 2 + vendor/composer/autoload_real.php | 2 +- vendor/composer/installed.json | 148 +++++----- 86 files changed, 2413 insertions(+), 488 deletions(-) create mode 100644 core/modules/ckeditor/tests/src/FunctionalJavascript/CKEditorIntegrationTest.php create mode 100644 core/modules/filter/migration_templates/d7_filter_settings.yml create mode 100644 core/modules/filter/tests/src/Kernel/Migrate/d7/MigrateFilterSettingsTest.php create mode 100644 core/modules/inline_form_errors/tests/src/FunctionalJavascript/FormErrorHandlerCKEditorTest.php delete mode 100644 core/modules/menu_link_content/tests/src/Unit/Plugin/migrate/process/d7/InternalUriTest.php create mode 100644 core/modules/migrate/tests/modules/migrate_query_batch_test/migrate_query_batch_test.info.yml create mode 100644 core/modules/migrate/tests/modules/migrate_query_batch_test/src/Plugin/migrate/source/QueryBatchTest.php create mode 100644 core/modules/migrate/tests/src/Functional/process/DownloadFunctionalTest.php create mode 100644 core/modules/migrate/tests/src/Kernel/QueryBatchTest.php create mode 100644 core/modules/system/tests/modules/experimental_module_requirements_test/experimental_module_requirements_test.info.yml create mode 100644 core/modules/system/tests/modules/experimental_module_requirements_test/experimental_module_requirements_test.install create mode 100644 core/modules/system/tests/modules/experimental_module_requirements_test/experimental_module_requirements_test.module create mode 100644 core/modules/taxonomy/src/Plugin/migrate/D7TaxonomyTermDeriver.php create mode 100644 core/modules/taxonomy/src/Plugin/migrate/source/d6/Term.php create mode 100644 core/modules/taxonomy/src/Plugin/migrate/source/d7/Term.php rename core/modules/taxonomy/tests/src/Kernel/Plugin/migrate/source/{ => d6}/TermSourceWithVocabularyFilterTest.php (87%) rename core/modules/taxonomy/tests/src/Kernel/Plugin/migrate/source/{ => d6}/TermTest.php (61%) create mode 100644 core/modules/taxonomy/tests/src/Kernel/Plugin/migrate/source/d7/TermSourceWithVocabularyFilterTest.php create mode 100644 core/modules/taxonomy/tests/src/Kernel/Plugin/migrate/source/d7/TermTest.php diff --git a/core/MAINTAINERS.txt b/core/MAINTAINERS.txt index adc61a74c..0739fb092 100644 --- a/core/MAINTAINERS.txt +++ b/core/MAINTAINERS.txt @@ -123,7 +123,6 @@ Color - ? Comment -- Dick Olsson 'dixon_' https://www.drupal.org/u/dixon_ - Lee Rowlands 'larowlan' https://www.drupal.org/u/larowlan - Andrey Postnikov 'andypost' https://www.drupal.org/u/andypost diff --git a/core/includes/schema.inc b/core/includes/schema.inc index 4712d3be1..aa3984b91 100644 --- a/core/includes/schema.inc +++ b/core/includes/schema.inc @@ -74,7 +74,7 @@ function drupal_get_schema_versions($module) { * module is not installed. */ function drupal_get_installed_schema_version($module, $reset = FALSE, $array = FALSE) { - static $versions = array(); + $versions = &drupal_static(__FUNCTION__, array()); if ($reset) { $versions = array(); diff --git a/core/lib/Drupal.php b/core/lib/Drupal.php index 1e0da8eb8..258582991 100644 --- a/core/lib/Drupal.php +++ b/core/lib/Drupal.php @@ -81,7 +81,7 @@ class Drupal { /** * The current system version. */ - const VERSION = '8.2.4'; + const VERSION = '8.2.5'; /** * Core API compatibility. @@ -556,8 +556,7 @@ class Drupal { * Renders a link with a given link text and Url object. * * This method is a convenience wrapper for the link generator service's - * generate() method. For detailed documentation, see - * \Drupal\Core\Routing\LinkGeneratorInterface::generate(). + * generate() method. * * @param string $text * The link text for the anchor tag. diff --git a/core/lib/Drupal/Core/Render/Element/Date.php b/core/lib/Drupal/Core/Render/Element/Date.php index dcee06228..7a0801d9c 100644 --- a/core/lib/Drupal/Core/Render/Element/Date.php +++ b/core/lib/Drupal/Core/Render/Element/Date.php @@ -11,6 +11,7 @@ use Drupal\Core\Render\Element; * Properties: * - #default_value: An array with the keys: 'year', 'month', and 'day'. * Defaults to the current date if no value is supplied. + * - #size: The size of the input element in characters. * * @code * $form['expiration'] = array( diff --git a/core/lib/Drupal/Core/Render/Element/Email.php b/core/lib/Drupal/Core/Render/Element/Email.php index 4b4da7b04..247967667 100644 --- a/core/lib/Drupal/Core/Render/Element/Email.php +++ b/core/lib/Drupal/Core/Render/Element/Email.php @@ -10,6 +10,7 @@ use Drupal\Core\Render\Element; * * Properties: * - #default_value: An RFC-compliant email address. + * - #size: The size of the input element in characters. * * Example usage: * @code diff --git a/core/lib/Drupal/Core/Render/Element/Number.php b/core/lib/Drupal/Core/Render/Element/Number.php index b2fbb1125..788aa1e6c 100644 --- a/core/lib/Drupal/Core/Render/Element/Number.php +++ b/core/lib/Drupal/Core/Render/Element/Number.php @@ -16,6 +16,7 @@ use Drupal\Component\Utility\Number as NumberUtility; * - #step: Ensures that the number is an even multiple of step, offset by #min * if specified. A #min of 1 and a #step of 2 would allow values of 1, 3, 5, * etc. + * - #size: The size of the input element in characters. * * Usage example: * @code diff --git a/core/lib/Drupal/Core/Render/Element/Password.php b/core/lib/Drupal/Core/Render/Element/Password.php index e16e8bb43..06d5532e5 100644 --- a/core/lib/Drupal/Core/Render/Element/Password.php +++ b/core/lib/Drupal/Core/Render/Element/Password.php @@ -8,6 +8,9 @@ use Drupal\Core\Render\Element; /** * Provides a form element for entering a password, with hidden text. * + * Properties: + * - #size: The size of the input element in characters. + * * Usage example: * @code * $form['pass'] = array( diff --git a/core/lib/Drupal/Core/Render/Element/PasswordConfirm.php b/core/lib/Drupal/Core/Render/Element/PasswordConfirm.php index 98b65ed90..0d5e0e286 100644 --- a/core/lib/Drupal/Core/Render/Element/PasswordConfirm.php +++ b/core/lib/Drupal/Core/Render/Element/PasswordConfirm.php @@ -10,6 +10,9 @@ use Drupal\Core\Form\FormStateInterface; * Formats as a pair of password fields, which do not validate unless the two * entered passwords match. * + * Properties: + * - #size: The size of the input element in characters. + * * Usage example: * @code * $form['pass'] = array( diff --git a/core/lib/Drupal/Core/Render/Element/Select.php b/core/lib/Drupal/Core/Render/Element/Select.php index f78dfa9f1..b1e0f4ab6 100644 --- a/core/lib/Drupal/Core/Render/Element/Select.php +++ b/core/lib/Drupal/Core/Render/Element/Select.php @@ -14,8 +14,31 @@ use Drupal\Core\Render\Element; * list. If a value is an array, it will be rendered similarly, but as an * optgroup. The key of the sub-array will be used as the label for the * optgroup. Nesting optgroups is not allowed. - * - #empty_option: The label that will be displayed to denote no selection. - * - #empty_value: The value of the option that is used to denote no selection. + * - #empty_option: (optional) The label to show for the first default option. + * By default, the label is automatically set to "- Select -" for a required + * field and "- None -" for an optional field. + * - #empty_value: (optional) The value for the first default option, which is + * used to determine whether the user submitted a value or not. + * - If #required is TRUE, this defaults to '' (an empty string). + * - If #required is not TRUE and this value isn't set, then no extra option + * is added to the select control, leaving the control in a slightly + * illogical state, because there's no way for the user to select nothing, + * since all user agents automatically preselect the first available + * option. But people are used to this being the behavior of select + * controls. + * @todo Address the above issue in Drupal 8. + * - If #required is not TRUE and this value is set (most commonly to an + * empty string), then an extra option (see #empty_option above) + * representing a "non-selection" is added with this as its value. + * - #multiple: (optional) Indicates whether one or more options can be + * selected. Defaults to FALSE. + * - #default_value: Must be NULL or not set in case there is no value for the + * element yet, in which case a first default option is inserted by default. + * Whether this first option is a valid option depends on whether the field + * is #required or not. + * - #required: (optional) Whether the user needs to select an option (TRUE) + * or not (FALSE). Defaults to FALSE. + * - #size: The size of the input element in characters. * * Usage example: * @code @@ -66,31 +89,7 @@ class Select extends FormElement { * select lists. * * @param array $element - * The form element to process. Properties used: - * - #multiple: (optional) Indicates whether one or more options can be - * selected. Defaults to FALSE. - * - #default_value: Must be NULL or not set in case there is no value for the - * element yet, in which case a first default option is inserted by default. - * Whether this first option is a valid option depends on whether the field - * is #required or not. - * - #required: (optional) Whether the user needs to select an option (TRUE) - * or not (FALSE). Defaults to FALSE. - * - #empty_option: (optional) The label to show for the first default option. - * By default, the label is automatically set to "- Select -" for a required - * field and "- None -" for an optional field. - * - #empty_value: (optional) The value for the first default option, which is - * used to determine whether the user submitted a value or not. - * - If #required is TRUE, this defaults to '' (an empty string). - * - If #required is not TRUE and this value isn't set, then no extra option - * is added to the select control, leaving the control in a slightly - * illogical state, because there's no way for the user to select nothing, - * since all user agents automatically preselect the first available - * option. But people are used to this being the behavior of select - * controls. - * @todo Address the above issue in Drupal 8. - * - If #required is not TRUE and this value is set (most commonly to an - * empty string), then an extra option (see #empty_option above) - * representing a "non-selection" is added with this as its value. + * The form element to process. * @param \Drupal\Core\Form\FormStateInterface $form_state * The current state of the form. * @param array $complete_form diff --git a/core/lib/Drupal/Core/Render/Element/Table.php b/core/lib/Drupal/Core/Render/Element/Table.php index 75bcab554..298a27fa6 100644 --- a/core/lib/Drupal/Core/Render/Element/Table.php +++ b/core/lib/Drupal/Core/Render/Element/Table.php @@ -24,6 +24,7 @@ use Drupal\Component\Utility\Html as HtmlUtility; * providing responsive tables. Defaults to TRUE. * - #sticky: Indicates whether to add the drupal.tableheader library that makes * table headers always visible at the top of the page. Defaults to FALSE. + * - #size: The size of the input element in characters. * * Usage example: * @code diff --git a/core/lib/Drupal/Core/Render/Element/Tel.php b/core/lib/Drupal/Core/Render/Element/Tel.php index 02b071d5a..090939384 100644 --- a/core/lib/Drupal/Core/Render/Element/Tel.php +++ b/core/lib/Drupal/Core/Render/Element/Tel.php @@ -10,6 +10,9 @@ use Drupal\Core\Render\Element; * Provides an HTML5 input element with type of "tel". It provides no special * validation. * + * Properties: + * - #size: The size of the input element in characters. + * * Usage example: * @code * $form['phone'] = array( diff --git a/core/lib/Drupal/Core/Render/Element/Url.php b/core/lib/Drupal/Core/Render/Element/Url.php index 33d91ed1c..c66cadc63 100644 --- a/core/lib/Drupal/Core/Render/Element/Url.php +++ b/core/lib/Drupal/Core/Render/Element/Url.php @@ -11,6 +11,7 @@ use Drupal\Core\Render\Element; * * Properties: * - #default_value: A valid URL string. + * - #size: The size of the input element in characters. * * Usage example: * @code diff --git a/core/lib/Drupal/Core/Render/theme.api.php b/core/lib/Drupal/Core/Render/theme.api.php index 322761eee..0dd757322 100644 --- a/core/lib/Drupal/Core/Render/theme.api.php +++ b/core/lib/Drupal/Core/Render/theme.api.php @@ -254,13 +254,13 @@ * form array, which specifies the form elements for an HTML form; see the * @link form_api Form generation topic @endlink for more information on forms. * - * Render arrays (at each level in the hierarchy) will usually have one of the - * following three properties defined: + * Render arrays (at any level of the hierarchy) will usually have one of the + * following properties defined: * - #type: Specifies that the array contains data and options for a particular - * type of "render element" (examples: 'form', for an HTML form; 'textfield', - * 'submit', and other HTML form element types; 'table', for a table with - * rows, columns, and headers). See @ref elements below for more on render - * element types. + * type of "render element" (for example, 'form', for an HTML form; + * 'textfield', 'submit', for HTML form element types; 'table', for a table + * with rows, columns, and headers). See @ref elements below for more on + * render element types. * - #theme: Specifies that the array contains data to be themed by a particular * theme hook. Modules define theme hooks by implementing hook_theme(), which * specifies the input "variables" used to provide data and options; if a @@ -277,30 +277,29 @@ * can customize the markup. Note that the value is passed through * \Drupal\Component\Utility\Xss::filterAdmin(), which strips known XSS * vectors while allowing a permissive list of HTML tags that are not XSS - * vectors. (I.e,