diff --git a/core/modules/update/src/Form/UpdateManagerUpdate.php b/core/modules/update/src/Form/UpdateManagerUpdate.php index c42928e8d2..6915cf3f92 100644 --- a/core/modules/update/src/Form/UpdateManagerUpdate.php +++ b/core/modules/update/src/Form/UpdateManagerUpdate.php @@ -8,6 +8,7 @@ use Drupal\Core\Link; use Drupal\Core\State\StateInterface; use Drupal\Core\Url; +use Drupal\update\ModuleVersionParser; use Symfony\Component\DependencyInjection\ContainerInterface; /** @@ -133,7 +134,8 @@ public function buildForm(array $form, FormStateInterface $form_state) { $recommended_release = $project['releases'][$project['recommended']]; $recommended_version = '{{ release_version }} ({{ release_notes }})'; - if ($recommended_release['version_major'] != $project['existing_major']) { + $recommended_version_parser = new ModuleVersionParser($recommended_release['version']); + if ($recommended_version_parser->getMajorVersion() != $project['existing_major']) { $recommended_version .= '
{{ major_update_warning_text }}
'; } diff --git a/core/modules/update/src/ModuleVersionParser.php b/core/modules/update/src/ModuleVersionParser.php new file mode 100644 index 0000000000..ff2cbef1d9 --- /dev/null +++ b/core/modules/update/src/ModuleVersionParser.php @@ -0,0 +1,100 @@ +version = $version; + } + + /** + * Gets the major version. + * + * @return string + * The major version. + */ + public function getMajorVersion() { + return explode('.', $this->getVersionString())[0]; + } + + /** + * Gets the minor version. + * + * @return string|null + * The minor version if available otherwise NULL. + */ + public function getMinorVersion() { + $version_parts = explode('.', $this->getVersionString()); + return count($version_parts) === 2 ? NULL : $version_parts[1]; + } + + /** + * Gets the patch version. + * + * @return string + * The patch version. + */ + public function getPatchVersion() { + $version_parts = explode('.', $this->getVersionString()); + $last_version_part = count($version_parts) === 2 ? $version_parts[1] : $version_parts[2]; + return explode('-', $last_version_part)[0]; + } + + /** + * Gets the version string. + * + * @return string + * The version string. + */ + private function getVersionString() { + $original_version = $this->version; + $version = strpos($original_version, '8.x-') === 0 ? str_replace('8.x-', '', $original_version) : $original_version; + return $version; + } + + /** + * Gets the version extra string at the end of the version number. + * + * @return string|null + * The version extra string if available otherwise NULL. + */ + public function getVersionExtra() { + $version_parts = explode('.', $this->getVersionString()); + $last_version_parts = explode('-', count($version_parts) === 2 ? $version_parts[1] : $version_parts[2]); + return count($last_version_parts) === 1 ? NULL : $last_version_parts[1]; + } + + /** + * Gets the support branch. + * + * @return string + * The support branch as is used in update XML files. + */ + public function getSupportBranch() { + $version = $this->version; + if ($extra = $this->getVersionExtra()) { + $version = str_replace("-$extra", '', $version); + } + $parts = explode('.', $version); + array_pop($parts); + return implode('.', $parts) . '.'; + } + +} diff --git a/core/modules/update/src/UpdateFetcher.php b/core/modules/update/src/UpdateFetcher.php index 2b03c9c101..05cce763a6 100644 --- a/core/modules/update/src/UpdateFetcher.php +++ b/core/modules/update/src/UpdateFetcher.php @@ -77,7 +77,7 @@ public function fetchProjectData(array $project, $site_key = '') { public function buildFetchUrl(array $project, $site_key = '') { $name = $project['name']; $url = $this->getFetchBaseUrl($project); - $url .= '/' . $name . '/' . \Drupal::CORE_COMPATIBILITY; + $url .= '/' . $name . '/current'; // Only append usage information if we have a site key and the project is // enabled. We do not want to record usage statistics for disabled projects. diff --git a/core/modules/update/tests/modules/update_test/aaa_update_test.1_0.xml b/core/modules/update/tests/modules/update_test/aaa_update_test.1_0.xml index 82362fe846..55234d6b5f 100644 --- a/core/modules/update/tests/modules/update_test/aaa_update_test.1_0.xml +++ b/core/modules/update/tests/modules/update_test/aaa_update_test.1_0.xml @@ -4,8 +4,8 @@ aaa_update_test Drupal 8.x -1 -1 +8.x-1. +8.x-1. 1 published http://example.com/project/aaa_update_test @@ -17,8 +17,6 @@ aaa_update_test 8.x-1.0 8.x-1.0 DRUPAL-8--1-0 - 1 - 0 published http://example.com/aaa_update_test-8-x-1-0-release http://example.com/aaa_update_test-8.x-1.0.tar.gz diff --git a/core/modules/update/tests/modules/update_test/aaa_update_test.sec.8.x-1.1_8.x-1.2.xml b/core/modules/update/tests/modules/update_test/aaa_update_test.sec.8.x-1.1_8.x-1.2.xml index 560c82bf05..4757b868e8 100644 --- a/core/modules/update/tests/modules/update_test/aaa_update_test.sec.8.x-1.1_8.x-1.2.xml +++ b/core/modules/update/tests/modules/update_test/aaa_update_test.sec.8.x-1.1_8.x-1.2.xml @@ -4,8 +4,8 @@ aaa_update_test Drupal 8.x - 1 - 1 + 8.x-1. + 8.x-1. 1 published http://example.com/project/aaa_update_test @@ -17,8 +17,6 @@ aaa_update_test 8.x-1.2 8.x-1.2 DRUPAL-8--1-2 - 1 - 2 published http://example.com/aaa_update_test-8-x-1-2-release http://example.com/aaa_update_test-8-x-1-2.tar.gz @@ -35,8 +33,6 @@ aaa_update_test 8.x-1.1 8.x-1.1 DRUPAL-8--1-1 - 1 - 1 published http://example.com/aaa_update_test-8-x-1-1-release http://example.com/aaa_update_test-8-x-1-1.tar.gz @@ -54,8 +50,6 @@ aaa_update_test 8.x-1.0 8.x-1.0 DRUPAL-8--1-0 - 1 - 0 published http://example.com/aaa_update_test-8-x-1-0-release http://example.com/aaa_update_test-8-x-1-0.tar.gz diff --git a/core/modules/update/tests/modules/update_test/aaa_update_test.sec.8.x-1.2.xml b/core/modules/update/tests/modules/update_test/aaa_update_test.sec.8.x-1.2.xml index 0ebb766dd2..cc16345b97 100644 --- a/core/modules/update/tests/modules/update_test/aaa_update_test.sec.8.x-1.2.xml +++ b/core/modules/update/tests/modules/update_test/aaa_update_test.sec.8.x-1.2.xml @@ -4,8 +4,8 @@ aaa_update_test Drupal 8.x - 1 - 1 + 8.x-1. + 8.x-1. 1 published http://example.com/project/aaa_update_test @@ -17,8 +17,6 @@ aaa_update_test 8.x-1.2 8.x-1.2 DRUPAL-8--1-2 - 1 - 2 published http://example.com/aaa_update_test-8-x-1-2-release http://example.com/aaa_update_test-8-x-1-2.tar.gz @@ -35,8 +33,6 @@ aaa_update_test 8.x-1.1 8.x-1.1 DRUPAL-8--1-1 - 1 - 1 published http://example.com/aaa_update_test-8-x-1-1-release http://example.com/aaa_update_test-8-x-1-1.tar.gz @@ -53,8 +49,6 @@ aaa_update_test 8.x-1.0 8.x-1.0 DRUPAL-8--1-0 - 1 - 0 published http://example.com/aaa_update_test-8-x-1-0-release http://example.com/aaa_update_test-8-x-1-0.tar.gz diff --git a/core/modules/update/tests/modules/update_test/aaa_update_test.sec.8.x-1.2_8.x-2.2.xml b/core/modules/update/tests/modules/update_test/aaa_update_test.sec.8.x-1.2_8.x-2.2.xml index ee5265901a..df41223f2d 100644 --- a/core/modules/update/tests/modules/update_test/aaa_update_test.sec.8.x-1.2_8.x-2.2.xml +++ b/core/modules/update/tests/modules/update_test/aaa_update_test.sec.8.x-1.2_8.x-2.2.xml @@ -4,8 +4,8 @@ aaa_update_test Drupal 8.x - 2 - 1,2 + 8.x-2. + 8.x-1.,8.x-2. 2 published http://example.com/project/aaa_update_test @@ -17,9 +17,6 @@ aaa_update_test 8.x-3.0-beta2 8.x-3.0-beta2 8.x-3.0-beta2 - 3 - 0 - beta2 published http://example.com/aaa_update_test-8-x-3-0-beta2-release http://example.com/aaa_update_test-8-x-3-0-beta2.tar.gz @@ -38,9 +35,6 @@ aaa_update_test 8.x-3.0-beta1 8.x-3.0-beta1 8.x-3.0-beta1 - 3 - 0 - beta1 published http://example.com/aaa_update_test-8-x-3-0-beta1 http://example.com/aaa_update_test--8-x-3-0-beta1.tar.gz @@ -60,8 +54,6 @@ aaa_update_test 8.x-2.2 8.x-2.2 DRUPAL-8--2-2 - 2 - 2 published http://example.com/aaa_update_test-8-x-2-2-release http://example.com/aaa_update_test-8-x-2-2.tar.gz @@ -78,8 +70,6 @@ aaa_update_test 8.x-2.1 8.x-2.1 DRUPAL-8--2-1 - 2 - 1 published http://example.com/aaa_update_test-8-x-2-1-release http://example.com/aaa_update_test-8-x-2-1.tar.gz @@ -97,8 +87,6 @@ aaa_update_test 8.x-2.0 8.x-2.0 DRUPAL-8--2-0 - 2 - 0 published http://example.com/aaa_update_test-8-x-2-0-release http://example.com/aaa_update_test-8-x-2-0.tar.gz @@ -115,8 +103,6 @@ aaa_update_test 8.x-1.2 8.x-1.2 DRUPAL-8--1-2 - 1 - 2 published http://example.com/aaa_update_test-8-x-1-2-release http://example.com/aaa_update_test-8-x-1-2.tar.gz @@ -133,8 +119,6 @@ aaa_update_test 8.x-1.1 8.x-1.1 DRUPAL-8--1-1 - 1 - 1 published http://example.com/aaa_update_test-8-x-1-1-release http://example.com/aaa_update_test-8-x-1-1.tar.gz @@ -151,8 +135,6 @@ aaa_update_test 8.x-1.0 8.x-1.0 DRUPAL-8--1-0 - 1 - 0 published http://example.com/aaa_update_test-8-x-1-0-release http://example.com/aaa_update_test-8-x-1-0.tar.gz diff --git a/core/modules/update/tests/modules/update_test/aaa_update_test.sec.8.x-2.2_1.x_secure.xml b/core/modules/update/tests/modules/update_test/aaa_update_test.sec.8.x-2.2_1.x_secure.xml index a42b58d5c5..9ac3eda36f 100644 --- a/core/modules/update/tests/modules/update_test/aaa_update_test.sec.8.x-2.2_1.x_secure.xml +++ b/core/modules/update/tests/modules/update_test/aaa_update_test.sec.8.x-2.2_1.x_secure.xml @@ -4,8 +4,8 @@ aaa_update_test Drupal 8.x - 2 - 1,2 + 8.x-2. + 8.x-1.,8.x-2. 2 published http://example.com/project/aaa_update_test @@ -17,8 +17,6 @@ aaa_update_test 8.x-2.2 8.x-2.2 DRUPAL-8--2-2 - 2 - 2 published http://example.com/aaa_update_test-8-x-2-2-release http://example.com/aaa_update_test-8-x-2-2.tar.gz @@ -35,8 +33,6 @@ aaa_update_test 8.x-2.1 8.x-2.1 DRUPAL-8--2-1 - 2 - 1 published http://example.com/aaa_update_test-8-x-2-1-release http://example.com/aaa_update_test-8-x-2-1.tar.gz @@ -54,8 +50,6 @@ aaa_update_test 8.x-2.0 8.x-2.0 DRUPAL-8--2-0 - 2 - 0 published http://example.com/aaa_update_test-8-x-2-0-release http://example.com/aaa_update_test-8-x-2-0.tar.gz @@ -72,8 +66,6 @@ aaa_update_test 8.x-1.2 8.x-1.2 DRUPAL-8--1-2 - 1 - 2 published http://example.com/aaa_update_test-8-x-1-2-release http://example.com/aaa_update_test-8-x-1-2.tar.gz @@ -89,8 +81,6 @@ aaa_update_test 8.x-1.1 8.x-1.1 DRUPAL-8--1-1 - 1 - 1 published http://example.com/aaa_update_test-8-x-1-1-release http://example.com/aaa_update_test-8-x-1-1.tar.gz @@ -106,8 +96,6 @@ aaa_update_test 8.x-1.0 8.x-1.0 DRUPAL-8--1-0 - 1 - 0 published http://example.com/aaa_update_test-8-x-1-0-release http://example.com/aaa_update_test-8-x-1-0.tar.gz diff --git a/core/modules/update/tests/modules/update_test/bbb_update_test.1_0.xml b/core/modules/update/tests/modules/update_test/bbb_update_test.1_0.xml index 8d705b5f96..be70b85b58 100644 --- a/core/modules/update/tests/modules/update_test/bbb_update_test.1_0.xml +++ b/core/modules/update/tests/modules/update_test/bbb_update_test.1_0.xml @@ -4,8 +4,8 @@ bbb_update_test Drupal 8.x -1 -1 +8.x-1. +8.x-1. 1 published http://example.com/project/bbb_update_test @@ -17,8 +17,6 @@ bbb_update_test 8.x-1.0 8.x-1.0 DRUPAL-7--1-0 - 1 - 0 published http://example.com/bbb_update_test-7-x-1-0-release http://example.com/bbb_update_test-8.x-1.0.tar.gz diff --git a/core/modules/update/tests/modules/update_test/ccc_update_test.1_0.xml b/core/modules/update/tests/modules/update_test/ccc_update_test.1_0.xml index 82764c2c33..35b3976b04 100644 --- a/core/modules/update/tests/modules/update_test/ccc_update_test.1_0.xml +++ b/core/modules/update/tests/modules/update_test/ccc_update_test.1_0.xml @@ -4,8 +4,8 @@ ccc_update_test Drupal 8.x -1 -1 +8.x-1. +8.x-1. 1 published http://example.com/project/ccc_update_test @@ -17,8 +17,6 @@ ccc_update_test 8.x-1.0 8.x-1.0 DRUPAL-7--1-0 - 1 - 0 published http://example.com/ccc_update_test-7-x-1-0-release http://example.com/ccc_update_test-8.x-1.0.tar.gz diff --git a/core/modules/update/tests/modules/update_test/drupal.0.0-alpha1.xml b/core/modules/update/tests/modules/update_test/drupal.0.0-alpha1.xml index e463b72e3d..fbd3f3dadd 100644 --- a/core/modules/update/tests/modules/update_test/drupal.0.0-alpha1.xml +++ b/core/modules/update/tests/modules/update_test/drupal.0.0-alpha1.xml @@ -4,8 +4,8 @@ drupal Drupal 8.x -8 -8 +8.0. +8.0.,8.1. 8 published http://example.com/project/drupal @@ -17,10 +17,6 @@ Drupal 8.0.0-alpha1 8.0.0-alpha1 DRUPAL-8-0-0-alpha1 - 8 - 0 - 0 - alpha1 published http://example.com/drupal-8-0-0-alpha1-release http://example.com/drupal-8-0-0-alpha1.tar.gz diff --git a/core/modules/update/tests/modules/update_test/drupal.0.0-beta1.xml b/core/modules/update/tests/modules/update_test/drupal.0.0-beta1.xml index b3dc3bf2aa..5f3dfdde2b 100644 --- a/core/modules/update/tests/modules/update_test/drupal.0.0-beta1.xml +++ b/core/modules/update/tests/modules/update_test/drupal.0.0-beta1.xml @@ -4,8 +4,8 @@ drupal Drupal 8.x -8 -8 +8.0. +8.0.,8.1. 8 published http://example.com/project/drupal @@ -17,10 +17,6 @@ Drupal 8.0.0-beta1 8.0.0-beta1 DRUPAL-8-0-0-beta1 - 8 - 0 - 0 - beta1 published http://example.com/drupal-8-0-0-beta1-release http://example.com/drupal-8-0-0-beta1.tar.gz @@ -36,10 +32,6 @@ Drupal 8.0.0-alpha1 8.0.0-alpha1 DRUPAL-8-0-0-alpha1 - 8 - 0 - 0 - alpha1 published http://example.com/drupal-8-0-0-alpha1-release http://example.com/drupal-8-0-0-alpha1.tar.gz diff --git a/core/modules/update/tests/modules/update_test/drupal.0.0.xml b/core/modules/update/tests/modules/update_test/drupal.0.0.xml index ac450660d5..a480482f20 100644 --- a/core/modules/update/tests/modules/update_test/drupal.0.0.xml +++ b/core/modules/update/tests/modules/update_test/drupal.0.0.xml @@ -4,8 +4,8 @@ drupal Drupal 8.x -8 -8 +8.0. +8.0.,8.1. 8 published http://example.com/project/drupal @@ -17,9 +17,6 @@ Drupal 8.0.0 8.0.0 DRUPAL-8-0-0 - 8 - 0 - 0 published http://example.com/drupal-8-0-0-release http://example.com/drupal-8-0-0.tar.gz @@ -35,10 +32,6 @@ Drupal 8.0.0-beta1 8.0.0-beta1 DRUPAL-8-0-0-beta1 - 8 - 0 - 0 - beta1 published http://example.com/drupal-8-0-0-beta1-release http://example.com/drupal-8-0-0-beta1.tar.gz @@ -54,10 +47,6 @@ Drupal 8.0.0-alpha1 8.0.0-alpha1 DRUPAL-8-0-0-alpha1 - 8 - 0 - 0 - alpha1 published http://example.com/drupal-8-0-0-alpha1-release http://example.com/drupal-8-0-0-alpha1.tar.gz diff --git a/core/modules/update/tests/modules/update_test/drupal.0.1-alpha1.xml b/core/modules/update/tests/modules/update_test/drupal.0.1-alpha1.xml index 150136c67d..8d227e1eb2 100644 --- a/core/modules/update/tests/modules/update_test/drupal.0.1-alpha1.xml +++ b/core/modules/update/tests/modules/update_test/drupal.0.1-alpha1.xml @@ -4,8 +4,8 @@ drupal Drupal 8.x -8 -8 +8.0. +8.0.,8.1. 8 published http://example.com/project/drupal @@ -17,10 +17,6 @@ Drupal 8.0.1-alpha1 8.0.1-alpha1 DRUPAL-8-0-1-alpha1 - 8 - 0 - 1 - alpha1 published http://example.com/drupal-8-0-1-alpha1-release http://example.com/drupal-8-0-1-alpha1.tar.gz @@ -36,9 +32,6 @@ Drupal 8.0.0 8.0.0 DRUPAL-8-0-0 - 8 - 0 - 0 published http://example.com/drupal-8-0-0-release http://example.com/drupal-8-0-0.tar.gz @@ -54,10 +47,6 @@ Drupal 8.0.0-beta1 8.0.0-beta1 DRUPAL-8-0-0-beta1 - 8 - 0 - 0 - beta1 published http://example.com/drupal-8-0-0-beta1-release http://example.com/drupal-8-0-0-beta1.tar.gz @@ -73,10 +62,6 @@ Drupal 8.0.0-alpha1 8.0.0-alpha1 DRUPAL-8-0-0-alpha1 - 8 - 0 - 0 - alpha1 published http://example.com/drupal-8-0-0-alpha1-release http://example.com/drupal-8-0-0-alpha1.tar.gz diff --git a/core/modules/update/tests/modules/update_test/drupal.0.1-beta1.xml b/core/modules/update/tests/modules/update_test/drupal.0.1-beta1.xml index 25c9f7023e..55f4f32cbb 100644 --- a/core/modules/update/tests/modules/update_test/drupal.0.1-beta1.xml +++ b/core/modules/update/tests/modules/update_test/drupal.0.1-beta1.xml @@ -4,8 +4,8 @@ drupal Drupal 8.x -8 -8 +8.0. +8.0.,8.1. 8 published http://example.com/project/drupal @@ -17,10 +17,6 @@ Drupal 8.0.1-beta1 8.0.1-beta1 DRUPAL-8-0-1-beta1 - 8 - 0 - 1 - beta1 published http://example.com/drupal-8-0-1-beta1-release http://example.com/drupal-8-0-1-beta1.tar.gz @@ -36,10 +32,6 @@ Drupal 8.0.1-alpha1 8.0.1-alpha1 DRUPAL-8-0-1-alpha1 - 8 - 0 - 1 - alpha1 published http://example.com/drupal-8-0-1-alpha1-release http://example.com/drupal-8-0-1-alpha1.tar.gz @@ -55,9 +47,6 @@ Drupal 8.0.0 8.0.0 DRUPAL-8-0-0 - 8 - 0 - 0 published http://example.com/drupal-8-0-0-release http://example.com/drupal-8-0-0.tar.gz @@ -73,10 +62,6 @@ Drupal 8.0.0-beta1 8.0.0-beta1 DRUPAL-8-0-0-beta1 - 8 - 0 - 0 - beta1 published http://example.com/drupal-8-0-0-beta1-release http://example.com/drupal-8-0-0-beta1.tar.gz @@ -92,10 +77,6 @@ Drupal 8.0.0-alpha1 8.0.0-alpha1 DRUPAL-8-0-0-alpha1 - 8 - 0 - 0 - alpha1 published http://example.com/drupal-8-0-0-alpha1-release http://example.com/drupal-8-0-0-alpha1.tar.gz diff --git a/core/modules/update/tests/modules/update_test/drupal.0.1.xml b/core/modules/update/tests/modules/update_test/drupal.0.1.xml index ea00c15c90..8ae882cdb4 100644 --- a/core/modules/update/tests/modules/update_test/drupal.0.1.xml +++ b/core/modules/update/tests/modules/update_test/drupal.0.1.xml @@ -4,8 +4,8 @@ drupal Drupal 8.x -8 -8 +8.0. +8.0.,8.1. 8 published http://example.com/project/drupal @@ -17,9 +17,6 @@ Drupal 8.0.1 8.0.1 DRUPAL-8-0-1 - 8 - 0 - 1 published http://example.com/drupal-8-0-1-release http://example.com/drupal-8-0-1.tar.gz @@ -35,10 +32,6 @@ Drupal 8.0.1-beta1 8.0.1-beta1 DRUPAL-8-0-1-beta1 - 8 - 0 - 1 - beta1 published http://example.com/drupal-8-0-1-beta1-release http://example.com/drupal-8-0-1-beta1.tar.gz @@ -54,10 +47,6 @@ Drupal 8.0.1-alpha1 8.0.1-alpha1 DRUPAL-8-0-1-alpha1 - 8 - 0 - 1 - alpha1 published http://example.com/drupal-8-0-1-alpha1-release http://example.com/drupal-8-0-1-alpha1.tar.gz @@ -73,9 +62,6 @@ Drupal 8.0.0 8.0.0 DRUPAL-8-0-0 - 8 - 0 - 0 published http://example.com/drupal-8-0-0-release http://example.com/drupal-8-0-0.tar.gz @@ -91,10 +77,6 @@ Drupal 8.0.0-beta1 8.0.0-beta1 DRUPAL-8-0-0-beta1 - 8 - 0 - 0 - beta1 published http://example.com/drupal-8-0-0-beta1-release http://example.com/drupal-8-0-0-beta1.tar.gz @@ -110,10 +92,6 @@ Drupal 8.0.0-alpha1 8.0.0-alpha1 DRUPAL-8-0-0-alpha1 - 8 - 0 - 0 - alpha1 published http://example.com/drupal-8-0-0-alpha1-release http://example.com/drupal-8-0-0-alpha1.tar.gz diff --git a/core/modules/update/tests/modules/update_test/drupal.1.0-alpha1.xml b/core/modules/update/tests/modules/update_test/drupal.1.0-alpha1.xml index fe734a844b..74de5411f2 100644 --- a/core/modules/update/tests/modules/update_test/drupal.1.0-alpha1.xml +++ b/core/modules/update/tests/modules/update_test/drupal.1.0-alpha1.xml @@ -4,8 +4,8 @@ drupal Drupal 8.x -8 -8 +8.0. +8.0.,8.1. 8 published http://example.com/project/drupal @@ -17,10 +17,6 @@ Drupal 8.1.0-alpha1 8.1.0-alpha1 DRUPAL-8-1-0-alpha1 - 8 - 1 - 0 - alpha1 published http://example.com/drupal-8-1-0-alpha1-release http://example.com/drupal-8-1-0-alpha1.tar.gz @@ -36,9 +32,6 @@ Drupal 8.0.1 8.0.1 DRUPAL-8-0-1 - 8 - 0 - 1 published http://example.com/drupal-8-0-1-release http://example.com/drupal-8-0-1.tar.gz @@ -54,10 +47,6 @@ Drupal 8.0.1-beta1 8.0.1-beta1 DRUPAL-8-0-1-beta1 - 8 - 0 - 1 - beta1 published http://example.com/drupal-8-0-1-beta1-release http://example.com/drupal-8-0-1-beta1.tar.gz @@ -73,10 +62,6 @@ Drupal 8.0.1-alpha1 8.0.1-alpha1 DRUPAL-8-0-1-alpha1 - 8 - 0 - 1 - alpha1 published http://example.com/drupal-8-0-1-alpha1-release http://example.com/drupal-8-0-1-alpha1.tar.gz @@ -92,9 +77,6 @@ Drupal 8.0.0 8.0.0 DRUPAL-8-0-0 - 8 - 0 - 0 published http://example.com/drupal-8-0-0-release http://example.com/drupal-8-0-0.tar.gz @@ -110,10 +92,6 @@ Drupal 8.0.0-beta1 8.0.0-beta1 DRUPAL-8-0-0-beta1 - 8 - 0 - 0 - beta1 published http://example.com/drupal-8-0-0-beta1-release http://example.com/drupal-8-0-0-beta1.tar.gz @@ -129,10 +107,6 @@ Drupal 8.0.0-alpha1 8.0.0-alpha1 DRUPAL-8-0-0-alpha1 - 8 - 0 - 0 - alpha1 published http://example.com/drupal-8-0-0-alpha1-release http://example.com/drupal-8-0-0-alpha1.tar.gz diff --git a/core/modules/update/tests/modules/update_test/drupal.1.0-beta1.xml b/core/modules/update/tests/modules/update_test/drupal.1.0-beta1.xml index fa65c5e92e..8f0177d903 100644 --- a/core/modules/update/tests/modules/update_test/drupal.1.0-beta1.xml +++ b/core/modules/update/tests/modules/update_test/drupal.1.0-beta1.xml @@ -4,8 +4,8 @@ drupal Drupal 8.x -8 -8 +8.0. +8.0.,8.1. 8 published http://example.com/project/drupal @@ -17,10 +17,6 @@ Drupal 8.1.0-beta1 8.1.0-beta1 DRUPAL-8-1-0-beta1 - 8 - 1 - 0 - beta1 published http://example.com/drupal-8-1-0-beta1-release http://example.com/drupal-8-1-0-beta1.tar.gz @@ -36,10 +32,6 @@ Drupal 8.1.0-alpha1 8.1.0-alpha1 DRUPAL-8-1-0-alpha1 - 8 - 1 - 0 - alpha1 published http://example.com/drupal-8-1-0-alpha1-release http://example.com/drupal-8-1-0-alpha1.tar.gz @@ -55,9 +47,6 @@ Drupal 8.0.1 8.0.1 DRUPAL-8-0-1 - 8 - 0 - 1 published http://example.com/drupal-8-0-1-release http://example.com/drupal-8-0-1.tar.gz @@ -73,10 +62,6 @@ Drupal 8.0.1-beta1 8.0.1-beta1 DRUPAL-8-0-1-beta1 - 8 - 0 - 1 - beta1 published http://example.com/drupal-8-0-1-beta1-release http://example.com/drupal-8-0-1-beta1.tar.gz @@ -92,10 +77,6 @@ Drupal 8.0.1-alpha1 8.0.1-alpha1 DRUPAL-8-0-1-alpha1 - 8 - 0 - 1 - alpha1 published http://example.com/drupal-8-0-1-alpha1-release http://example.com/drupal-8-0-1-alpha1.tar.gz @@ -111,9 +92,6 @@ Drupal 8.0.0 8.0.0 DRUPAL-8-0-0 - 8 - 0 - 0 published http://example.com/drupal-8-0-0-release http://example.com/drupal-8-0-0.tar.gz @@ -129,10 +107,6 @@ Drupal 8.0.0-beta1 8.0.0-beta1 DRUPAL-8-0-0-beta1 - 8 - 0 - 0 - beta1 published http://example.com/drupal-8-0-0-beta1-release http://example.com/drupal-8-0-0-beta1.tar.gz @@ -148,10 +122,6 @@ Drupal 8.0.0-alpha1 8.0.0-alpha1 DRUPAL-8-0-0-alpha1 - 8 - 0 - 0 - alpha1 published http://example.com/drupal-8-0-0-alpha1-release http://example.com/drupal-8-0-0-alpha1.tar.gz diff --git a/core/modules/update/tests/modules/update_test/drupal.1.0.xml b/core/modules/update/tests/modules/update_test/drupal.1.0.xml index 0e6a40c72c..c76319d57c 100644 --- a/core/modules/update/tests/modules/update_test/drupal.1.0.xml +++ b/core/modules/update/tests/modules/update_test/drupal.1.0.xml @@ -4,8 +4,8 @@ drupal Drupal 8.x -8 -8 +8.0. +8.0.,8.1. 8 published http://example.com/project/drupal @@ -17,9 +17,6 @@ Drupal 8.1.0 8.1.0 DRUPAL-8-1-0 - 8 - 1 - 0 published http://example.com/drupal-8-1-0-release http://example.com/drupal-8-1-0.tar.gz @@ -35,10 +32,6 @@ Drupal 8.1.0-beta1 8.1.0-beta1 DRUPAL-8-1-0-beta1 - 8 - 1 - 0 - beta1 published http://example.com/drupal-8-1-0-beta1-release http://example.com/drupal-8-1-0-beta1.tar.gz @@ -54,10 +47,6 @@ Drupal 8.1.0-alpha1 8.1.0-alpha1 DRUPAL-8-0-1-alpha1 - 8 - 1 - 0 - alpha1 published http://example.com/drupal-8-1-0-alpha1-release http://example.com/drupal-8-1-0-alpha1.tar.gz @@ -73,9 +62,6 @@ Drupal 8.0.1 8.0.1 DRUPAL-8-0-1 - 8 - 0 - 1 published http://example.com/drupal-8-0-1-release http://example.com/drupal-8-0-1.tar.gz @@ -91,10 +77,6 @@ Drupal 8.0.1-beta1 8.0.1-beta1 DRUPAL-8-0-1-beta1 - 8 - 0 - 1 - beta1 published http://example.com/drupal-8-0-1-beta1-release http://example.com/drupal-8-0-1-beta1.tar.gz @@ -110,10 +92,6 @@ Drupal 8.0.1-alpha1 8.0.1-alpha1 DRUPAL-8-0-1-alpha1 - 8 - 0 - 1 - alpha1 published http://example.com/drupal-8-0-1-alpha1-release http://example.com/drupal-8-0-1-alpha1.tar.gz @@ -129,9 +107,6 @@ Drupal 8.0.0 8.0.0 DRUPAL-8-0-0 - 8 - 0 - 0 published http://example.com/drupal-8-0-0-release http://example.com/drupal-8-0-0.tar.gz @@ -147,10 +122,6 @@ Drupal 8.0.0-beta1 8.0.0-beta1 DRUPAL-8-0-0-beta1 - 8 - 0 - 0 - beta1 published http://example.com/drupal-8-0-0-beta1-release http://example.com/drupal-8-0-0-beta1.tar.gz @@ -166,10 +137,6 @@ Drupal 8.0.0-alpha1 8.0.0-alpha1 DRUPAL-8-0-0-alpha1 - 8 - 0 - 0 - alpha1 published http://example.com/drupal-8-0-0-alpha1-release http://example.com/drupal-8-0-0-alpha1.tar.gz diff --git a/core/modules/update/tests/modules/update_test/drupal.1.1-alpha1.xml b/core/modules/update/tests/modules/update_test/drupal.1.1-alpha1.xml index 0356c8d978..c0952c905d 100644 --- a/core/modules/update/tests/modules/update_test/drupal.1.1-alpha1.xml +++ b/core/modules/update/tests/modules/update_test/drupal.1.1-alpha1.xml @@ -4,8 +4,8 @@ drupal Drupal 8.x -8 -8 +8.0. +8.0.,8.1. 8 published http://example.com/project/drupal @@ -17,10 +17,6 @@ Drupal 8.1.1-alpha1 8.1.1-alpha1 DRUPAL-8-1-1-alpha1 - 8 - 1 - 1 - alpha1 published http://example.com/drupal-8-1-1-alpha1-release http://example.com/drupal-8-1-1-alpha1.tar.gz @@ -36,9 +32,6 @@ Drupal 8.1.0 8.1.0 DRUPAL-8-1-0 - 8 - 1 - 0 published http://example.com/drupal-8-1-0-release http://example.com/drupal-8-1-0.tar.gz @@ -54,10 +47,6 @@ Drupal 8.1.0-beta1 8.1.0-beta1 DRUPAL-8-0-1-beta1 - 8 - 1 - 0 - beta1 published http://example.com/drupal-8-1-0-beta1-release http://example.com/drupal-8-1-0-beta1.tar.gz @@ -73,10 +62,6 @@ Drupal 8.1.0-alpha1 8.1.0-alpha1 DRUPAL-8-1-0-alpha1 - 8 - 1 - 0 - alpha1 published http://example.com/drupal-8-1-0-alpha1-release http://example.com/drupal-8-1-0-alpha1.tar.gz @@ -92,9 +77,6 @@ Drupal 8.0.1 8.0.1 DRUPAL-8-0-1 - 8 - 0 - 1 published http://example.com/drupal-8-0-1-release http://example.com/drupal-8-0-1.tar.gz @@ -110,10 +92,6 @@ Drupal 8.0.1-beta1 8.0.1-beta1 DRUPAL-8-0-1-beta1 - 8 - 0 - 1 - beta1 published http://example.com/drupal-8-0-1-beta1-release http://example.com/drupal-8-0-1-beta1.tar.gz @@ -129,10 +107,6 @@ Drupal 8.0.1-alpha1 8.0.1-alpha1 DRUPAL-8-0-1-alpha1 - 8 - 0 - 1 - alpha1 published http://example.com/drupal-8-0-1-alpha1-release http://example.com/drupal-8-0-1-alpha1.tar.gz @@ -148,9 +122,6 @@ Drupal 8.0.0 8.0.0 DRUPAL-8-0-0 - 8 - 0 - 0 published http://example.com/drupal-8-0-0-release http://example.com/drupal-8-0-0.tar.gz @@ -166,10 +137,6 @@ Drupal 8.0.0-beta1 8.0.0-beta1 DRUPAL-8-0-0-beta1 - 8 - 0 - 0 - beta1 published http://example.com/drupal-8-0-0-beta1-release http://example.com/drupal-8-0-0-beta1.tar.gz @@ -185,10 +152,6 @@ Drupal 8.0.0-alpha1 8.0.0-alpha1 DRUPAL-8-0-0-alpha1 - 8 - 0 - 0 - alpha1 published http://example.com/drupal-8-0-0-alpha1-release http://example.com/drupal-8-0-0-alpha1.tar.gz diff --git a/core/modules/update/tests/modules/update_test/drupal.1.1-beta1.xml b/core/modules/update/tests/modules/update_test/drupal.1.1-beta1.xml index abeef7ea41..e3a3264b7e 100644 --- a/core/modules/update/tests/modules/update_test/drupal.1.1-beta1.xml +++ b/core/modules/update/tests/modules/update_test/drupal.1.1-beta1.xml @@ -4,8 +4,8 @@ drupal Drupal 8.x -8 -8 +8.0. +8.0.,8.1. 8 published http://example.com/project/drupal @@ -17,10 +17,6 @@ Drupal 8.1.1-beta1 8.1.1-beta1 DRUPAL-8-1-1-beta1 - 8 - 1 - 1 - beta1 published http://example.com/drupal-8-1-1-beta1-release http://example.com/drupal-8-1-1-beta1.tar.gz @@ -36,10 +32,6 @@ Drupal 8.1.1-alpha1 8.1.1-alpha1 DRUPAL-8-1-1-alpha1 - 8 - 1 - 1 - alpha1 published http://example.com/drupal-8-1-1-alpha1-release http://example.com/drupal-8-1-1-alpha1.tar.gz @@ -55,9 +47,6 @@ Drupal 8.1.0 8.1.0 DRUPAL-8-1-0 - 8 - 1 - 0 published http://example.com/drupal-8-1-0-release http://example.com/drupal-8-1-0.tar.gz @@ -73,10 +62,6 @@ Drupal 8.1.0-beta1 8.1.0-beta1 DRUPAL-8-0-1-beta1 - 8 - 1 - 0 - beta1 published http://example.com/drupal-8-1-0-beta1-release http://example.com/drupal-8-1-0-beta1.tar.gz @@ -92,10 +77,6 @@ Drupal 8.1.0-alpha1 8.1.0-alpha1 DRUPAL-8-1-0-alpha1 - 8 - 1 - 0 - alpha1 published http://example.com/drupal-8-1-0-alpha1-release http://example.com/drupal-8-1-0-alpha1.tar.gz @@ -111,9 +92,6 @@ Drupal 8.0.1 8.0.1 DRUPAL-8-0-1 - 8 - 0 - 1 published http://example.com/drupal-8-0-1-release http://example.com/drupal-8-0-1.tar.gz @@ -129,10 +107,6 @@ Drupal 8.0.1-beta1 8.0.1-beta1 DRUPAL-8-0-1-beta1 - 8 - 0 - 1 - beta1 published http://example.com/drupal-8-0-1-beta1-release http://example.com/drupal-8-0-1-beta1.tar.gz @@ -148,10 +122,6 @@ Drupal 8.0.1-alpha1 8.0.1-alpha1 DRUPAL-8-0-1-alpha1 - 8 - 0 - 1 - alpha1 published http://example.com/drupal-8-0-1-alpha1-release http://example.com/drupal-8-0-1-alpha1.tar.gz @@ -167,9 +137,6 @@ Drupal 8.0.0 8.0.0 DRUPAL-8-0-0 - 8 - 0 - 0 published http://example.com/drupal-8-0-0-release http://example.com/drupal-8-0-0.tar.gz @@ -185,10 +152,6 @@ Drupal 8.0.0-beta1 8.0.0-beta1 DRUPAL-8-0-0-beta1 - 8 - 0 - 0 - beta1 published http://example.com/drupal-8-0-0-beta1-release http://example.com/drupal-8-0-0-beta1.tar.gz @@ -204,10 +167,6 @@ Drupal 8.0.0-alpha1 8.0.0-alpha1 DRUPAL-8-0-0-alpha1 - 8 - 0 - 0 - alpha1 published http://example.com/drupal-8-0-0-alpha1-release http://example.com/drupal-8-0-0-alpha1.tar.gz diff --git a/core/modules/update/tests/modules/update_test/drupal.1.1.xml b/core/modules/update/tests/modules/update_test/drupal.1.1.xml index a588bdc466..af0fb6ae78 100644 --- a/core/modules/update/tests/modules/update_test/drupal.1.1.xml +++ b/core/modules/update/tests/modules/update_test/drupal.1.1.xml @@ -4,8 +4,8 @@ drupal Drupal 8.x -8 -8 +8.0. +8.0.,8.1. 8 published http://example.com/project/drupal @@ -17,9 +17,6 @@ Drupal 8.1.1 8.1.1 DRUPAL-8-1-1 - 8 - 1 - 1 published http://example.com/drupal-8-1-1-release http://example.com/drupal-8-1-1.tar.gz @@ -35,10 +32,6 @@ Drupal 8.1.1-beta1 8.1.1-beta1 DRUPAL-8-1-1-beta1 - 8 - 1 - 1 - beta1 published http://example.com/drupal-8-1-1-beta1-release http://example.com/drupal-8-1-1-beta1.tar.gz @@ -54,10 +47,6 @@ Drupal 8.1.1-alpha1 8.1.1-alpha1 DRUPAL-8-1-1-alpha1 - 8 - 1 - 1 - alpha1 published http://example.com/drupal-8-1-1-alpha1-release http://example.com/drupal-8-1-1-alpha1.tar.gz @@ -73,9 +62,6 @@ Drupal 8.1.0 8.1.0 DRUPAL-8-1-0 - 8 - 1 - 0 published http://example.com/drupal-8-1-0-release http://example.com/drupal-8-1-0.tar.gz @@ -91,10 +77,6 @@ Drupal 8.1.0-beta1 8.1.0-beta1 DRUPAL-8-0-1-beta1 - 8 - 1 - 0 - beta1 published http://example.com/drupal-8-1-0-beta1-release http://example.com/drupal-8-1-0-beta1.tar.gz @@ -110,10 +92,6 @@ Drupal 8.1.0-alpha1 8.1.0-alpha1 DRUPAL-8-1-0-alpha1 - 8 - 1 - 0 - alpha1 published http://example.com/drupal-8-1-0-alpha1-release http://example.com/drupal-8-1-0-alpha1.tar.gz @@ -129,9 +107,6 @@ Drupal 8.0.1 8.0.1 DRUPAL-8-0-1 - 8 - 0 - 1 published http://example.com/drupal-8-0-1-release http://example.com/drupal-8-0-1.tar.gz @@ -147,10 +122,6 @@ Drupal 8.0.1-beta1 8.0.1-beta1 DRUPAL-8-0-1-beta1 - 8 - 0 - 1 - beta1 published http://example.com/drupal-8-0-1-beta1-release http://example.com/drupal-8-0-1-beta1.tar.gz @@ -166,10 +137,6 @@ Drupal 8.0.1-alpha1 8.0.1-alpha1 DRUPAL-8-0-1-alpha1 - 8 - 0 - 1 - alpha1 published http://example.com/drupal-8-0-1-alpha1-release http://example.com/drupal-8-0-1-alpha1.tar.gz @@ -185,9 +152,6 @@ Drupal 8.0.0 8.0.0 DRUPAL-8-0-0 - 8 - 0 - 0 published http://example.com/drupal-8-0-0-release http://example.com/drupal-8-0-0.tar.gz @@ -203,10 +167,6 @@ Drupal 8.0.0-beta1 8.0.0-beta1 DRUPAL-8-0-0-beta1 - 8 - 0 - 0 - beta1 published http://example.com/drupal-8-0-0-beta1-release http://example.com/drupal-8-0-0-beta1.tar.gz @@ -222,10 +182,6 @@ Drupal 8.0.0-alpha1 8.0.0-alpha1 DRUPAL-8-0-0-alpha1 - 8 - 0 - 0 - alpha1 published http://example.com/drupal-8-0-0-alpha1-release http://example.com/drupal-8-0-0-alpha1.tar.gz diff --git a/core/modules/update/tests/modules/update_test/drupal.9.xml b/core/modules/update/tests/modules/update_test/drupal.9.xml index c17b426a75..6b62d122a9 100644 --- a/core/modules/update/tests/modules/update_test/drupal.9.xml +++ b/core/modules/update/tests/modules/update_test/drupal.9.xml @@ -4,8 +4,8 @@ drupal Drupal 9.x -9 -9 +9.0. +9.0. 9 published http://example.com/project/drupal @@ -17,9 +17,6 @@ Drupal 9.0.0 9.0.0 DRUPAL-9-0-0 - 9 - 0 - 0 published http://example.com/drupal-9-0-0-release http://example.com/drupal-9-0-0.tar.gz diff --git a/core/modules/update/tests/modules/update_test/drupal.dev.xml b/core/modules/update/tests/modules/update_test/drupal.dev.xml index 4ab26bd2db..c53fd11289 100644 --- a/core/modules/update/tests/modules/update_test/drupal.dev.xml +++ b/core/modules/update/tests/modules/update_test/drupal.dev.xml @@ -4,8 +4,8 @@ drupal Drupal 8.x -8 -8 +8.0. +8.0.,8.1. 8 published http://example.com/project/drupal @@ -17,9 +17,6 @@ Drupal 8.0.0 8.0.0 DRUPAL-8-0-0 - 8 - 0 - 0 published http://example.com/drupal-8-0-0-release http://example.com/drupal-8-0-0.tar.gz @@ -35,9 +32,6 @@ Drupal 8.0.x-dev 8.0.x-dev DRUPAL-8-0 - 8 - 0 - dev published http://example.com/drupal-8-0-x-dev-release http://example.com/drupal-8.0.x-dev.tar.gz diff --git a/core/modules/update/tests/modules/update_test/drupal.sec.0.1_0.2.xml b/core/modules/update/tests/modules/update_test/drupal.sec.0.1_0.2.xml index ba954ae427..216c236ed3 100644 --- a/core/modules/update/tests/modules/update_test/drupal.sec.0.1_0.2.xml +++ b/core/modules/update/tests/modules/update_test/drupal.sec.0.1_0.2.xml @@ -4,8 +4,8 @@ drupal Drupal 8.x -8 -8 +8.0. +8.0.,8.1. 8 published http://example.com/project/drupal @@ -17,9 +17,6 @@ Drupal 8.0.2 8.0.2 DRUPAL-8-0-2 - 8 - 0 - 2 published http://example.com/drupal-8-0-2-release http://example.com/drupal-8-0-2.tar.gz @@ -36,9 +33,6 @@ Drupal 8.0.1 8.0.1 DRUPAL-8-0-1 - 8 - 0 - 1 published http://example.com/drupal-8-0-1-release http://example.com/drupal-8-0-1.tar.gz @@ -56,9 +50,6 @@ Drupal 8.0.0 8.0.0 DRUPAL-8-0-0 - 8 - 0 - 0 published http://example.com/drupal-8-0-0-release http://example.com/drupal-8-0-0.tar.gz diff --git a/core/modules/update/tests/modules/update_test/drupal.sec.0.2-rc2-b.xml b/core/modules/update/tests/modules/update_test/drupal.sec.0.2-rc2-b.xml index a971ca73eb..76eed9b1c5 100644 --- a/core/modules/update/tests/modules/update_test/drupal.sec.0.2-rc2-b.xml +++ b/core/modules/update/tests/modules/update_test/drupal.sec.0.2-rc2-b.xml @@ -4,8 +4,8 @@ drupal Drupal 8.x -8 -8 +8.0. +8.0.,8.1.,8.2. 8 published http://example.com/project/drupal @@ -17,10 +17,6 @@ drupal 8.2.0-rc2 8.2.0-rc2 8.2.0-rc2 - 8 - 2 - 0 - rc2 published http://example.com/drupal-8-2-0-rc2-release http://example.com/drupal-8-2-0-rc2.tar.gz @@ -39,10 +35,6 @@ drupal 8.2.0-rc1 8.2.0-rc1 8.2.0-rc1 - 8 - 2 - 0 - rc1 published http://example.com/drupal-8-2-0-rc1-release http://example.com/drupal-8-2-0-rc1.tar.gz @@ -61,10 +53,6 @@ drupal 8.2.0-beta2 8.2.0-beta2 8.2.0-beta2 - 8 - 2 - 0 - beta2 published http://example.com/drupal-8-2-0-beta2-release http://example.com/drupal-8-2-0-beta2.tar.gz @@ -83,10 +71,6 @@ drupal 8.2.0-beta1 8.2.0-beta1 8.2.0-beta1 - 8 - 2 - 0 - beta1 published http://example.com/drupal-8-2-0-beta1-release http://example.com/drupal-8-2-0-beta1.tar.gz @@ -105,10 +89,6 @@ drupal 8.2.0-alpha2 8.2.0-alpha2 8.2.0-alpha2 - 8 - 2 - 0 - alpha2 published http://example.com/drupal-8-2-0-alpha2-release http://example.com/drupal-8-2-0-alpha2.tar.gz @@ -127,10 +107,6 @@ drupal 8.2.0-alpha1 8.2.0-alpha1 8.2.0-alpha1 - 8 - 2 - 0 - alpha1 published http://example.com/drupal-8.2.0-alpha1 http://example.com/drupal-8-2-0-alpha1.tar.gz @@ -149,9 +125,6 @@ Drupal 8.1.2 8.1.2 DRUPAL-8-1-2 - 8 - 1 - 2 published http://example.com/drupal-8-1-2-release http://example.com/drupal-8-1-2.tar.gz @@ -168,9 +141,6 @@ Drupal 8.1.1 8.1.1 DRUPAL-8-1-1 - 8 - 1 - 1 published http://example.com/drupal-8-1-1-release http://example.com/drupal-8-1-1.tar.gz @@ -187,9 +157,6 @@ Drupal 8.1.0 8.1.0 DRUPAL-8-1-0 - 8 - 1 - 0 published http://example.com/drupal-8-1-0-release http://example.com/drupal-8-1-0.tar.gz @@ -206,9 +173,6 @@ Drupal 8.0.2 8.0.2 DRUPAL-8-0-2 - 8 - 0 - 2 published http://example.com/drupal-8-0-2-release http://example.com/drupal-8-0-2.tar.gz @@ -225,9 +189,6 @@ Drupal 8.0.1 8.0.1 DRUPAL-8-0-1 - 8 - 0 - 1 published http://example.com/drupal-8-0-1-release http://example.com/drupal-8-0-1.tar.gz @@ -244,9 +205,6 @@ Drupal 8.0.0 8.0.0 DRUPAL-8-0-0 - 8 - 0 - 0 published http://example.com/drupal-8-0-0-release http://example.com/drupal-8-0-0.tar.gz diff --git a/core/modules/update/tests/modules/update_test/drupal.sec.0.2-rc2.xml b/core/modules/update/tests/modules/update_test/drupal.sec.0.2-rc2.xml index bc422deb6f..06e6674323 100644 --- a/core/modules/update/tests/modules/update_test/drupal.sec.0.2-rc2.xml +++ b/core/modules/update/tests/modules/update_test/drupal.sec.0.2-rc2.xml @@ -4,8 +4,8 @@ drupal Drupal 8.x -8 -8 +8.0. +8.0.,8.1.,8.2. 8 published http://example.com/project/drupal @@ -17,10 +17,6 @@ drupal 8.2.0-rc2 8.2.0-rc2 8.2.0-rc2 - 8 - 2 - 0 - rc2 published http://example.com/drupal-8-2-0-rc2-release http://example.com/drupal-8-2-0-rc2.tar.gz @@ -40,10 +36,6 @@ drupal 8.2.0-rc1 8.2.0-rc1 8.2.0-rc1 - 8 - 2 - 0 - rc1 published http://example.com/drupal-8-2-0-rc1-release http://example.com/drupal-8-2-0-rc1.tar.gz @@ -63,10 +55,6 @@ drupal 8.2.0-beta2 8.2.0-beta2 8.2.0-beta2 - 8 - 2 - 0 - beta2 published http://example.com/drupal-8-2-0-beta2-release http://example.com/drupal-8-2-0-beta2.tar.gz @@ -86,10 +74,6 @@ drupal 8.2.0-beta1 8.2.0-beta1 8.2.0-beta1 - 8 - 2 - 0 - beta1 published http://example.com/drupal-8-2-0-beta1-release http://example.com/drupal-8-2-0-beta1.tar.gz @@ -109,10 +93,6 @@ drupal 8.2.0-alpha2 8.2.0-alpha2 8.2.0-alpha2 - 8 - 2 - 0 - alpha2 published http://example.com/drupal-8-2-0-alpha2-release http://example.com/drupal-8-2-0-alpha2.tar.gz @@ -132,10 +112,6 @@ drupal 8.2.0-alpha1 8.2.0-alpha1 8.2.0-alpha1 - 8 - 2 - 0 - alpha1 published http://example.com/drupal-8.2.0-alpha1 http://example.com/drupal-8-2-0-alpha1.tar.gz @@ -155,9 +131,6 @@ Drupal 8.1.2 8.1.2 DRUPAL-8-1-2 - 8 - 1 - 2 published http://example.com/drupal-8-1-2-release http://example.com/drupal-8-1-2.tar.gz @@ -174,9 +147,6 @@ Drupal 8.1.1 8.1.1 DRUPAL-8-1-1 - 8 - 1 - 1 published http://example.com/drupal-8-1-1-release http://example.com/drupal-8-1-1.tar.gz @@ -193,9 +163,6 @@ Drupal 8.1.0 8.1.0 DRUPAL-8-1-0 - 8 - 1 - 0 published http://example.com/drupal-8-1-0-release http://example.com/drupal-8-1-0.tar.gz @@ -212,9 +179,6 @@ Drupal 8.0.2 8.0.2 DRUPAL-8-0-2 - 8 - 0 - 2 published http://example.com/drupal-8-0-2-release http://example.com/drupal-8-0-2.tar.gz @@ -231,9 +195,6 @@ Drupal 8.0.1 8.0.1 DRUPAL-8-0-1 - 8 - 0 - 1 published http://example.com/drupal-8-0-1-release http://example.com/drupal-8-0-1.tar.gz @@ -250,9 +211,6 @@ Drupal 8.0.0 8.0.0 DRUPAL-8-0-0 - 8 - 0 - 0 published http://example.com/drupal-8-0-0-release http://example.com/drupal-8-0-0.tar.gz diff --git a/core/modules/update/tests/modules/update_test/drupal.sec.0.2.xml b/core/modules/update/tests/modules/update_test/drupal.sec.0.2.xml index 0b9bbce632..46dd668793 100644 --- a/core/modules/update/tests/modules/update_test/drupal.sec.0.2.xml +++ b/core/modules/update/tests/modules/update_test/drupal.sec.0.2.xml @@ -4,8 +4,8 @@ drupal Drupal 8.x -8 -8 +8.0. +8.0.,8.1. 8 published http://example.com/project/drupal @@ -17,9 +17,6 @@ Drupal 8.0.2 8.0.2 DRUPAL-8-0-2 - 8 - 0 - 2 published http://example.com/drupal-8-0-2-release http://example.com/drupal-8-0-2.tar.gz @@ -36,9 +33,6 @@ Drupal 8.0.1 8.0.1 DRUPAL-8-0-1 - 8 - 0 - 1 published http://example.com/drupal-8-0-1-release http://example.com/drupal-8-0-1.tar.gz @@ -55,9 +49,6 @@ Drupal 8.0.0 8.0.0 DRUPAL-8-0-0 - 8 - 0 - 0 published http://example.com/drupal-8-0-0-release http://example.com/drupal-8-0-0.tar.gz diff --git a/core/modules/update/tests/modules/update_test/drupal.sec.1.2.xml b/core/modules/update/tests/modules/update_test/drupal.sec.1.2.xml index 8665e46b36..ae2a2b07a4 100644 --- a/core/modules/update/tests/modules/update_test/drupal.sec.1.2.xml +++ b/core/modules/update/tests/modules/update_test/drupal.sec.1.2.xml @@ -4,8 +4,8 @@ drupal Drupal 8.x -8 -8 +8.0. +8.0.,8.1. 8 published http://example.com/project/drupal @@ -17,9 +17,6 @@ Drupal 8.1.2 8.1.2 DRUPAL-8-1-2 - 8 - 1 - 2 published http://example.com/drupal-8-1-2-release http://example.com/drupal-8-1-2.tar.gz @@ -36,9 +33,6 @@ Drupal 8.1.1 8.1.1 DRUPAL-8-1-1 - 8 - 1 - 1 published http://example.com/drupal-8-1-1-release http://example.com/drupal-8-1-1.tar.gz @@ -55,9 +49,6 @@ Drupal 8.1.0 8.1.0 DRUPAL-8-1-0 - 8 - 1 - 0 published http://example.com/drupal-8-1-0-release http://example.com/drupal-8-1-0.tar.gz @@ -74,9 +65,6 @@ Drupal 8.0.2 8.0.2 DRUPAL-8-0-2 - 8 - 0 - 2 published http://example.com/drupal-8-0-2-release http://example.com/drupal-8-0-2.tar.gz @@ -92,9 +80,6 @@ Drupal 8.0.1 8.0.1 DRUPAL-8-0-1 - 8 - 0 - 1 published http://example.com/drupal-8-0-1-release http://example.com/drupal-8-0-1.tar.gz @@ -110,9 +95,6 @@ Drupal 8.0.0 8.0.0 DRUPAL-8-0-0 - 8 - 0 - 0 published http://example.com/drupal-8-0-0-release http://example.com/drupal-8-0-0.tar.gz diff --git a/core/modules/update/tests/modules/update_test/drupal.sec.1.2_insecure.xml b/core/modules/update/tests/modules/update_test/drupal.sec.1.2_insecure.xml index dadad421bc..d1cb15f376 100644 --- a/core/modules/update/tests/modules/update_test/drupal.sec.1.2_insecure.xml +++ b/core/modules/update/tests/modules/update_test/drupal.sec.1.2_insecure.xml @@ -4,8 +4,8 @@ drupal Drupal 8.x -8 -8 +8.0. +8.0.,8.1. 8 published http://example.com/project/drupal @@ -17,9 +17,6 @@ Drupal 8.1.2 8.1.2 DRUPAL-8-1-2 - 8 - 1 - 2 published http://example.com/drupal-8-1-2-release http://example.com/drupal-8-1-2.tar.gz @@ -36,9 +33,6 @@ Drupal 8.1.1 8.1.1 DRUPAL-8-1-1 - 8 - 1 - 1 published http://example.com/drupal-8-1-1-release http://example.com/drupal-8-1-1.tar.gz @@ -55,9 +49,6 @@ Drupal 8.1.0 8.1.0 DRUPAL-8-1-0 - 8 - 1 - 0 published http://example.com/drupal-8-1-0-release http://example.com/drupal-8-1-0.tar.gz @@ -74,9 +65,6 @@ Drupal 8.0.2 8.0.2 DRUPAL-8-0-2 - 8 - 0 - 2 published http://example.com/drupal-8-0-2-release http://example.com/drupal-8-0-2.tar.gz @@ -93,9 +81,6 @@ Drupal 8.0.1 8.0.1 DRUPAL-8-0-1 - 8 - 0 - 1 published http://example.com/drupal-8-0-1-release http://example.com/drupal-8-0-1.tar.gz @@ -112,9 +97,6 @@ Drupal 8.0.0 8.0.0 DRUPAL-8-0-0 - 8 - 0 - 0 published http://example.com/drupal-8-0-0-release http://example.com/drupal-8-0-0.tar.gz diff --git a/core/modules/update/tests/modules/update_test/update_test_basetheme.1_1-sec.xml b/core/modules/update/tests/modules/update_test/update_test_basetheme.1_1-sec.xml index 3529e19763..43ea623454 100644 --- a/core/modules/update/tests/modules/update_test/update_test_basetheme.1_1-sec.xml +++ b/core/modules/update/tests/modules/update_test/update_test_basetheme.1_1-sec.xml @@ -4,8 +4,8 @@ update_test_basetheme Drupal 8.x -1 -1 +8.x-1. +8.x-1. 1 published http://example.com/project/update_test_basetheme @@ -17,8 +17,6 @@ update_test_basetheme 8.x-1.1 8.x-1.1 DRUPAL-7--1-1 - 1 - 1 published http://example.com/update_test_basetheme-7-x-1-1-release http://example.com/update_test_basetheme-8.x-1.1.tar.gz @@ -35,8 +33,6 @@ update_test_basetheme 8.x-1.0 8.x-1.0 DRUPAL-7--1-0 - 1 - 0 published http://example.com/update_test_basetheme-7-x-1-0-release http://example.com/update_test_basetheme-8.x-1.0.tar.gz diff --git a/core/modules/update/tests/modules/update_test/update_test_new_module.1_1.xml b/core/modules/update/tests/modules/update_test/update_test_new_module.1_1.xml index f9039b2e3f..58f8247168 100644 --- a/core/modules/update/tests/modules/update_test/update_test_new_module.1_1.xml +++ b/core/modules/update/tests/modules/update_test/update_test_new_module.1_1.xml @@ -4,8 +4,8 @@ update_test_new_module Drupal 8.x -1 -1 +8.x-1. +8.x-1. 1 published http://example.com/project/update_test_new_module @@ -17,8 +17,6 @@ update_test_new_module 8.x-1.1 8.x-1.1 DRUPAL-8--1-1 - 1 - 1 published http://example.com/update_test_new_module-8-x-1-1-release core/modules/update/tests/update_test_new_module/8.x-1.1/update_test_new_module.tar.gz diff --git a/core/modules/update/tests/modules/update_test/update_test_subtheme.1_0.xml b/core/modules/update/tests/modules/update_test/update_test_subtheme.1_0.xml index c791b7f1fb..2b1ddbf0aa 100644 --- a/core/modules/update/tests/modules/update_test/update_test_subtheme.1_0.xml +++ b/core/modules/update/tests/modules/update_test/update_test_subtheme.1_0.xml @@ -4,8 +4,8 @@ update_test_subtheme Drupal 8.x -1 -1 +8.x-1. +8.x-1. 1 published http://example.com/project/update_test_subtheme @@ -17,8 +17,6 @@ update_test_subtheme 8.x-1.0 8.x-1.0 DRUPAL-7--1-0 - 1 - 0 published http://example.com/update_test_subtheme-7-x-1-0-release http://example.com/update_test_subtheme-8.x-1.0.tar.gz diff --git a/core/modules/update/tests/src/Unit/ModuleVersionParserTest.php b/core/modules/update/tests/src/Unit/ModuleVersionParserTest.php new file mode 100644 index 0000000000..580dd19562 --- /dev/null +++ b/core/modules/update/tests/src/Unit/ModuleVersionParserTest.php @@ -0,0 +1,136 @@ +assertSame($excepted_version_info['major'], $releaseInfo->getMajorVersion()); + } + + /** + * @covers ::getMinorVersion + * + * @dataProvider providerVersionInfos + */ + public function testGetMinorVersion($version, $excepted_version_info) { + $releaseInfo = new ModuleVersionParser($version); + $this->assertSame($excepted_version_info['minor'], $releaseInfo->getMinorVersion()); + } + + /** + * @covers ::getPatchVersion + * + * @dataProvider providerVersionInfos + */ + public function testGetPatchVersion($version, $excepted_version_info) { + $releaseInfo = new ModuleVersionParser($version); + $this->assertSame($excepted_version_info['patch'], $releaseInfo->getPatchVersion()); + } + + /** + * @covers ::getVersionExtra + * + * @dataProvider providerVersionInfos + */ + public function testGetVersionExtra($version, $excepted_version_info) { + $releaseInfo = new ModuleVersionParser($version); + $this->assertSame($excepted_version_info['extra'], $releaseInfo->getVersionExtra()); + } + + /** + * @covers ::getSupportBranch + * + * @dataProvider providerVersionInfos + */ + public function testGetSupportBranch($version, $excepted_version_info) { + $releaseInfo = new ModuleVersionParser($version); + $this->assertSame($excepted_version_info['branch'], $releaseInfo->getSupportBranch()); + } + + /** + * Dataprovider for expected version information. + * + * @return array + * Arrays of version information. + */ + public function providerVersionInfos() { + return [ + '8.x-1.3' => [ + '8.x-1.3', + [ + 'major' => '1', + 'minor' => NULL, + 'patch' => '3', + 'extra' => NULL, + 'branch' => '8.x-1.', + ], + ], + '8.x-1.3-dev' => [ + '8.x-1.3-dev', + [ + 'major' => '1', + 'minor' => NULL, + 'patch' => '3', + 'extra' => 'dev', + 'branch' => '8.x-1.', + ], + ], + '1.3' => [ + '1.3', + [ + 'major' => '1', + 'minor' => NULL, + 'patch' => '3', + 'extra' => NULL, + 'branch' => '1.', + ], + ], + '1.3-dev' => [ + '1.3-dev', + [ + 'major' => '1', + 'minor' => NULL, + 'patch' => '3', + 'extra' => 'dev', + 'branch' => '1.', + ], + ], + '1.2.3' => [ + '1.2.3', + [ + 'major' => '1', + 'minor' => '2', + 'patch' => '3', + 'extra' => NULL, + 'branch' => '1.2.', + ], + ], + '1.2.3-dev' => [ + '1.2.3-dev', + [ + 'major' => '1', + 'minor' => '2', + 'patch' => '3', + 'extra' => 'dev', + 'branch' => '1.2.', + ], + ], + ]; + } + +} diff --git a/core/modules/update/tests/src/Unit/UpdateFetcherTest.php b/core/modules/update/tests/src/Unit/UpdateFetcherTest.php index 61c767deda..fb06f4173e 100644 --- a/core/modules/update/tests/src/Unit/UpdateFetcherTest.php +++ b/core/modules/update/tests/src/Unit/UpdateFetcherTest.php @@ -5,10 +5,6 @@ use Drupal\Tests\UnitTestCase; use Drupal\update\UpdateFetcher; -if (!defined('DRUPAL_CORE_COMPATIBILITY')) { - define('DRUPAL_CORE_COMPATIBILITY', '8.x'); -} - /** * Tests update functionality unrelated to the database. * @@ -71,20 +67,20 @@ public function providerTestUpdateBuildFetchUrl() { $project['info']['project status url'] = 'http://www.example.com'; $project['includes'] = ['module1' => 'Module 1', 'module2' => 'Module 2']; $site_key = ''; - $expected = 'http://www.example.com/' . $project['name'] . '/' . DRUPAL_CORE_COMPATIBILITY; + $expected = 'http://www.example.com/' . $project['name'] . '/current'; $data[] = [$project, $site_key, $expected]; // For disabled projects it shouldn't add the site key either. $site_key = 'site_key'; $project['project_type'] = 'disabled'; - $expected = 'http://www.example.com/' . $project['name'] . '/' . DRUPAL_CORE_COMPATIBILITY; + $expected = 'http://www.example.com/' . $project['name'] . '/current'; $data[] = [$project, $site_key, $expected]; // For enabled projects, test adding the site key. $project['project_type'] = ''; - $expected = 'http://www.example.com/' . $project['name'] . '/' . DRUPAL_CORE_COMPATIBILITY; + $expected = 'http://www.example.com/' . $project['name'] . '/current'; $expected .= '?site_key=site_key'; $expected .= '&list=' . rawurlencode('module1,module2'); @@ -92,7 +88,7 @@ public function providerTestUpdateBuildFetchUrl() { // Test when the URL contains a question mark. $project['info']['project status url'] = 'http://www.example.com/?project='; - $expected = 'http://www.example.com/?project=/' . $project['name'] . '/' . DRUPAL_CORE_COMPATIBILITY; + $expected = 'http://www.example.com/?project=/' . $project['name'] . '/current'; $expected .= '&site_key=site_key'; $expected .= '&list=' . rawurlencode('module1,module2'); diff --git a/core/modules/update/update.compare.inc b/core/modules/update/update.compare.inc index dd658120ef..be79cce0af 100644 --- a/core/modules/update/update.compare.inc +++ b/core/modules/update/update.compare.inc @@ -5,6 +5,8 @@ * Code required only when comparing available updates to existing data. */ +use Drupal\update\ModuleVersionParser; + /** * Determines version and type information for currently installed projects. * @@ -232,26 +234,25 @@ function update_calculate_project_update_status(&$project_data, $available) { } // Figure out the target major version. - $existing_major = $project_data['existing_major']; - $supported_majors = []; - if (isset($available['supported_majors'])) { - $supported_majors = explode(',', $available['supported_majors']); - } - elseif (isset($available['default_major'])) { - // Older release history XML file without supported or recommended. - $supported_majors[] = $available['default_major']; + $existing_version_parser = new ModuleVersionParser($project_data['existing_version']); + $existing_major = $existing_version_parser->getMajorVersion(); + $supported_branches = []; + if (isset($available['supported_branches'])) { + $supported_branches = explode(',', $available['supported_branches']); } - if (in_array($existing_major, $supported_majors)) { + + if (in_array($existing_version_parser->getSupportBranch(), $supported_branches)) { // Still supported, stay at the current major version. $target_major = $existing_major; } - elseif (isset($available['recommended_major'])) { - // Since 'recommended_major' is defined, we know this is the new XML + elseif (isset($available['recommended_branch'])) { + // Since 'recommended_branch' is defined, we know this is the new XML // format. Therefore, we know the current release is unsupported since - // its major version was not in the 'supported_majors' list. We should + // its major version was not in the 'supported_branches' list. We should // find the best release from the recommended major version. - $target_major = $available['recommended_major']; + $branch_version_parser = new ModuleVersionParser($available['recommended_branch'] . 'x'); + $target_major = $branch_version_parser->getMajorVersion(); $project_data['status'] = UPDATE_NOT_SUPPORTED; } elseif (isset($available['default_major'])) { @@ -260,7 +261,7 @@ function update_calculate_project_update_status(&$project_data, $available) { $target_major = $available['default_major']; } else { - // Malformed XML file? Stick with the current version. + // Malformed XML file? Stick with the current branch. $target_major = $existing_major; } @@ -294,6 +295,7 @@ function update_calculate_project_update_status(&$project_data, $available) { return; } foreach ($available['releases'] as $version => $release) { + $release_version_parser = new ModuleVersionParser($release['version']); // First, if this is the existing release, check a few conditions. if ($project_data['existing_version'] === $version) { if (isset($release['terms']['Release type']) && @@ -333,18 +335,20 @@ function update_calculate_project_update_status(&$project_data, $available) { continue; } + $release_major_version = $release_version_parser->getMajorVersion(); + $release_patch_version = $release_version_parser->getPatchVersion(); // See if this is a higher major version than our target and yet still // supported. If so, record it as an "Also available" release. // Note: Some projects have a HEAD release from CVS days, which could // be one of those being compared. They would not have version_major // set, so we must call isset first. - if (isset($release['version_major']) && $release['version_major'] > $target_major) { - if (in_array($release['version_major'], $supported_majors)) { + if ($release_major_version !== NULL && $release_major_version > $target_major) { + if (in_array($release_version_parser->getSupportBranch(), $supported_branches)) { if (!isset($project_data['also'])) { $project_data['also'] = []; } - if (!isset($project_data['also'][$release['version_major']])) { - $project_data['also'][$release['version_major']] = $version; + if (!isset($project_data['also'][$release_major_version])) { + $project_data['also'][$release_major_version] = $version; $project_data['releases'][$version] = $release; } } @@ -361,16 +365,15 @@ function update_calculate_project_update_status(&$project_data, $available) { // Look for the 'latest version' if we haven't found it yet. Latest is // defined as the most recent version for the target major version. if (!isset($project_data['latest_version']) - && $release['version_major'] == $target_major) { + && $release_major_version == $target_major) { $project_data['latest_version'] = $version; $project_data['releases'][$version] = $release; } // Look for the development snapshot release for this branch. if (!isset($project_data['dev_version']) - && $release['version_major'] == $target_major - && isset($release['version_extra']) - && $release['version_extra'] == 'dev') { + && $release_major_version == $target_major + && $release_version_parser->getVersionExtra() === 'dev') { $project_data['dev_version'] = $version; $project_data['releases'][$version] = $release; } @@ -378,13 +381,13 @@ function update_calculate_project_update_status(&$project_data, $available) { // Look for the 'recommended' version if we haven't found it yet (see // phpdoc at the top of this function for the definition). if (!isset($project_data['recommended']) - && $release['version_major'] == $target_major - && isset($release['version_patch'])) { - if ($patch != $release['version_patch']) { - $patch = $release['version_patch']; + && $release_major_version == $target_major + && $release_patch_version !== NULL) { + if ($patch != $release_patch_version) { + $patch = $release_patch_version; $release_patch_changed = $release; } - if (empty($release['version_extra']) && $patch == $release['version_patch']) { + if ($release_version_parser->getVersionExtra() === NULL && $patch == $release_patch_version) { $project_data['recommended'] = $release_patch_changed['version']; $project_data['releases'][$release_patch_changed['version']] = $release_patch_changed; }