Skip to content
Snippets Groups Projects
Commit 71424c7b authored by Theresa Grannum's avatar Theresa Grannum Committed by Adam G-H
Browse files

Issue #3274837 by Theresa.Grannum: Remove "recommended" from text of version validators

parent 544b6609
No related branches found
No related tags found
1 merge request!326Issue #3274837: Remove "recommended" from text of version validators
Showing
with 31 additions and 30 deletions
......@@ -35,7 +35,7 @@ class ForbidMinorUpdates {
if ($installed_minor !== $target_minor) {
return [
$this->t('Drupal cannot be automatically updated from its current version, @installed_version, to the recommended version, @target_version, because automatic updates from one minor version to another are not supported during cron.', [
$this->t('Drupal cannot be automatically updated from @installed_version to @target_version because automatic updates from one minor version to another are not supported during cron.', [
'@installed_version' => $installed_version,
'@target_version' => $target_version,
]),
......
......@@ -36,7 +36,7 @@ class MajorVersionMatch {
if ($installed_major !== $target_major) {
return [
$this->t('Drupal cannot be automatically updated from its current version, @installed_version, to the recommended version, @target_version, because automatic updates from one major version to another are not supported.', [
$this->t('Drupal cannot be automatically updated from @installed_version to @target_version because automatic updates from one major version to another are not supported.', [
'@installed_version' => $installed_version,
'@target_version' => $target_version,
]),
......
......@@ -74,7 +74,7 @@ class MinorUpdatesEnabled implements ContainerInjectionInterface {
if (!$minor_updates_allowed) {
return [
$this->t('Drupal cannot be automatically updated from its current version, @installed_version, to the recommended version, @target_version, because automatic updates from one minor version to another are not supported.', [
$this->t('Drupal cannot be automatically updated from @installed_version to @target_version because automatic updates from one minor version to another are not supported.', [
'@installed_version' => $installed_version,
'@target_version' => $target_version,
]),
......
......@@ -32,7 +32,7 @@ class TargetSecurityRelease {
public function validate(string $installed_version, ?string $target_version, array $available_releases): array {
if (!$available_releases[$target_version]->isSecurityRelease()) {
return [
$this->t('Drupal cannot be automatically updated during cron from its current version, @installed_version, to the recommended version, @target_version, because @target_version is not a security release.', [
$this->t('Drupal cannot be automatically updated during cron from @installed_version to @target_version because @target_version is not a security release.', [
'@installed_version' => $installed_version,
'@target_version' => $target_version,
]),
......
......@@ -34,7 +34,7 @@ class TargetVersionStable {
if ($extra) {
return [
$this->t('Drupal cannot be automatically updated during cron to the recommended version, @target_version, because Automatic Updates only supports updating to stable versions during cron.', [
$this->t('Drupal cannot be automatically updated during cron to @target_version, because Automatic Updates only supports updating to stable versions during cron.', [
'@target_version' => $target_version,
]),
];
......
......@@ -116,7 +116,7 @@ class VersionPolicyValidatorTest extends AutomaticUpdatesKernelTestBase {
[CronUpdater::SECURITY],
[
$this->createValidationResult('9.8.1', '9.8.2', [
'Drupal cannot be automatically updated during cron from its current version, 9.8.1, to the recommended version, 9.8.2, because 9.8.2 is not a security release.',
'Drupal cannot be automatically updated during cron from 9.8.1 to 9.8.2 because 9.8.2 is not a security release.',
]),
],
],
......@@ -236,7 +236,7 @@ class VersionPolicyValidatorTest extends AutomaticUpdatesKernelTestBase {
['drupal' => '9.8.2'],
[
$this->createValidationResult('8.9.1', '9.8.2', [
'Drupal cannot be automatically updated from its current version, 8.9.1, to the recommended version, 9.8.2, because automatic updates from one major version to another are not supported.',
'Drupal cannot be automatically updated from 8.9.1 to 9.8.2 because automatic updates from one major version to another are not supported.',
]),
],
],
......@@ -273,7 +273,7 @@ class VersionPolicyValidatorTest extends AutomaticUpdatesKernelTestBase {
['drupal' => '9.8.2'],
[
$this->createValidationResult('9.8.1', '9.8.2', [
'Drupal cannot be automatically updated during cron from its current version, 9.8.1, to the recommended version, 9.8.2, because 9.8.2 is not a security release.',
'Drupal cannot be automatically updated during cron from 9.8.1 to 9.8.2 because 9.8.2 is not a security release.',
]),
],
],
......@@ -296,7 +296,7 @@ class VersionPolicyValidatorTest extends AutomaticUpdatesKernelTestBase {
['drupal' => '9.8.2'],
[
$this->createValidationResult('9.7.9', '9.8.2', [
'Drupal cannot be automatically updated from its current version, 9.7.9, to the recommended version, 9.8.2, because automatic updates from one minor version to another are not supported during cron.',
'Drupal cannot be automatically updated from 9.7.9 to 9.8.2 because automatic updates from one minor version to another are not supported during cron.',
]),
],
],
......@@ -308,7 +308,7 @@ class VersionPolicyValidatorTest extends AutomaticUpdatesKernelTestBase {
['drupal' => '9.8.2'],
[
$this->createValidationResult('9.7.9', '9.8.2', [
'Drupal cannot be automatically updated from its current version, 9.7.9, to the recommended version, 9.8.2, because automatic updates from one minor version to another are not supported.',
'Drupal cannot be automatically updated from 9.7.9 to 9.8.2 because automatic updates from one minor version to another are not supported.',
]),
],
],
......@@ -341,7 +341,7 @@ class VersionPolicyValidatorTest extends AutomaticUpdatesKernelTestBase {
['drupal' => '9.8.1-beta1'],
[
$this->createValidationResult('9.8.0', '9.8.1-beta1', [
'Drupal cannot be automatically updated during cron to the recommended version, 9.8.1-beta1, because Automatic Updates only supports updating to stable versions during cron.',
'Drupal cannot be automatically updated during cron to 9.8.1-beta1, because Automatic Updates only supports updating to stable versions during cron.',
]),
],
],
......
......@@ -41,32 +41,33 @@ class ForbidMinorUpdatesTest extends UnitTestCase {
'target version in older minor' => [
'9.8.0',
'9.7.2',
['Drupal cannot be automatically updated from its current version, 9.8.0, to the recommended version, 9.7.2, because automatic updates from one minor version to another are not supported during cron.'],
['Drupal cannot be automatically updated from 9.8.0 to 9.7.2 because automatic updates from one minor version to another are not supported during cron.'],
],
'target version in newer minor' => [
'9.8.0',
'9.9.2',
['Drupal cannot be automatically updated from its current version, 9.8.0, to the recommended version, 9.9.2, because automatic updates from one minor version to another are not supported during cron.'],
['Drupal cannot be automatically updated from 9.8.0 to 9.9.2 because automatic updates from one minor version to another are not supported during cron.'],
],
'target version in older major' => [
'9.8.0',
'8.8.0',
['Drupal cannot be automatically updated from its current version, 9.8.0, to the recommended version, 8.8.0, because automatic updates from one minor version to another are not supported during cron.'],
['Drupal cannot be automatically updated from 9.8.0 to 8.8.0 because automatic updates from one minor version to another are not supported during cron.'],
],
'target version in newer major' => [
'9.8.0',
'10.8.0',
['Drupal cannot be automatically updated from its current version, 9.8.0, to the recommended version, 10.8.0, because automatic updates from one minor version to another are not supported during cron.'],
['Drupal cannot be automatically updated from 9.8.0 to 10.8.0 because automatic updates from one minor version to another are not supported during cron.'],
],
'target version in older major and minor' => [
'9.8.0',
'8.9.9',
['Drupal cannot be automatically updated from its current version, 9.8.0, to the recommended version, 8.9.9, because automatic updates from one minor version to another are not supported during cron.'],
['Drupal cannot be automatically updated from 9.8.0 to 8.9.9 because automatic updates from one minor version to another are not supported during cron.'],
],
'target version in newer major and minor' => [
'9.8.0',
'10.9.2',
['Drupal cannot be automatically updated from its current version, 9.8.0, to the recommended version, 10.9.2, because automatic updates from one minor version to another are not supported during cron.'],
['Drupal cannot be automatically updated from 9.8.0 to 10.9.2 because automatic updates from one minor version to another are not supported during cron.'],
],
];
}
......
......@@ -51,12 +51,12 @@ class MajorVersionMatchTest extends UnitTestCase {
'target version in newer major' => [
'9.8.0',
'10.0.0',
['Drupal cannot be automatically updated from its current version, 9.8.0, to the recommended version, 10.0.0, because automatic updates from one major version to another are not supported.'],
['Drupal cannot be automatically updated from 9.8.0 to 10.0.0 because automatic updates from one major version to another are not supported.'],
],
'target version in older major' => [
'9.8.0',
'8.9.0',
['Drupal cannot be automatically updated from its current version, 9.8.0, to the recommended version, 8.9.0, because automatic updates from one major version to another are not supported.'],
['Drupal cannot be automatically updated from 9.8.0 to 8.9.0 because automatic updates from one major version to another are not supported.'],
],
];
}
......
......@@ -51,7 +51,7 @@ class MinorUpdatesEnabledTest extends UnitTestCase {
FALSE,
'9.8.0',
'9.9.2',
['Drupal cannot be automatically updated from its current version, 9.8.0, to the recommended version, 9.9.2, because automatic updates from one minor version to another are not supported.'],
['Drupal cannot be automatically updated from 9.8.0 to 9.9.2 because automatic updates from one minor version to another are not supported.'],
],
'target version in newer minor, minor updates allowed' => [
TRUE,
......@@ -75,7 +75,7 @@ class MinorUpdatesEnabledTest extends UnitTestCase {
FALSE,
'9.8.0',
'9.7.2',
['Drupal cannot be automatically updated from its current version, 9.8.0, to the recommended version, 9.7.2, because automatic updates from one minor version to another are not supported.'],
['Drupal cannot be automatically updated from 9.8.0 to 9.7.2 because automatic updates from one minor version to another are not supported.'],
],
'target version in older minor, minor updates allowed' => [
TRUE,
......@@ -87,25 +87,25 @@ class MinorUpdatesEnabledTest extends UnitTestCase {
FALSE,
'9.8.0',
'8.8.0',
['Drupal cannot be automatically updated from its current version, 9.8.0, to the recommended version, 8.8.0, because automatic updates from one minor version to another are not supported.'],
['Drupal cannot be automatically updated from 9.8.0 to 8.8.0 because automatic updates from one minor version to another are not supported.'],
],
'target version in older major, minor updates allowed' => [
FALSE,
'9.8.0',
'8.8.0',
['Drupal cannot be automatically updated from its current version, 9.8.0, to the recommended version, 8.8.0, because automatic updates from one minor version to another are not supported.'],
['Drupal cannot be automatically updated from 9.8.0 to 8.8.0 because automatic updates from one minor version to another are not supported.'],
],
'target version in newer major, minor updates forbidden' => [
FALSE,
'9.8.0',
'10.8.0',
['Drupal cannot be automatically updated from its current version, 9.8.0, to the recommended version, 10.8.0, because automatic updates from one minor version to another are not supported.'],
['Drupal cannot be automatically updated from 9.8.0 to 10.8.0 because automatic updates from one minor version to another are not supported.'],
],
'target version in newer major, minor updates allowed' => [
FALSE,
'9.8.0',
'10.8.0',
['Drupal cannot be automatically updated from its current version, 9.8.0, to the recommended version, 10.8.0, because automatic updates from one minor version to another are not supported.'],
['Drupal cannot be automatically updated from 9.8.0 to 10.8.0 because automatic updates from one minor version to another are not supported.'],
],
];
}
......
......@@ -45,7 +45,7 @@ class TargetSecurityReleaseTest extends UnitTestCase {
'version' => '9.8.1',
]),
],
['Drupal cannot be automatically updated during cron from its current version, 9.8.0, to the recommended version, 9.8.1, because 9.8.1 is not a security release.'],
['Drupal cannot be automatically updated during cron from 9.8.0 to 9.8.1 because 9.8.1 is not a security release.'],
],
];
}
......
......@@ -29,19 +29,19 @@ class TargetVersionStableTest extends UnitTestCase {
],
'dev target version' => [
'9.9.0-dev',
['Drupal cannot be automatically updated during cron to the recommended version, 9.9.0-dev, because Automatic Updates only supports updating to stable versions during cron.'],
['Drupal cannot be automatically updated during cron to 9.9.0-dev, because Automatic Updates only supports updating to stable versions during cron.'],
],
'alpha target version' => [
'9.9.0-alpha3',
['Drupal cannot be automatically updated during cron to the recommended version, 9.9.0-alpha3, because Automatic Updates only supports updating to stable versions during cron.'],
['Drupal cannot be automatically updated during cron to 9.9.0-alpha3, because Automatic Updates only supports updating to stable versions during cron.'],
],
'beta target version' => [
'9.9.0-beta7',
['Drupal cannot be automatically updated during cron to the recommended version, 9.9.0-beta7, because Automatic Updates only supports updating to stable versions during cron.'],
['Drupal cannot be automatically updated during cron to 9.9.0-beta7, because Automatic Updates only supports updating to stable versions during cron.'],
],
'release candidate target version' => [
'9.9.0-rc2',
['Drupal cannot be automatically updated during cron to the recommended version, 9.9.0-rc2, because Automatic Updates only supports updating to stable versions during cron.'],
['Drupal cannot be automatically updated during cron to 9.9.0-rc2, because Automatic Updates only supports updating to stable versions during cron.'],
],
];
}
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment