mirror of
https://github.com/jellyfin/jellyfin.git
synced 2026-01-23 23:20:51 +01:00
Backport pull request #11541 from jellyfin/release-10.9.z
Fix migration with special Rating
Original-merge: efba619acb
Merged-by: crobibero <cody@robibe.ro>
Backported-by: Joshua M. Boniface <joshua@boniface.me>
This commit is contained in:
parent
e5ecdcf8c9
commit
a118498f79
2 changed files with 26 additions and 3 deletions
|
|
@ -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;
|
||||
|
|
@ -157,6 +158,20 @@ namespace Jellyfin.Server.Implementations.Tests.Localization
|
|||
Assert.Null(localizationManager.GetRatingLevel("n/a"));
|
||||
}
|
||||
|
||||
[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")]
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue