diff options
| author | crobibero <cody@robibe.ro> | 2024-05-13 12:47:32 -0400 |
|---|---|---|
| committer | Joshua M. Boniface <joshua@boniface.me> | 2024-05-13 12:47:32 -0400 |
| commit | a118498f79abaac49fb6be508786f948f05ad502 (patch) | |
| tree | 5e35531e037a8c7a1bd28efbf23119e1fcda2e2b /tests/Jellyfin.Server.Implementations.Tests/Localization/LocalizationManagerTests.cs | |
| parent | e5ecdcf8c99f16928b18cb4c0fcc77e1c08b2637 (diff) | |
Backport pull request #11541 from jellyfin/release-10.9.z
Fix migration with special Rating
Original-merge: efba619acbe4849205874a464511ffcfd4aad2ba
Merged-by: crobibero <cody@robibe.ro>
Backported-by: Joshua M. Boniface <joshua@boniface.me>
Diffstat (limited to 'tests/Jellyfin.Server.Implementations.Tests/Localization/LocalizationManagerTests.cs')
| -rw-r--r-- | tests/Jellyfin.Server.Implementations.Tests/Localization/LocalizationManagerTests.cs | 15 |
1 files changed, 15 insertions, 0 deletions
diff --git a/tests/Jellyfin.Server.Implementations.Tests/Localization/LocalizationManagerTests.cs b/tests/Jellyfin.Server.Implementations.Tests/Localization/LocalizationManagerTests.cs index 0f7f5c194..0a4a836cb 100644 --- a/tests/Jellyfin.Server.Implementations.Tests/Localization/LocalizationManagerTests.cs +++ b/tests/Jellyfin.Server.Implementations.Tests/Localization/LocalizationManagerTests.cs @@ -1,5 +1,6 @@ using System; using System.Linq; +using System.Runtime.InteropServices; using System.Threading.Tasks; using Emby.Server.Implementations.Localization; using MediaBrowser.Controller.Configuration; @@ -158,6 +159,20 @@ namespace Jellyfin.Server.Implementations.Tests.Localization } [Theory] + [InlineData("-NO RATING SHOWN-")] + [InlineData(":NO RATING SHOWN:")] + public async Task GetRatingLevel_Split_Success(string value) + { + var localizationManager = Setup(new ServerConfiguration() + { + UICulture = "en-US" + }); + await localizationManager.LoadAll(); + + Assert.Null(localizationManager.GetRatingLevel(value)); + } + + [Theory] [InlineData("Default", "Default")] [InlineData("HeaderLiveTV", "Live TV")] public void GetLocalizedString_Valid_Success(string key, string expected) |
