mirror of
https://github.com/jellyfin/jellyfin.git
synced 2026-06-03 06:18:28 +01:00
Fix migration with special Rating (#11541)
This commit is contained in:
@@ -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")]
|
||||
|
||||
Reference in New Issue
Block a user