From e4c5fc5c6e9f153e14dbc6495cebc2cbc32d9d7c Mon Sep 17 00:00:00 2001 From: Mark McDowall Date: Sat, 12 Aug 2023 00:41:27 -0700 Subject: [PATCH] Sync LocalizationService tests with upstream (cherry picked from commit 9c7fab69fd008a423f3607de71e0c76200e84ea5) Closes #8978 --- .../LocalizationServiceFixture.cs | 24 +++++++++---------- 1 file changed, 12 insertions(+), 12 deletions(-) diff --git a/src/NzbDrone.Core.Test/Localization/LocalizationServiceFixture.cs b/src/NzbDrone.Core.Test/Localization/LocalizationServiceFixture.cs index e54fec8c5..180292622 100644 --- a/src/NzbDrone.Core.Test/Localization/LocalizationServiceFixture.cs +++ b/src/NzbDrone.Core.Test/Localization/LocalizationServiceFixture.cs @@ -24,17 +24,17 @@ namespace NzbDrone.Core.Test.Localization [Test] public void should_get_string_in_dictionary_if_lang_exists_and_string_exists() { - var localizedString = Subject.GetLocalizedString("BackupNow"); + var localizedString = Subject.GetLocalizedString("UiLanguage"); - localizedString.Should().Be("Backup Now"); + localizedString.Should().Be("UI Language"); } [Test] public void should_get_string_in_default_language_dictionary_if_no_lang_country_code_exists_and_string_exists() { - var localizedString = Subject.GetLocalizedString("BackupNow", "de_de"); + var localizedString = Subject.GetLocalizedString("UiLanguage", "fr_fr"); - localizedString.Should().Be("Jetzt sichern"); + localizedString.Should().Be("UI Langue"); ExceptionVerification.ExpectedErrors(1); } @@ -42,9 +42,9 @@ namespace NzbDrone.Core.Test.Localization [Test] public void should_get_string_in_default_dictionary_if_no_lang_exists_and_string_exists() { - var localizedString = Subject.GetLocalizedString("BackupNow", "an"); + var localizedString = Subject.GetLocalizedString("UiLanguage", "an"); - localizedString.Should().Be("Backup Now"); + localizedString.Should().Be("UI Language"); ExceptionVerification.ExpectedErrors(1); } @@ -52,25 +52,25 @@ namespace NzbDrone.Core.Test.Localization [Test] public void should_get_string_in_default_dictionary_if_lang_empty_and_string_exists() { - var localizedString = Subject.GetLocalizedString("BackupNow", ""); + var localizedString = Subject.GetLocalizedString("UiLanguage", ""); - localizedString.Should().Be("Backup Now"); + localizedString.Should().Be("UI Language"); } [Test] public void should_return_argument_if_string_doesnt_exists() { - var localizedString = Subject.GetLocalizedString("BadString", "en"); + var localizedString = Subject.GetLocalizedString("badString", "en"); - localizedString.Should().Be("BadString"); + localizedString.Should().Be("badString"); } [Test] public void should_return_argument_if_string_doesnt_exists_default_lang() { - var localizedString = Subject.GetLocalizedString("BadString"); + var localizedString = Subject.GetLocalizedString("badString"); - localizedString.Should().Be("BadString"); + localizedString.Should().Be("badString"); } [Test]