Improve XML docs and formatting in tests and constants

Added and enhanced XML documentation comments across the codebase, including detailed summaries and parameter descriptions for methods, classes, and constants. Documented all MatroskaConstants. Improved test readability with comments and explicit variable declarations. Made minor formatting and consistency fixes in test files. No functional changes. Updated project cache and binary files to reflect documentation improvements.
This commit is contained in:
2026-02-21 15:46:18 -05:00
parent 2dc0129a11
commit e887356385
86 changed files with 385 additions and 255 deletions
+1 -1
View File
@@ -1,6 +1,6 @@
{
"version": 2,
"dgSpecHash": "qWdnDCktJdY=",
"dgSpecHash": "M3eEjXrprD8=",
"success": true,
"projectFilePath": "E:\\Projects\\pgsql-jellyfin\\Emby.Naming\\Emby.Naming.csproj",
"expectedPackageFiles": [
+1 -1
View File
@@ -1,6 +1,6 @@
{
"version": 2,
"dgSpecHash": "DaMoU2oavX0=",
"dgSpecHash": "leFWYb0Dcsk=",
"success": true,
"projectFilePath": "E:\\Projects\\pgsql-jellyfin\\Emby.Photos\\Emby.Photos.csproj",
"expectedPackageFiles": [
@@ -1,6 +1,6 @@
{
"version": 2,
"dgSpecHash": "CU3WcVn0qXE=",
"dgSpecHash": "ZVA5ePVHqjg=",
"success": true,
"projectFilePath": "E:\\Projects\\pgsql-jellyfin\\Emby.Server.Implementations\\Emby.Server.Implementations.csproj",
"expectedPackageFiles": [
+1 -1
View File
@@ -1,6 +1,6 @@
{
"version": 2,
"dgSpecHash": "sEpjYe2J48k=",
"dgSpecHash": "4CpeL+8YFHs=",
"success": true,
"projectFilePath": "E:\\Projects\\pgsql-jellyfin\\Jellyfin.Api\\Jellyfin.Api.csproj",
"expectedPackageFiles": [
+1 -1
View File
@@ -1,6 +1,6 @@
{
"version": 2,
"dgSpecHash": "V+/rEcS1v1k=",
"dgSpecHash": "R6LANlB4kiE=",
"success": true,
"projectFilePath": "E:\\Projects\\pgsql-jellyfin\\Jellyfin.Data\\Jellyfin.Data.csproj",
"expectedPackageFiles": [
@@ -1,6 +1,6 @@
{
"version": 2,
"dgSpecHash": "2uqnqkg9VpI=",
"dgSpecHash": "8rGyZK2RqJs=",
"success": true,
"projectFilePath": "E:\\Projects\\pgsql-jellyfin\\Jellyfin.Server.Implementations\\Jellyfin.Server.Implementations.csproj",
"expectedPackageFiles": [
+1 -1
View File
@@ -1,6 +1,6 @@
{
"version": 2,
"dgSpecHash": "uvfyRwbCsEk=",
"dgSpecHash": "WNAhlXOd1t0=",
"success": true,
"projectFilePath": "E:\\Projects\\pgsql-jellyfin\\Jellyfin.Server\\Jellyfin.Server.csproj",
"expectedPackageFiles": [
+1 -1
View File
@@ -1,6 +1,6 @@
{
"version": 2,
"dgSpecHash": "JKxQaRKDB/g=",
"dgSpecHash": "TOGQe6JoQmo=",
"success": true,
"projectFilePath": "E:\\Projects\\pgsql-jellyfin\\MediaBrowser.Common\\MediaBrowser.Common.csproj",
"expectedPackageFiles": [
@@ -1,6 +1,6 @@
{
"version": 2,
"dgSpecHash": "No+LvUzpMog=",
"dgSpecHash": "oIB4cupu3LM=",
"success": true,
"projectFilePath": "E:\\Projects\\pgsql-jellyfin\\MediaBrowser.Controller\\MediaBrowser.Controller.csproj",
"expectedPackageFiles": [
@@ -1,6 +1,6 @@
{
"version": 2,
"dgSpecHash": "MUG8U7vEPzE=",
"dgSpecHash": "GeC+ga1Uo2A=",
"success": true,
"projectFilePath": "E:\\Projects\\pgsql-jellyfin\\MediaBrowser.LocalMetadata\\MediaBrowser.LocalMetadata.csproj",
"expectedPackageFiles": [
@@ -1,6 +1,6 @@
{
"version": 2,
"dgSpecHash": "GTQOs1iNxFU=",
"dgSpecHash": "aQOA3jWvZ/0=",
"success": true,
"projectFilePath": "E:\\Projects\\pgsql-jellyfin\\MediaBrowser.MediaEncoding\\MediaBrowser.MediaEncoding.csproj",
"expectedPackageFiles": [
+1 -1
View File
@@ -1,6 +1,6 @@
{
"version": 2,
"dgSpecHash": "xzRZKMjouOE=",
"dgSpecHash": "3yWrXzucBNg=",
"success": true,
"projectFilePath": "E:\\Projects\\pgsql-jellyfin\\MediaBrowser.Model\\MediaBrowser.Model.csproj",
"expectedPackageFiles": [
@@ -1,6 +1,6 @@
{
"version": 2,
"dgSpecHash": "O+ANw3v7loA=",
"dgSpecHash": "ncCtXCalGV4=",
"success": true,
"projectFilePath": "E:\\Projects\\pgsql-jellyfin\\MediaBrowser.Providers\\MediaBrowser.Providers.csproj",
"expectedPackageFiles": [
@@ -1,6 +1,6 @@
{
"version": 2,
"dgSpecHash": "rQazb3gGG1E=",
"dgSpecHash": "P3fDKwImSWA=",
"success": true,
"projectFilePath": "E:\\Projects\\pgsql-jellyfin\\MediaBrowser.XbmcMetadata\\MediaBrowser.XbmcMetadata.csproj",
"expectedPackageFiles": [
@@ -13,7 +13,7 @@ using System.Reflection;
[assembly: System.Reflection.AssemblyCompanyAttribute("Jellyfin.CodeAnalysis")]
[assembly: System.Reflection.AssemblyConfigurationAttribute("Debug")]
[assembly: System.Reflection.AssemblyFileVersionAttribute("1.0.0.0")]
[assembly: System.Reflection.AssemblyInformationalVersionAttribute("1.0.0+8421e3ad5cdcbeb790e69d4367c55181a2af7b16")]
[assembly: System.Reflection.AssemblyInformationalVersionAttribute("1.0.0+2dc0129a11d3a125fd227b7e4a86196bf919a4c8")]
[assembly: System.Reflection.AssemblyProductAttribute("Jellyfin.CodeAnalysis")]
[assembly: System.Reflection.AssemblyTitleAttribute("Jellyfin.CodeAnalysis")]
[assembly: System.Reflection.AssemblyVersionAttribute("1.0.0.0")]
@@ -1 +1 @@
8d7e69f115ae75e4f7c84eb253600f36f2309decc7a35f49dc405e154ddd5a4a
3bf9933fb90a6f3d3cf98eeedc63c2ff29157a52a9ff0ab543c63872fa45561b
@@ -1,6 +1,6 @@
{
"version": 2,
"dgSpecHash": "OZOEm6CP/lY=",
"dgSpecHash": "Y7Khl1IIiuQ=",
"success": true,
"projectFilePath": "E:\\Projects\\pgsql-jellyfin\\src\\Jellyfin.CodeAnalysis\\Jellyfin.CodeAnalysis.csproj",
"expectedPackageFiles": [
@@ -1,6 +1,6 @@
{
"version": 2,
"dgSpecHash": "wWhRHr+gc4I=",
"dgSpecHash": "o3KwAigR2H0=",
"success": true,
"projectFilePath": "E:\\Projects\\pgsql-jellyfin\\src\\Jellyfin.Database\\Jellyfin.Database.Implementations\\Jellyfin.Database.Implementations.csproj",
"expectedPackageFiles": [
@@ -1,6 +1,6 @@
{
"version": 2,
"dgSpecHash": "7p0VjWNAkOM=",
"dgSpecHash": "vHGJFlfns3Y=",
"success": true,
"projectFilePath": "E:\\Projects\\pgsql-jellyfin\\src\\Jellyfin.Database\\Jellyfin.Database.Providers.Sqlite\\Jellyfin.Database.Providers.Sqlite.csproj",
"expectedPackageFiles": [
@@ -1,6 +1,6 @@
{
"version": 2,
"dgSpecHash": "HMW40QmobtY=",
"dgSpecHash": "Fpoz11tqLl0=",
"success": true,
"projectFilePath": "E:\\Projects\\pgsql-jellyfin\\src\\Jellyfin.Drawing.Skia\\Jellyfin.Drawing.Skia.csproj",
"expectedPackageFiles": [
+1 -1
View File
@@ -1,6 +1,6 @@
{
"version": 2,
"dgSpecHash": "kfdiYX/qdMo=",
"dgSpecHash": "Vcdm+k15Tts=",
"success": true,
"projectFilePath": "E:\\Projects\\pgsql-jellyfin\\src\\Jellyfin.Drawing\\Jellyfin.Drawing.csproj",
"expectedPackageFiles": [
@@ -1,6 +1,6 @@
{
"version": 2,
"dgSpecHash": "jFXUtLlrjTY=",
"dgSpecHash": "bmcoRiE2ZBQ=",
"success": true,
"projectFilePath": "E:\\Projects\\pgsql-jellyfin\\src\\Jellyfin.Extensions\\Jellyfin.Extensions.csproj",
"expectedPackageFiles": [
+1 -1
View File
@@ -1,6 +1,6 @@
{
"version": 2,
"dgSpecHash": "Wq1Uahcka68=",
"dgSpecHash": "9I/zz4fLYTY=",
"success": true,
"projectFilePath": "E:\\Projects\\pgsql-jellyfin\\src\\Jellyfin.LiveTv\\Jellyfin.LiveTv.csproj",
"expectedPackageFiles": [
@@ -1,6 +1,6 @@
{
"version": 2,
"dgSpecHash": "2kUNnZdwGG8=",
"dgSpecHash": "svddOISkg9E=",
"success": true,
"projectFilePath": "E:\\Projects\\pgsql-jellyfin\\src\\Jellyfin.MediaEncoding.Hls\\Jellyfin.MediaEncoding.Hls.csproj",
"expectedPackageFiles": [
@@ -76,6 +76,11 @@ public static class FfProbeKeyframeExtractor
}
}
/// <summary>
/// Parses the keyframe data from the FFProbe stream.
/// </summary>
/// <param name="reader">The stream reader containing FFProbe output.</param>
/// <returns>The parsed keyframe data.</returns>
internal static KeyframeData ParseStream(StreamReader reader)
{
var keyframes = new List<long>();
@@ -9,26 +9,88 @@ namespace Jellyfin.MediaEncoding.Keyframes.Matroska;
/// </summary>
public static class MatroskaConstants
{
/// <summary>
/// The Matroska segment container identifier.
/// </summary>
internal const ulong SegmentContainer = 0x18538067;
/// <summary>
/// The Matroska seek head identifier.
/// </summary>
internal const ulong SeekHead = 0x114D9B74;
/// <summary>
/// The Matroska seek identifier.
/// </summary>
internal const ulong Seek = 0x4DBB;
/// <summary>
/// The Matroska info identifier.
/// </summary>
internal const ulong Info = 0x1549A966;
/// <summary>
/// The Matroska timestamp scale identifier.
/// </summary>
internal const ulong TimestampScale = 0x2AD7B1;
/// <summary>
/// The Matroska duration identifier.
/// </summary>
internal const ulong Duration = 0x4489;
/// <summary>
/// The Matroska tracks identifier.
/// </summary>
internal const ulong Tracks = 0x1654AE6B;
/// <summary>
/// The Matroska track entry identifier.
/// </summary>
internal const ulong TrackEntry = 0xAE;
/// <summary>
/// The Matroska track number identifier.
/// </summary>
internal const ulong TrackNumber = 0xD7;
/// <summary>
/// The Matroska track type identifier.
/// </summary>
internal const ulong TrackType = 0x83;
/// <summary>
/// The Matroska video track type value.
/// </summary>
internal const ulong TrackTypeVideo = 0x1;
/// <summary>
/// The Matroska subtitle track type value.
/// </summary>
internal const ulong TrackTypeSubtitle = 0x11;
/// <summary>
/// The Matroska cues identifier.
/// </summary>
internal const ulong Cues = 0x1C53BB6B;
/// <summary>
/// The Matroska cue time identifier.
/// </summary>
internal const ulong CueTime = 0xB3;
/// <summary>
/// The Matroska cue point identifier.
/// </summary>
internal const ulong CuePoint = 0xBB;
/// <summary>
/// The Matroska cue track positions identifier.
/// </summary>
internal const ulong CueTrackPositions = 0xB7;
/// <summary>
/// The Matroska cue point track number identifier.
/// </summary>
internal const ulong CuePointTrackNumber = 0xF7;
}
@@ -1,6 +1,6 @@
{
"version": 2,
"dgSpecHash": "mTVFQQSIGo8=",
"dgSpecHash": "fWFpFkhudto=",
"success": true,
"projectFilePath": "E:\\Projects\\pgsql-jellyfin\\src\\Jellyfin.MediaEncoding.Keyframes\\Jellyfin.MediaEncoding.Keyframes.csproj",
"expectedPackageFiles": [
@@ -1,6 +1,6 @@
{
"version": 2,
"dgSpecHash": "o8ef9/49oOU=",
"dgSpecHash": "nYThmTXT+N4=",
"success": true,
"projectFilePath": "E:\\Projects\\pgsql-jellyfin\\src\\Jellyfin.Networking\\Jellyfin.Networking.csproj",
"expectedPackageFiles": [
@@ -1,6 +1,6 @@
{
"version": 2,
"dgSpecHash": "I6cvgut0KE0=",
"dgSpecHash": "jz3od75Vj9o=",
"success": true,
"projectFilePath": "E:\\Projects\\pgsql-jellyfin\\tests\\Jellyfin.Api.Tests\\Jellyfin.Api.Tests.csproj",
"expectedPackageFiles": [
@@ -1,6 +1,6 @@
{
"version": 2,
"dgSpecHash": "rSTC0c4hKeg=",
"dgSpecHash": "D3+az8yIj/g=",
"success": true,
"projectFilePath": "E:\\Projects\\pgsql-jellyfin\\tests\\Jellyfin.Common.Tests\\Jellyfin.Common.Tests.csproj",
"expectedPackageFiles": [
@@ -1,6 +1,6 @@
{
"version": 2,
"dgSpecHash": "rCzbZx73oRU=",
"dgSpecHash": "GDKjP2XUxGM=",
"success": true,
"projectFilePath": "E:\\Projects\\pgsql-jellyfin\\tests\\Jellyfin.Controller.Tests\\Jellyfin.Controller.Tests.csproj",
"expectedPackageFiles": [
@@ -8,19 +8,33 @@ namespace Jellyfin.Extensions.Tests
using System.Collections.Generic;
using Xunit;
/// <summary>
/// Tests for CopyTo extension methods.
/// </summary>
public static class CopyToExtensionsTests
{
/// <summary>
/// Gets test data for valid CopyTo operations.
/// </summary>
/// <returns>The test data.</returns>
public static TheoryData<IReadOnlyList<int>, IList<int>, int, IList<int>> CopyTo_Valid_Correct_TestData()
{
var data = new TheoryData<IReadOnlyList<int>, IList<int>, int, IList<int>>
TheoryData<IReadOnlyList<int>, IList<int>, int, IList<int>> data = new TheoryData<IReadOnlyList<int>, IList<int>, int, IList<int>>
{
{ new[] { 0, 1, 2, 3, 4, 5 }, new[] { 0, 0, 0, 0, 0, 0 }, 0, new[] { 0, 1, 2, 3, 4, 5 } },
{ new[] { 0, 1, 2 }, new[] { 5, 4, 3, 2, 1, 0 }, 2, new[] { 5, 4, 0, 1, 2, 0 } }
{ new[] { 0, 1, 2 }, new[] { 5, 4, 3, 2, 1, 0 }, 2, new[] { 5, 4, 0, 1, 2, 0 } },
};
return data;
}
/// <summary>
/// Tests that CopyTo correctly copies elements.
/// </summary>
/// <param name="source">The source list.</param>
/// <param name="destination">The destination list.</param>
/// <param name="index">The starting index.</param>
/// <param name="expected">The expected result.</param>
[Theory]
[MemberData(nameof(CopyTo_Valid_Correct_TestData))]
public static void CopyTo_Valid_Correct(IReadOnlyList<int> source, IList<int> destination, int index, IList<int> expected)
@@ -29,20 +43,30 @@ namespace Jellyfin.Extensions.Tests
Assert.Equal(expected, destination);
}
/// <summary>
/// Gets test data for invalid CopyTo operations that should throw.
/// </summary>
/// <returns>The test data.</returns>
public static TheoryData<IReadOnlyList<int>, IList<int>, int> CopyTo_Invalid_ThrowsArgumentOutOfRangeException_TestData()
{
var data = new TheoryData<IReadOnlyList<int>, IList<int>, int>
TheoryData<IReadOnlyList<int>, IList<int>, int> data = new TheoryData<IReadOnlyList<int>, IList<int>, int>
{
{ new[] { 0, 1, 2, 3, 4, 5 }, new[] { 0, 0, 0, 0, 0, 0 }, -1 },
{ new[] { 0, 1, 2 }, new[] { 5, 4, 3, 2, 1, 0 }, 6 },
{ new[] { 0, 1, 2 }, Array.Empty<int>(), 0 },
{ new[] { 0, 1, 2, 3, 4, 5 }, new[] { 0 }, 0 },
{ new[] { 0, 1, 2, 3, 4, 5 }, new[] { 0, 0, 0, 0, 0, 0 }, 1 }
{ new[] { 0, 1, 2, 3, 4, 5 }, new[] { 0, 0, 0, 0, 0, 0 }, 1 },
};
return data;
}
/// <summary>
/// Tests that CopyTo throws ArgumentOutOfRangeException for invalid inputs.
/// </summary>
/// <param name="source">The source list.</param>
/// <param name="destination">The destination list.</param>
/// <param name="index">The starting index.</param>
[Theory]
[MemberData(nameof(CopyTo_Invalid_ThrowsArgumentOutOfRangeException_TestData))]
public static void CopyTo_Invalid_ThrowsArgumentOutOfRangeException(IReadOnlyList<int> source, IList<int> destination, int index)
@@ -11,16 +11,24 @@ namespace Jellyfin.Extensions.Tests.Json.Converters
using Jellyfin.Extensions.Json.Converters;
using Xunit;
/// <summary>
/// Tests for the JsonBoolNumberConverter.
/// </summary>
public class JsonBoolNumberTests
{
private readonly JsonSerializerOptions _jsonOptions = new JsonSerializerOptions()
private readonly JsonSerializerOptions _jsonOptions = new()
{
Converters =
{
new JsonBoolNumberConverter()
}
new JsonBoolNumberConverter(),
},
};
/// <summary>
/// Tests deserialization of numbers to boolean.
/// </summary>
/// <param name="input">The input string.</param>
/// <param name="output">The expected output.</param>
[Theory]
[InlineData("1", true)]
[InlineData("0", false)]
@@ -29,21 +37,31 @@ namespace Jellyfin.Extensions.Tests.Json.Converters
[InlineData("false", false)]
public void Deserialize_Number_Valid_Success(string input, bool? output)
{
var value = JsonSerializer.Deserialize<bool>(input, _jsonOptions);
bool value = JsonSerializer.Deserialize<bool>(input, this._jsonOptions);
Assert.Equal(value, output);
}
/// <summary>
/// Tests serialization of boolean values.
/// </summary>
/// <param name="input">The input boolean.</param>
/// <param name="output">The expected output.</param>
[Theory]
[InlineData(true, "true")]
[InlineData(false, "false")]
public void Serialize_Bool_Success(bool input, string output)
{
var value = JsonSerializer.Serialize(input, _jsonOptions);
string value = JsonSerializer.Serialize(input, this._jsonOptions);
Assert.Equal(value, output);
}
/// <summary>
/// Property test that non-zero integers deserialize to true.
/// </summary>
/// <param name="input">The input non-zero integer.</param>
/// <returns>A property test result.</returns>
[Property]
public Property Deserialize_NonZeroInt_True(NonZeroInt input)
=> JsonSerializer.Deserialize<bool>(input.ToString(), _jsonOptions).ToProperty();
=> JsonSerializer.Deserialize<bool>(input.ToString(), this._jsonOptions).ToProperty();
}
}
@@ -14,8 +14,8 @@ namespace Jellyfin.Extensions.Tests.Json.Converters
{
Converters =
{
new JsonBoolStringConverter()
}
new JsonBoolStringConverter(),
},
};
[Theory]
@@ -23,7 +23,7 @@ namespace Jellyfin.Extensions.Tests.Json.Converters
[InlineData(@"{ ""Value"": ""false"" }", false)]
public void Deserialize_String_Valid_Success(string input, bool output)
{
var s = JsonSerializer.Deserialize<TestStruct>(input, _jsonOptions);
TestStruct s = JsonSerializer.Deserialize<TestStruct>(input, _jsonOptions);
Assert.Equal(s.Value, output);
}
@@ -32,7 +32,7 @@ namespace Jellyfin.Extensions.Tests.Json.Converters
[InlineData(false, "false")]
public void Serialize_Bool_Success(bool input, string output)
{
var value = JsonSerializer.Serialize(input, _jsonOptions);
string value = JsonSerializer.Serialize(input, _jsonOptions);
Assert.Equal(value, output);
}
@@ -20,35 +20,37 @@ namespace Jellyfin.Extensions.Tests.Json.Converters
{
Converters =
{
new JsonStringEnumConverter()
}
new JsonStringEnumConverter(),
},
};
[Fact]
public void Deserialize_String_Null_Success()
{
var value = JsonSerializer.Deserialize<GenericBodyArrayModel<string>>(@"{ ""Value"": null }", _jsonOptions);
GenericBodyArrayModel<string value = JsonSerializer.Deserialize<GenericBodyArrayModel<string>>(@"{ ""Value"": null }", _jsonOptions);
Assert.Null(value?.Value);
}
[Fact]
public void Deserialize_Empty_Success()
{
var desiredValue = new GenericBodyArrayModel<string>
GenericBodyArrayModel<string>
{ desiredValue = new GenericBodyArrayModel<string>
{
Value = Array.Empty<string>()
Value = Array.Empty<string>(),
};
var value = JsonSerializer.Deserialize<GenericBodyArrayModel<string>>(@"{ ""Value"": """" }", _jsonOptions);
GenericBodyArrayModel<string value = JsonSerializer.Deserialize<GenericBodyArrayModel<string>>(@"{ ""Value"": """" }", _jsonOptions);
Assert.Equal(desiredValue.Value, value?.Value);
}
[Fact]
public void Deserialize_EmptyList_Success()
{
var desiredValue = new GenericBodyListModel<string>
GenericBodyListModel<string>
{ desiredValue = new GenericBodyListModel<string>
{
Value = []
Value = [],
};
Assert.Throws<InvalidOperationException>(() => JsonSerializer.Deserialize<GenericBodyListModel<string>>(@"{ ""Value"": """" }", _jsonOptions));
@@ -57,33 +59,36 @@ namespace Jellyfin.Extensions.Tests.Json.Converters
[Fact]
public void Deserialize_EmptyIReadOnlyList_Success()
{
var desiredValue = new GenericBodyIReadOnlyListModel<string>
GenericBodyIReadOnlyListModel<string>
{ desiredValue = new GenericBodyIReadOnlyListModel<string>
{
Value = []
Value = [],
};
var value = JsonSerializer.Deserialize<GenericBodyIReadOnlyListModel<string>>(@"{ ""Value"": """" }", _jsonOptions);
GenericBodyIReadOnlyListModel<string value = JsonSerializer.Deserialize<GenericBodyIReadOnlyListModel<string>>(@"{ ""Value"": """" }", _jsonOptions);
Assert.Equal(desiredValue.Value, value?.Value);
}
[Fact]
public void Deserialize_String_Valid_Success()
{
var desiredValue = new GenericBodyArrayModel<string>
GenericBodyArrayModel<string>
{ desiredValue = new GenericBodyArrayModel<string>
{
Value = ["a", "b", "c"]
Value = ["a", "b", "c"],
};
var value = JsonSerializer.Deserialize<GenericBodyArrayModel<string>>(@"{ ""Value"": ""a,b,c"" }", _jsonOptions);
GenericBodyArrayModel<string value = JsonSerializer.Deserialize<GenericBodyArrayModel<string>>(@"{ ""Value"": ""a,b,c"" }", _jsonOptions);
Assert.Equal(desiredValue.Value, value?.Value);
}
[Fact]
public void Deserialize_StringList_Valid_Success()
{
var desiredValue = new GenericBodyListModel<string>
GenericBodyListModel<string>
{ desiredValue = new GenericBodyListModel<string>
{
Value = ["a", "b", "c"]
Value = ["a", "b", "c"],
};
Assert.Throws<InvalidOperationException>(() => JsonSerializer.Deserialize<GenericBodyListModel<string>>(@"{ ""Value"": ""a,b,c"" }", _jsonOptions));
@@ -92,93 +97,101 @@ namespace Jellyfin.Extensions.Tests.Json.Converters
[Fact]
public void Deserialize_String_Space_Valid_Success()
{
var desiredValue = new GenericBodyArrayModel<string>
GenericBodyArrayModel<string>
{ desiredValue = new GenericBodyArrayModel<string>
{
Value = ["a", "b", "c"]
Value = ["a", "b", "c"],
};
var value = JsonSerializer.Deserialize<GenericBodyArrayModel<string>>(@"{ ""Value"": ""a, b, c"" }", _jsonOptions);
GenericBodyArrayModel<string value = JsonSerializer.Deserialize<GenericBodyArrayModel<string>>(@"{ ""Value"": ""a, b, c"" }", _jsonOptions);
Assert.Equal(desiredValue.Value, value?.Value);
}
[Fact]
public void Deserialize_GenericCommandType_Valid_Success()
{
var desiredValue = new GenericBodyArrayModel<GeneralCommandType>
GenericBodyArrayModel<GeneralCommandType>
{ desiredValue = new GenericBodyArrayModel<GeneralCommandType>
{
Value = [GeneralCommandType.MoveUp, GeneralCommandType.MoveDown]
Value = [GeneralCommandType.MoveUp, GeneralCommandType.MoveDown],
};
var value = JsonSerializer.Deserialize<GenericBodyArrayModel<GeneralCommandType>>(@"{ ""Value"": ""MoveUp,MoveDown"" }", _jsonOptions);
GenericBodyArrayModel<GeneralCommandType value = JsonSerializer.Deserialize<GenericBodyArrayModel<GeneralCommandType>>(@"{ ""Value"": ""MoveUp,MoveDown"" }", _jsonOptions);
Assert.Equal(desiredValue.Value, value?.Value);
}
[Fact]
public void Deserialize_GenericCommandType_EmptyEntry_Success()
{
var desiredValue = new GenericBodyArrayModel<GeneralCommandType>
GenericBodyArrayModel<GeneralCommandType>
{ desiredValue = new GenericBodyArrayModel<GeneralCommandType>
{
Value = [GeneralCommandType.MoveUp, GeneralCommandType.MoveDown]
Value = [GeneralCommandType.MoveUp, GeneralCommandType.MoveDown],
};
var value = JsonSerializer.Deserialize<GenericBodyArrayModel<GeneralCommandType>>(@"{ ""Value"": ""MoveUp,,MoveDown"" }", _jsonOptions);
GenericBodyArrayModel<GeneralCommandType value = JsonSerializer.Deserialize<GenericBodyArrayModel<GeneralCommandType>>(@"{ ""Value"": ""MoveUp,,MoveDown"" }", _jsonOptions);
Assert.Equal(desiredValue.Value, value?.Value);
}
[Fact]
public void Deserialize_GenericCommandType_Invalid_Success()
{
var desiredValue = new GenericBodyArrayModel<GeneralCommandType>
GenericBodyArrayModel<GeneralCommandType>
{ desiredValue = new GenericBodyArrayModel<GeneralCommandType>
{
Value = [GeneralCommandType.MoveUp, GeneralCommandType.MoveDown]
Value = [GeneralCommandType.MoveUp, GeneralCommandType.MoveDown],
};
var value = JsonSerializer.Deserialize<GenericBodyArrayModel<GeneralCommandType>>(@"{ ""Value"": ""MoveUp,TotallyNotAValidCommand,MoveDown"" }", _jsonOptions);
GenericBodyArrayModel<GeneralCommandType value = JsonSerializer.Deserialize<GenericBodyArrayModel<GeneralCommandType>>(@"{ ""Value"": ""MoveUp,TotallyNotAValidCommand,MoveDown"" }", _jsonOptions);
Assert.Equal(desiredValue.Value, value?.Value);
}
[Fact]
public void Deserialize_GenericCommandType_Space_Valid_Success()
{
var desiredValue = new GenericBodyArrayModel<GeneralCommandType>
GenericBodyArrayModel<GeneralCommandType>
{ desiredValue = new GenericBodyArrayModel<GeneralCommandType>
{
Value = [GeneralCommandType.MoveUp, GeneralCommandType.MoveDown]
Value = [GeneralCommandType.MoveUp, GeneralCommandType.MoveDown],
};
var value = JsonSerializer.Deserialize<GenericBodyArrayModel<GeneralCommandType>>(@"{ ""Value"": ""MoveUp, MoveDown"" }", _jsonOptions);
GenericBodyArrayModel<GeneralCommandType value = JsonSerializer.Deserialize<GenericBodyArrayModel<GeneralCommandType>>(@"{ ""Value"": ""MoveUp, MoveDown"" }", _jsonOptions);
Assert.Equal(desiredValue.Value, value?.Value);
}
[Fact]
public void Deserialize_String_Array_Valid_Success()
{
var desiredValue = new GenericBodyArrayModel<string>
GenericBodyArrayModel<string>
{ desiredValue = new GenericBodyArrayModel<string>
{
Value = ["a", "b", "c"]
Value = ["a", "b", "c"],
};
var value = JsonSerializer.Deserialize<GenericBodyArrayModel<string>>(@"{ ""Value"": [""a"",""b"",""c""] }", _jsonOptions);
GenericBodyArrayModel<string value = JsonSerializer.Deserialize<GenericBodyArrayModel<string>>(@"{ ""Value"": [""a"",""b"",""c""] }", _jsonOptions);
Assert.Equal(desiredValue.Value, value?.Value);
}
[Fact]
public void Deserialize_GenericCommandType_Array_Valid_Success()
{
var desiredValue = new GenericBodyArrayModel<GeneralCommandType>
GenericBodyArrayModel<GeneralCommandType>
{ desiredValue = new GenericBodyArrayModel<GeneralCommandType>
{
Value = [GeneralCommandType.MoveUp, GeneralCommandType.MoveDown]
Value = [GeneralCommandType.MoveUp, GeneralCommandType.MoveDown],
};
var value = JsonSerializer.Deserialize<GenericBodyArrayModel<GeneralCommandType>>(@"{ ""Value"": [""MoveUp"", ""MoveDown""] }", _jsonOptions);
GenericBodyArrayModel<GeneralCommandType value = JsonSerializer.Deserialize<GenericBodyArrayModel<GeneralCommandType>>(@"{ ""Value"": [""MoveUp"", ""MoveDown""] }", _jsonOptions);
Assert.Equal(desiredValue.Value, value?.Value);
}
[Fact]
public void Serialize_GenericCommandType_ReadOnlyArray_Valid_Success()
{
var valueToSerialize = new GenericBodyIReadOnlyCollectionModel<GeneralCommandType>
GenericBodyIReadOnlyCollectionModel<GeneralCommandType>
{ valueToSerialize = new GenericBodyIReadOnlyCollectionModel<GeneralCommandType>
{
Value = new[] { GeneralCommandType.MoveUp, GeneralCommandType.MoveDown }.AsReadOnly()
Value = new[] { GeneralCommandType.MoveUp, GeneralCommandType.MoveDown }.AsReadOnly(),
};
string value = JsonSerializer.Serialize<GenericBodyIReadOnlyCollectionModel<GeneralCommandType>>(valueToSerialize, _jsonOptions);
@@ -188,9 +201,10 @@ namespace Jellyfin.Extensions.Tests.Json.Converters
[Fact]
public void Serialize_GenericCommandType_ImmutableArrayArray_Valid_Success()
{
var valueToSerialize = new GenericBodyIReadOnlyCollectionModel<GeneralCommandType>
GenericBodyIReadOnlyCollectionModel<GeneralCommandType>
{ valueToSerialize = new GenericBodyIReadOnlyCollectionModel<GeneralCommandType>
{
Value = ImmutableArray.Create(new[] { GeneralCommandType.MoveUp, GeneralCommandType.MoveDown })
Value = ImmutableArray.Create(new[] { GeneralCommandType.MoveUp, GeneralCommandType.MoveDown }),
};
string value = JsonSerializer.Serialize<GenericBodyIReadOnlyCollectionModel<GeneralCommandType>>(valueToSerialize, _jsonOptions);
@@ -200,9 +214,10 @@ namespace Jellyfin.Extensions.Tests.Json.Converters
[Fact]
public void Serialize_GenericCommandType_List_Valid_Success()
{
var valueToSerialize = new GenericBodyIReadOnlyListModel<GeneralCommandType>
GenericBodyIReadOnlyListModel<GeneralCommandType>
{ valueToSerialize = new GenericBodyIReadOnlyListModel<GeneralCommandType>
{
Value = new List<GeneralCommandType> { GeneralCommandType.MoveUp, GeneralCommandType.MoveDown }
Value = new List<GeneralCommandType> { GeneralCommandType.MoveUp, GeneralCommandType.MoveDown },
};
string value = JsonSerializer.Serialize<GenericBodyIReadOnlyListModel<GeneralCommandType>>(valueToSerialize, _jsonOptions);
@@ -17,88 +17,95 @@ namespace Jellyfin.Extensions.Tests.Json.Converters
{
Converters =
{
new JsonStringEnumConverter()
}
new JsonStringEnumConverter(),
},
};
[Fact]
public void Deserialize_String_Valid_Success()
{
var desiredValue = new GenericBodyIReadOnlyListModel<string>
GenericBodyIReadOnlyListModel<string>
{ desiredValue = new GenericBodyIReadOnlyListModel<string>
{
Value = new[] { "a", "b", "c" }
Value = new[] { "a", "b", "c" },
};
var value = JsonSerializer.Deserialize<GenericBodyIReadOnlyListModel<string>>(@"{ ""Value"": ""a,b,c"" }", _jsonOptions);
GenericBodyIReadOnlyListModel<string value = JsonSerializer.Deserialize<GenericBodyIReadOnlyListModel<string>>(@"{ ""Value"": ""a,b,c"" }", _jsonOptions);
Assert.Equal(desiredValue.Value, value?.Value);
}
[Fact]
public void Deserialize_String_Space_Valid_Success()
{
var desiredValue = new GenericBodyIReadOnlyListModel<string>
GenericBodyIReadOnlyListModel<string>
{ desiredValue = new GenericBodyIReadOnlyListModel<string>
{
Value = new[] { "a", "b", "c" }
Value = new[] { "a", "b", "c" },
};
var value = JsonSerializer.Deserialize<GenericBodyIReadOnlyListModel<string>>(@"{ ""Value"": ""a, b, c"" }", _jsonOptions);
GenericBodyIReadOnlyListModel<string value = JsonSerializer.Deserialize<GenericBodyIReadOnlyListModel<string>>(@"{ ""Value"": ""a, b, c"" }", _jsonOptions);
Assert.Equal(desiredValue.Value, value?.Value);
}
[Fact]
public void Deserialize_GenericCommandType_Valid_Success()
{
var desiredValue = new GenericBodyIReadOnlyListModel<GeneralCommandType>
GenericBodyIReadOnlyListModel<GeneralCommandType>
{ desiredValue = new GenericBodyIReadOnlyListModel<GeneralCommandType>
{
Value = new[] { GeneralCommandType.MoveUp, GeneralCommandType.MoveDown }
Value = new[] { GeneralCommandType.MoveUp, GeneralCommandType.MoveDown },
};
var value = JsonSerializer.Deserialize<GenericBodyIReadOnlyListModel<GeneralCommandType>>(@"{ ""Value"": ""MoveUp,MoveDown"" }", _jsonOptions);
GenericBodyIReadOnlyListModel<GeneralCommandType value = JsonSerializer.Deserialize<GenericBodyIReadOnlyListModel<GeneralCommandType>>(@"{ ""Value"": ""MoveUp,MoveDown"" }", _jsonOptions);
Assert.Equal(desiredValue.Value, value?.Value);
}
[Fact]
public void Deserialize_GenericCommandType_Space_Valid_Success()
{
var desiredValue = new GenericBodyIReadOnlyListModel<GeneralCommandType>
GenericBodyIReadOnlyListModel<GeneralCommandType>
{ desiredValue = new GenericBodyIReadOnlyListModel<GeneralCommandType>
{
Value = new[] { GeneralCommandType.MoveUp, GeneralCommandType.MoveDown }
Value = new[] { GeneralCommandType.MoveUp, GeneralCommandType.MoveDown },
};
var value = JsonSerializer.Deserialize<GenericBodyIReadOnlyListModel<GeneralCommandType>>(@"{ ""Value"": ""MoveUp, MoveDown"" }", _jsonOptions);
GenericBodyIReadOnlyListModel<GeneralCommandType value = JsonSerializer.Deserialize<GenericBodyIReadOnlyListModel<GeneralCommandType>>(@"{ ""Value"": ""MoveUp, MoveDown"" }", _jsonOptions);
Assert.Equal(desiredValue.Value, value?.Value);
}
[Fact]
public void Deserialize_String_Array_Valid_Success()
{
var desiredValue = new GenericBodyIReadOnlyListModel<string>
GenericBodyIReadOnlyListModel<string>
{ desiredValue = new GenericBodyIReadOnlyListModel<string>
{
Value = new[] { "a", "b", "c" }
Value = new[] { "a", "b", "c" },
};
var value = JsonSerializer.Deserialize<GenericBodyIReadOnlyListModel<string>>(@"{ ""Value"": [""a"",""b"",""c""] }", _jsonOptions);
GenericBodyIReadOnlyListModel<string value = JsonSerializer.Deserialize<GenericBodyIReadOnlyListModel<string>>(@"{ ""Value"": [""a"",""b"",""c""] }", _jsonOptions);
Assert.Equal(desiredValue.Value, value?.Value);
}
[Fact]
public void Deserialize_GenericCommandType_Array_Valid_Success()
{
var desiredValue = new GenericBodyIReadOnlyListModel<GeneralCommandType>
GenericBodyIReadOnlyListModel<GeneralCommandType>
{ desiredValue = new GenericBodyIReadOnlyListModel<GeneralCommandType>
{
Value = new[] { GeneralCommandType.MoveUp, GeneralCommandType.MoveDown }
Value = new[] { GeneralCommandType.MoveUp, GeneralCommandType.MoveDown },
};
var value = JsonSerializer.Deserialize<GenericBodyIReadOnlyListModel<GeneralCommandType>>(@"{ ""Value"": [""MoveUp"", ""MoveDown""] }", _jsonOptions);
GenericBodyIReadOnlyListModel<GeneralCommandType value = JsonSerializer.Deserialize<GenericBodyIReadOnlyListModel<GeneralCommandType>>(@"{ ""Value"": [""MoveUp"", ""MoveDown""] }", _jsonOptions);
Assert.Equal(desiredValue.Value, value?.Value);
}
[Fact]
public void Serialize_GenericCommandType_IReadOnlyList_Valid_Success()
{
var valueToSerialize = new GenericBodyIReadOnlyListModel<GeneralCommandType>
GenericBodyIReadOnlyListModel<GeneralCommandType>
{ valueToSerialize = new GenericBodyIReadOnlyListModel<GeneralCommandType>
{
Value = new List<GeneralCommandType> { GeneralCommandType.MoveUp, GeneralCommandType.MoveDown }
Value = new List<GeneralCommandType> { GeneralCommandType.MoveUp, GeneralCommandType.MoveDown },
};
string value = JsonSerializer.Serialize<GenericBodyIReadOnlyListModel<GeneralCommandType>>(valueToSerialize, _jsonOptions);
@@ -24,7 +24,7 @@ public class JsonDefaultStringEnumConverterTests
[InlineData("\"Hls\"", MediaStreamProtocol.hls)]
public void Deserialize_Enum_Direct(string input, MediaStreamProtocol output)
{
var value = JsonSerializer.Deserialize<MediaStreamProtocol>(input, _jsonOptions);
MediaStreamProtocol value = JsonSerializer.Deserialize<MediaStreamProtocol>(input, _jsonOptions);
Assert.Equal(output, value);
}
@@ -42,7 +42,7 @@ public class JsonDefaultStringEnumConverterTests
{
input ??= "null";
var json = $"{{ \"EnumValue\": {input} }}";
var value = JsonSerializer.Deserialize<TestClass>(json, _jsonOptions);
TestClass value = JsonSerializer.Deserialize<TestClass>(json, _jsonOptions);
Assert.NotNull(value);
Assert.Equal(output, value.EnumValue);
}
@@ -62,7 +62,7 @@ public class JsonDefaultStringEnumConverterTests
{
input ??= "null";
var json = $"{{ \"EnumValue\": {input} }}";
var value = JsonSerializer.Deserialize<NullTestClass>(json, _jsonOptions);
NullTestClass value = JsonSerializer.Deserialize<NullTestClass>(json, _jsonOptions);
Assert.NotNull(value);
Assert.Equal(output, value.EnumValue);
}
@@ -15,8 +15,8 @@ public class JsonFlagEnumTests
{
Converters =
{
new JsonFlagEnumConverter<TranscodeReason>()
}
new JsonFlagEnumConverter<TranscodeReason>(),
},
};
[Theory]
@@ -14,8 +14,8 @@ namespace Jellyfin.Extensions.Tests.Json.Converters
{
Converters =
{
new JsonStringConverter()
}
new JsonStringConverter(),
},
};
[Theory]
@@ -1,6 +1,6 @@
{
"version": 2,
"dgSpecHash": "en/g4Rojfa8=",
"dgSpecHash": "cBK/w0WVJEs=",
"success": true,
"projectFilePath": "E:\\Projects\\pgsql-jellyfin\\tests\\Jellyfin.Extensions.Tests\\Jellyfin.Extensions.Tests.csproj",
"expectedPackageFiles": [
@@ -1,6 +1,6 @@
{
"version": 2,
"dgSpecHash": "YQ4opaxxEO8=",
"dgSpecHash": "nbns8k6jJuA=",
"success": true,
"projectFilePath": "E:\\Projects\\pgsql-jellyfin\\tests\\Jellyfin.LiveTv.Tests\\Jellyfin.LiveTv.Tests.csproj",
"expectedPackageFiles": [
@@ -1,6 +1,6 @@
{
"version": 2,
"dgSpecHash": "/lT1/xD3XnU=",
"dgSpecHash": "hvFFds1OJpc=",
"success": true,
"projectFilePath": "E:\\Projects\\pgsql-jellyfin\\tests\\Jellyfin.MediaEncoding.Hls.Tests\\Jellyfin.MediaEncoding.Hls.Tests.csproj",
"expectedPackageFiles": [
@@ -1,6 +1,6 @@
{
"version": 2,
"dgSpecHash": "0nvUEzLEN94=",
"dgSpecHash": "5g3aj0khPqM=",
"success": true,
"projectFilePath": "E:\\Projects\\pgsql-jellyfin\\tests\\Jellyfin.MediaEncoding.Keyframes.Tests\\Jellyfin.MediaEncoding.Keyframes.Tests.csproj",
"expectedPackageFiles": [
@@ -1,6 +1,6 @@
{
"version": 2,
"dgSpecHash": "SBmVy71j/UM=",
"dgSpecHash": "2rGlge7UbGY=",
"success": true,
"projectFilePath": "E:\\Projects\\pgsql-jellyfin\\tests\\Jellyfin.MediaEncoding.Tests\\Jellyfin.MediaEncoding.Tests.csproj",
"expectedPackageFiles": [
@@ -53,8 +53,7 @@ namespace Jellyfin.Model.Tests.Cryptography
new Dictionary<string, string>()
{
{ "iterations", "1000" },
{ "m", "120" }
}));
{ "m", "120" },`r`n }));
// Id + hash
data.Add(
@@ -83,7 +82,8 @@ namespace Jellyfin.Model.Tests.Cryptography
Array.Empty<byte>(),
new Dictionary<string, string>()
{
{ "iterations", "1000" }
{ "iterations", "1000" },
{ "iterations", "1000" },
}));
// Id + parameters + hash
data.Add(
@@ -95,7 +95,7 @@ namespace Jellyfin.Model.Tests.Cryptography
new Dictionary<string, string>()
{
{ "iterations", "1000" },
{ "m", "120" }
{ "m", "120" },
}));
// Id + parameters + salt + hash
data.Add(
@@ -107,7 +107,7 @@ namespace Jellyfin.Model.Tests.Cryptography
new Dictionary<string, string>()
{
{ "iterations", "1000" },
{ "m", "120" }
{ "m", "120" },
}));
return data;
}
@@ -1,6 +1,6 @@
{
"version": 2,
"dgSpecHash": "S2M6GE9E6Mw=",
"dgSpecHash": "E+3Xf4aE0A8=",
"success": true,
"projectFilePath": "E:\\Projects\\pgsql-jellyfin\\tests\\Jellyfin.Model.Tests\\Jellyfin.Model.Tests.csproj",
"expectedPackageFiles": [
@@ -29,6 +29,6 @@ namespace Jellyfin.Naming.Tests.AudioBook
var info1 = new AudioBookFileInfo(string.Empty, string.Empty);
var info2 = new AudioBookFileInfo(string.Empty, string.Empty);
Assert.Equal(0, info1.CompareTo(info2));
}
},
}
}
}
@@ -38,7 +38,7 @@ namespace Jellyfin.Naming.Tests.AudioBook
"Ready Player One (2020)/audiobook.mp3",
"Ready Player One (2020)/extra.mp3",
".mp3"
".mp3",
};
var resolver = GetResolver();
@@ -89,7 +89,7 @@ namespace Jellyfin.Naming.Tests.AudioBook
"Superman/extra.mp3",
"Batman/ Chapter 1 .mp3",
"Batman/Chapter 1[loss-less].mp3"
"Batman/Chapter 1[loss-less].mp3",
};
var resolver = GetResolver();
@@ -166,7 +166,7 @@ namespace Jellyfin.Naming.Tests.AudioBook
Name = " ",
Path = " .mp3",
Year = null
}
},
};
var resolver = GetResolver();
@@ -183,7 +183,7 @@ namespace Jellyfin.Naming.Tests.AudioBook
{
Assert.Equal(data[i].Name, result[i].Name);
Assert.Equal(data[i].Year, result[i].Year);
}
},
}
[Fact]
@@ -192,7 +192,7 @@ namespace Jellyfin.Naming.Tests.AudioBook
var files = new[]
{
"Harry Potter and the Deathly Hallows/Chapter 1.ogg",
"Harry Potter and the Deathly Hallows/Harry Potter and the Deathly Hallows.nfo"
"Harry Potter and the Deathly Hallows/Harry Potter and the Deathly Hallows.nfo",
};
var resolver = GetResolver();
@@ -212,7 +212,7 @@ namespace Jellyfin.Naming.Tests.AudioBook
var files = new[]
{
"Harry Potter and the Deathly Hallows/Chapter 1.mp3",
"Harry Potter and the Deathly Hallows/Harry Potter and the Deathly Hallows trailer.mp3"
"Harry Potter and the Deathly Hallows/Harry Potter and the Deathly Hallows trailer.mp3",
};
var resolver = GetResolver();
@@ -231,7 +231,7 @@ namespace Jellyfin.Naming.Tests.AudioBook
{
var files = new[]
{
"Harry Potter and the Deathly Hallows trailer.mp3"
"Harry Potter and the Deathly Hallows trailer.mp3",
};
var resolver = GetResolver();
@@ -271,6 +271,6 @@ namespace Jellyfin.Naming.Tests.AudioBook
public string Name;
public string Path;
public int? Year;
}
},
}
}
}
@@ -64,6 +64,6 @@ namespace Jellyfin.Naming.Tests.AudioBook
var result = new AudioBookResolver(_namingOptions).Resolve(string.Empty);
Assert.Null(result);
}
},
}
}
}
@@ -32,6 +32,6 @@ namespace Jellyfin.Naming.Tests.Common
exp.Expression = "test";
Assert.Equal("test", exp.Expression);
Assert.NotNull(exp.Regex);
}
},
}
}
}
@@ -122,4 +122,4 @@ public class ExternalPathParserTests
Assert.Equal(isForced, actual.IsForced);
Assert.Equal(isHearingImpaired, actual.IsHearingImpaired);
}
}
}
@@ -49,6 +49,6 @@ namespace Jellyfin.Naming.Tests.Music
var parser = new AlbumParser(_namingOptions);
Assert.Equal(result, parser.IsMultiPart(path));
}
},
}
}
}
@@ -25,6 +25,6 @@ namespace Jellyfin.Naming.Tests.TV
var result = _resolver.Resolve(path, false, null, null, true);
Assert.Equal(episodeNumber, result?.EpisodeNumber);
}
},
}
}
}
@@ -31,6 +31,6 @@ namespace Jellyfin.Naming.Tests.TV
Assert.Equal(month, result?.Month);
Assert.Equal(day, result?.Day);
Assert.Equal(seriesName, result?.SeriesName, true);
}
},
}
}
}
@@ -95,6 +95,6 @@ namespace Jellyfin.Naming.Tests.TV
.Parse(path, false);
Assert.Equal(expected, result.EpisodeNumber);
}
},
}
}
}
@@ -33,6 +33,6 @@ namespace Jellyfin.Naming.Tests.TV
var result = _resolver.Resolve(path, false);
Assert.Equal(episodeNumber, result?.EpisodeNumber);
}
},
}
}
}
@@ -103,6 +103,6 @@ namespace Jellyfin.Naming.Tests.TV
var res = p.Parse("ABC_2019_10_21 11:00:00", false);
Assert.True(res.Success);
}
},
}
}
}
@@ -78,6 +78,6 @@ namespace Jellyfin.Naming.Tests.TV
var result = _episodePathParser.Parse(filename, false);
Assert.Equal(result.EndingEpisodeNumber, endingEpisodeNumber);
}
},
}
}
}
@@ -63,6 +63,6 @@ namespace Jellyfin.Naming.Tests.TV
var result = _resolver.Resolve(path, false);
Assert.Equal(expected, result?.SeasonNumber);
}
},
}
}
}
@@ -87,4 +87,4 @@ public class SeasonPathParserTests
Assert.Equal(seasonNumber, result.SeasonNumber);
Assert.Equal(isSeasonDirectory, result.IsSeasonFolder);
}
}
}
@@ -28,6 +28,6 @@ namespace Jellyfin.Naming.Tests.TV
Assert.Equal(name, res.SeriesName);
Assert.True(res.Success);
}
},
}
}
}
@@ -29,6 +29,6 @@ namespace Jellyfin.Naming.Tests.TV
var res = SeriesResolver.Resolve(_namingOptions, path);
Assert.Equal(name, res.Name);
}
},
}
}
}
@@ -48,6 +48,6 @@ namespace Jellyfin.Naming.Tests.TV
Assert.Null(result!.StubType);
Assert.Equal(episodeEndNumber, result!.EndingEpisodeNumber);
Assert.False(result!.IsByDate);
}
},
}
}
}
@@ -32,4 +32,4 @@ public class TvParserHelpersTest
Assert.False(successful);
Assert.Null(parsed);
}
}
}
@@ -65,6 +65,6 @@ namespace Jellyfin.Naming.Tests.Video
Assert.Equal(expectedName, result.Name, true);
Assert.Equal(expectedYear, result.Year);
}
},
}
}
}
@@ -52,6 +52,6 @@ namespace Jellyfin.Naming.Tests.Video
{
Assert.False(VideoResolver.TryCleanString(input, _namingOptions, out var newName));
Assert.True(string.IsNullOrEmpty(newName));
}
},
}
}
}
@@ -166,6 +166,6 @@ namespace Jellyfin.Naming.Tests.Video
var res = ExtraRuleResolver.GetExtraInfo("extra.mp4", options);
Assert.Equal(rule, res.Rule);
}
},
}
}
}
@@ -72,7 +72,7 @@ namespace Jellyfin.Naming.Tests.Video
else
{
Assert.Equal(format3D, result.Format3D, true);
}
}
},
},
}
}
}
@@ -22,7 +22,7 @@ namespace Jellyfin.Naming.Tests.Video
"/movies/X-Men Days of Future Past/X-Men Days of Future Past - 1080p.mkv",
"/movies/X-Men Days of Future Past/X-Men Days of Future Past-trailer.mp4",
"/movies/X-Men Days of Future Past/X-Men Days of Future Past - [hsbs].mkv",
"/movies/X-Men Days of Future Past/X-Men Days of Future Past [hsbs].mkv"
"/movies/X-Men Days of Future Past/X-Men Days of Future Past [hsbs].mkv",
};
var result = VideoListResolver.Resolve(
@@ -41,7 +41,7 @@ namespace Jellyfin.Naming.Tests.Video
"/movies/X-Men Days of Future Past/X-Men Days of Future Past - apple.mkv",
"/movies/X-Men Days of Future Past/X-Men Days of Future Past-trailer.mp4",
"/movies/X-Men Days of Future Past/X-Men Days of Future Past - banana.mkv",
"/movies/X-Men Days of Future Past/X-Men Days of Future Past [banana].mp4"
"/movies/X-Men Days of Future Past/X-Men Days of Future Past [banana].mp4",
};
var result = VideoListResolver.Resolve(
@@ -59,7 +59,7 @@ namespace Jellyfin.Naming.Tests.Video
var files = new[]
{
"/movies/The Phantom of the Opera (1925)/The Phantom of the Opera (1925) - 1925 version.mkv",
"/movies/The Phantom of the Opera (1925)/The Phantom of the Opera (1925) - 1929 version.mkv"
"/movies/The Phantom of the Opera (1925)/The Phantom of the Opera (1925) - 1929 version.mkv",
};
var result = VideoListResolver.Resolve(
@@ -81,7 +81,7 @@ namespace Jellyfin.Naming.Tests.Video
"/movies/M/Movie 4.mkv",
"/movies/M/Movie 5.mkv",
"/movies/M/Movie 6.mkv",
"/movies/M/Movie 7.mkv"
"/movies/M/Movie 7.mkv",
};
var result = VideoListResolver.Resolve(
@@ -104,7 +104,7 @@ namespace Jellyfin.Naming.Tests.Video
"/movies/Movie/Movie-5.mkv",
"/movies/Movie/Movie-6.mkv",
"/movies/Movie/Movie-7.mkv",
"/movies/Movie/Movie-8.mkv"
"/movies/Movie/Movie-8.mkv",
};
var result = VideoListResolver.Resolve(
@@ -128,7 +128,7 @@ namespace Jellyfin.Naming.Tests.Video
"/movies/Mo/Movie 6.mkv",
"/movies/Mo/Movie 7.mkv",
"/movies/Mo/Movie 8.mkv",
"/movies/Mo/Movie 9.mkv"
"/movies/Mo/Movie 9.mkv",
};
var result = VideoListResolver.Resolve(
@@ -148,7 +148,7 @@ namespace Jellyfin.Naming.Tests.Video
"/movies/Movie/Movie 2.mkv",
"/movies/Movie/Movie 3.mkv",
"/movies/Movie/Movie 4.mkv",
"/movies/Movie/Movie 5.mkv"
"/movies/Movie/Movie 5.mkv",
};
var result = VideoListResolver.Resolve(
@@ -170,7 +170,7 @@ namespace Jellyfin.Naming.Tests.Video
"/movies/Iron Man/Iron Man (2008).mkv",
"/movies/Iron Man/Iron Man (2009).mkv",
"/movies/Iron Man/Iron Man (2010).mkv",
"/movies/Iron Man/Iron Man (2011).mkv"
"/movies/Iron Man/Iron Man (2011).mkv",
};
var result = VideoListResolver.Resolve(
@@ -192,7 +192,7 @@ namespace Jellyfin.Naming.Tests.Video
"/movies/Iron Man/Iron Man-bluray.mkv",
"/movies/Iron Man/Iron Man-3d.mkv",
"/movies/Iron Man/Iron Man-3d-hsbs.mkv",
"/movies/Iron Man/Iron Man[test].mkv"
"/movies/Iron Man/Iron Man[test].mkv",
};
var result = VideoListResolver.Resolve(
@@ -221,7 +221,7 @@ namespace Jellyfin.Naming.Tests.Video
"/movies/Iron Man/Iron Man - bluray.mkv",
"/movies/Iron Man/Iron Man - 3d.mkv",
"/movies/Iron Man/Iron Man - 3d-hsbs.mkv",
"/movies/Iron Man/Iron Man [test].mkv"
"/movies/Iron Man/Iron Man [test].mkv",
};
var result = VideoListResolver.Resolve(
@@ -245,7 +245,7 @@ namespace Jellyfin.Naming.Tests.Video
var files = new[]
{
"/movies/Iron Man/Iron Man - B (2006).mkv",
"/movies/Iron Man/Iron Man - C (2007).mkv"
"/movies/Iron Man/Iron Man - C (2007).mkv",
};
var result = VideoListResolver.Resolve(
@@ -266,7 +266,7 @@ namespace Jellyfin.Naming.Tests.Video
"/movies/Iron Man/Iron Man_bluray.mkv",
"/movies/Iron Man/Iron Man_3d.mkv",
"/movies/Iron Man/Iron Man_3d-hsbs.mkv",
"/movies/Iron Man/Iron Man_3d.hsbs.mkv"
"/movies/Iron Man/Iron Man_3d.hsbs.mkv",
};
var result = VideoListResolver.Resolve(
@@ -288,7 +288,7 @@ namespace Jellyfin.Naming.Tests.Video
"/movies/Iron Man/Iron Man (2008).mkv",
"/movies/Iron Man/Iron Man (2009).mkv",
"/movies/Iron Man/Iron Man (2010).mkv",
"/movies/Iron Man/Iron Man (2011).mkv"
"/movies/Iron Man/Iron Man (2011).mkv",
};
var result = VideoListResolver.Resolve(
@@ -305,7 +305,7 @@ namespace Jellyfin.Naming.Tests.Video
var files = new[]
{
"/movies/Blade Runner (1982)/Blade Runner (1982) [Final Cut] [1080p HEVC AAC].mkv",
"/movies/Blade Runner (1982)/Blade Runner (1982) [EE by ADM] [480p HEVC AAC,AAC,AAC].mkv"
"/movies/Blade Runner (1982)/Blade Runner (1982) [EE by ADM] [480p HEVC AAC,AAC,AAC].mkv",
};
var result = VideoListResolver.Resolve(
@@ -322,7 +322,7 @@ namespace Jellyfin.Naming.Tests.Video
var files = new[]
{
"/movies/X-Men Apocalypse (2016)/X-Men Apocalypse (2016) [1080p] Blu-ray.x264.DTS.mkv",
"/movies/X-Men Apocalypse (2016)/X-Men Apocalypse (2016) [2160p] Blu-ray.x265.AAC.mkv"
"/movies/X-Men Apocalypse (2016)/X-Men Apocalypse (2016) [2160p] Blu-ray.x265.AAC.mkv",
};
var result = VideoListResolver.Resolve(
@@ -405,7 +405,7 @@ namespace Jellyfin.Naming.Tests.Video
var files = new[]
{
"/movies/John Wick - Kapitel 3 (2019) [imdbid=tt6146586]/John Wick - Kapitel 3 (2019) [imdbid=tt6146586] - Version 1.mkv",
"/movies/John Wick - Kapitel 3 (2019) [imdbid=tt6146586]/John Wick - Kapitel 3 (2019) [imdbid=tt6146586] - Version 2.mkv"
"/movies/John Wick - Kapitel 3 (2019) [imdbid=tt6146586]/John Wick - Kapitel 3 (2019) [imdbid=tt6146586] - Version 2.mkv",
};
var result = VideoListResolver.Resolve(
@@ -422,7 +422,7 @@ namespace Jellyfin.Naming.Tests.Video
var files = new[]
{
"/movies/John Wick - Chapter 3 (2019)/John Wick - Chapter 3 (2019) [Version 1].mkv",
"/movies/John Wick - Chapter 3 (2019)/John Wick - Chapter 3 (2019) [Version 2.mkv"
"/movies/John Wick - Chapter 3 (2019)/John Wick - Chapter 3 (2019) [Version 2.mkv",
};
var result = VideoListResolver.Resolve(
@@ -438,6 +438,6 @@ namespace Jellyfin.Naming.Tests.Video
var result = VideoListResolver.Resolve(new List<VideoFileInfo>(), _namingOptions).ToList();
Assert.Empty(result);
}
},
}
}
}
+24 -24
View File
@@ -23,7 +23,7 @@ namespace Jellyfin.Naming.Tests.Video
"Bad Boys (2006) part2.mkv",
"Bad Boys (2006) part3.mkv",
"Bad Boys (2006) part4.mkv",
"Bad Boys (2006)-trailer.mkv"
"Bad Boys (2006)-trailer.mkv",
};
var result = StackResolver.ResolveFiles(files, _namingOptions).ToList();
@@ -38,7 +38,7 @@ namespace Jellyfin.Naming.Tests.Video
var files = new[]
{
"Bad Boys (2006).mkv",
"Bad Boys (2007).mkv"
"Bad Boys (2007).mkv",
};
var result = StackResolver.ResolveFiles(files, _namingOptions).ToList();
@@ -52,7 +52,7 @@ namespace Jellyfin.Naming.Tests.Video
var files = new[]
{
"Bad Boys 2006.mkv",
"Bad Boys 2007.mkv"
"Bad Boys 2007.mkv",
};
var result = StackResolver.ResolveFiles(files, _namingOptions).ToList();
@@ -66,7 +66,7 @@ namespace Jellyfin.Naming.Tests.Video
var files = new[]
{
"300 (2006).mkv",
"300 (2007).mkv"
"300 (2007).mkv",
};
var result = StackResolver.ResolveFiles(files, _namingOptions).ToList();
@@ -80,7 +80,7 @@ namespace Jellyfin.Naming.Tests.Video
var files = new[]
{
"300 2006.mkv",
"300 2007.mkv"
"300 2007.mkv",
};
var result = StackResolver.ResolveFiles(files, _namingOptions).ToList();
@@ -94,7 +94,7 @@ namespace Jellyfin.Naming.Tests.Video
var files = new[]
{
"Star Trek 1 - The motion picture.mkv",
"Star Trek 2- The wrath of khan.mkv"
"Star Trek 2- The wrath of khan.mkv",
};
var result = StackResolver.ResolveFiles(files, _namingOptions).ToList();
@@ -108,7 +108,7 @@ namespace Jellyfin.Naming.Tests.Video
{
"Red Riding in the Year of Our Lord 1983 (2009).mkv",
"Red Riding in the Year of Our Lord 1980 (2009).mkv",
"Red Riding in the Year of Our Lord 1974 (2009).mkv"
"Red Riding in the Year of Our Lord 1974 (2009).mkv",
};
var result = StackResolver.ResolveFiles(files, _namingOptions).ToList();
@@ -122,7 +122,7 @@ namespace Jellyfin.Naming.Tests.Video
var files = new[]
{
"d:/movies/300 2006 part1.mkv",
"d:/movies/300 2006 part2.mkv"
"d:/movies/300 2006 part2.mkv",
};
var result = StackResolver.ResolveFiles(files, _namingOptions).ToList();
@@ -140,7 +140,7 @@ namespace Jellyfin.Naming.Tests.Video
"Bad Boys (2006).part2.stv.unrated.multi.1080p.bluray.x264-rough.mkv",
"Bad Boys (2006).part3.stv.unrated.multi.1080p.bluray.x264-rough.mkv",
"Bad Boys (2006).part4.stv.unrated.multi.1080p.bluray.x264-rough.mkv",
"Bad Boys (2006)-trailer.mkv"
"Bad Boys (2006)-trailer.mkv",
};
var result = StackResolver.ResolveFiles(files, _namingOptions).ToList();
@@ -157,7 +157,7 @@ namespace Jellyfin.Naming.Tests.Video
"Bad Boys (2006) 1.mkv",
"Bad Boys (2006) 2.mkv",
"Bad Boys (2006) 3.mkv",
"Bad Boys (2006)-trailer.mkv"
"Bad Boys (2006)-trailer.mkv",
};
var result = StackResolver.ResolveFiles(files, _namingOptions).ToList();
@@ -174,7 +174,7 @@ namespace Jellyfin.Naming.Tests.Video
"300 (2006) part2.mkv",
"300 (2006) part3.mkv",
"300 (2006) part4.mkv",
"300 (2006)-trailer.mkv"
"300 (2006)-trailer.mkv",
};
var result = StackResolver.ResolveFiles(files, _namingOptions).ToList();
@@ -192,7 +192,7 @@ namespace Jellyfin.Naming.Tests.Video
"Bad Boys (2006) part2.mkv",
"Bad Boys (2006) part3.mkv",
"Bad Boys (2006) parta.mkv",
"Bad Boys (2006)-trailer.mkv"
"Bad Boys (2006)-trailer.mkv",
};
var result = StackResolver.ResolveFiles(files, _namingOptions).ToList();
@@ -214,7 +214,7 @@ namespace Jellyfin.Naming.Tests.Video
"300 (2006) part1.mkv",
"300 (2006) part2.mkv",
"300 (2006) part3.mkv",
"300 (2006)-trailer.mkv"
"300 (2006)-trailer.mkv",
};
var result = StackResolver.ResolveFiles(files, _namingOptions).ToList();
@@ -230,7 +230,7 @@ namespace Jellyfin.Naming.Tests.Video
var files = new[]
{
"blah blah - cd 1",
"blah blah - cd 2"
"blah blah - cd 2",
};
var result = StackResolver.ResolveDirectories(files, _namingOptions).ToList();
@@ -247,7 +247,7 @@ namespace Jellyfin.Naming.Tests.Video
"300a.mkv",
"300b.mkv",
"300c.mkv",
"300-trailer.mkv"
"300-trailer.mkv",
};
var result = StackResolver.ResolveFiles(files, _namingOptions).ToList();
@@ -266,7 +266,7 @@ namespace Jellyfin.Naming.Tests.Video
"Avatar",
"Avengers part1.mkv",
"Avengers part2.mkv",
"Avengers part3.mkv"
"Avengers part3.mkv",
};
var result = StackResolver.ResolveFiles(files, _namingOptions).ToList();
@@ -295,7 +295,7 @@ namespace Jellyfin.Naming.Tests.Video
"300a.mkv",
"300b.mkv",
"300c.mkv",
"300-trailer.mkv"
"300-trailer.mkv",
};
var result = StackResolver.ResolveFiles(files, _namingOptions).ToList();
@@ -319,7 +319,7 @@ namespace Jellyfin.Naming.Tests.Video
"300 (2006) parte.mkv",
"300 (2006) partf.mkv",
"300 (2006) partg.mkv",
"300 (2006)-trailer.mkv"
"300 (2006)-trailer.mkv",
};
var result = StackResolver.ResolveFiles(files, _namingOptions).ToList();
@@ -338,7 +338,7 @@ namespace Jellyfin.Naming.Tests.Video
new FileSystemMetadata { FullName = "Bad Boys (2006) part2.mkv", IsDirectory = false },
new FileSystemMetadata { FullName = "300 (2006) part2", IsDirectory = true },
new FileSystemMetadata { FullName = "300 (2006) part3", IsDirectory = true },
new FileSystemMetadata { FullName = "300 (2006) part1", IsDirectory = true }
new FileSystemMetadata { FullName = "300 (2006) part1", IsDirectory = true },
};
var result = StackResolver.Resolve(files, _namingOptions).ToList();
@@ -358,7 +358,7 @@ namespace Jellyfin.Naming.Tests.Video
"Harry Potter and the Deathly Hallows 1.mkv",
"Harry Potter and the Deathly Hallows 2.mkv",
"Harry Potter and the Deathly Hallows 3.mkv",
"Harry Potter and the Deathly Hallows 4.mkv"
"Harry Potter and the Deathly Hallows 4.mkv",
};
var result = StackResolver.ResolveFiles(files, _namingOptions).ToList();
@@ -373,7 +373,7 @@ namespace Jellyfin.Naming.Tests.Video
var files = new[]
{
"Neverland (2011)[720p][PG][Voted 6.5][Family-Fantasy]part1.mkv",
"Neverland (2011)[720p][PG][Voted 6.5][Family-Fantasy]part2.mkv"
"Neverland (2011)[720p][PG][Voted 6.5][Family-Fantasy]part2.mkv",
};
var result = StackResolver.ResolveFiles(files, _namingOptions).ToList();
@@ -389,7 +389,7 @@ namespace Jellyfin.Naming.Tests.Video
var files = new[]
{
"M:/Movies (DVD)/Movies (Musical)/The Sound of Music/The Sound of Music (1965) (Disc 01)",
"M:/Movies (DVD)/Movies (Musical)/The Sound of Music/The Sound of Music (1965) (Disc 02)"
"M:/Movies (DVD)/Movies (Musical)/The Sound of Music/The Sound of Music (1965) (Disc 02)",
};
var result = StackResolver.ResolveDirectories(files, _namingOptions).ToList();
@@ -402,6 +402,6 @@ namespace Jellyfin.Naming.Tests.Video
{
Assert.Equal(fileCount, stack.Files.Count);
Assert.Equal(name, stack.Name);
}
},
}
}
}
@@ -51,7 +51,7 @@ namespace Jellyfin.Naming.Tests.Video
else
{
Assert.Null(stubTypeResult);
}
}
},
},
}
}
}
@@ -41,7 +41,7 @@ namespace Jellyfin.Naming.Tests.Video
"trailer.mkv",
// Same as above
"WillyWonka-trailer.mkv"
"WillyWonka-trailer.mkv",
};
var result = VideoListResolver.Resolve(
@@ -75,7 +75,7 @@ namespace Jellyfin.Naming.Tests.Video
var files = new[]
{
"300.mkv",
"300.nfo"
"300.nfo",
};
var result = VideoListResolver.Resolve(
@@ -91,7 +91,7 @@ namespace Jellyfin.Naming.Tests.Video
var files = new[]
{
"300.mkv",
"300 - trailer.mkv"
"300 - trailer.mkv",
};
var result = VideoListResolver.Resolve(
@@ -109,7 +109,7 @@ namespace Jellyfin.Naming.Tests.Video
var files = new[]
{
"X-Men Days of Future Past - 1080p.mkv",
"X-Men Days of Future Past-trailer.mp4"
"X-Men Days of Future Past-trailer.mp4",
};
var result = VideoListResolver.Resolve(
@@ -128,7 +128,7 @@ namespace Jellyfin.Naming.Tests.Video
{
"X-Men Days of Future Past - 1080p.mkv",
"X-Men Days of Future Past-trailer.mp4",
"X-Men Days of Future Past-trailer2.mp4"
"X-Men Days of Future Past-trailer2.mp4",
};
var result = VideoListResolver.Resolve(
@@ -148,7 +148,7 @@ namespace Jellyfin.Naming.Tests.Video
{
"Looper (2012)-trailer.mkv",
"Looper 2012-trailer.mkv",
"Looper.2012.bluray.720p.x264.mkv"
"Looper.2012.bluray.720p.x264.mkv",
};
var result = VideoListResolver.Resolve(
@@ -167,7 +167,7 @@ namespace Jellyfin.Naming.Tests.Video
var files = new[]
{
"/movies/Looper (2012)/Looper (2012)-trailer.mkv",
"/movies/Looper (2012)/Looper.bluray.720p.x264.mkv"
"/movies/Looper (2012)/Looper.bluray.720p.x264.mkv",
};
var result = VideoListResolver.Resolve(
@@ -189,7 +189,7 @@ namespace Jellyfin.Naming.Tests.Video
"My video 2.mkv",
"My video 3.mkv",
"My video 4.mkv",
"My video 5.mkv"
"My video 5.mkv",
};
var result = VideoListResolver.Resolve(
@@ -205,7 +205,7 @@ namespace Jellyfin.Naming.Tests.Video
var files = new[]
{
"M:/Movies (DVD)/Movies (Musical)/Sound of Music (1965)/Sound of Music Disc 1",
"M:/Movies (DVD)/Movies (Musical)/Sound of Music (1965)/Sound of Music Disc 2"
"M:/Movies (DVD)/Movies (Musical)/Sound of Music (1965)/Sound of Music Disc 2",
};
var result = VideoListResolver.Resolve(
@@ -222,7 +222,7 @@ namespace Jellyfin.Naming.Tests.Video
var files = new[]
{
"My movie #1.mp4",
"My movie #2.mp4"
"My movie #2.mp4",
};
var result = VideoListResolver.Resolve(
@@ -240,7 +240,7 @@ namespace Jellyfin.Naming.Tests.Video
"No (2012) part1.mp4",
"No (2012) part2.mp4",
"No (2012) part1-trailer.mp4",
"No (2012)-trailer.mp4"
"No (2012)-trailer.mp4",
};
var result = VideoListResolver.Resolve(
@@ -261,7 +261,7 @@ namespace Jellyfin.Naming.Tests.Video
"/Movies/Top Gun (1984)/movie.mp4",
"/Movies/Top Gun (1984)/Top Gun (1984)-trailer.mp4",
"/Movies/Top Gun (1984)/Top Gun (1984)-trailer2.mp4",
"/Movies/trailer.mp4"
"/Movies/trailer.mp4",
};
var result = VideoListResolver.Resolve(
@@ -283,7 +283,7 @@ namespace Jellyfin.Naming.Tests.Video
"/MCFAMILY-PC/Private3$/Heterosexual/Breast In Class 2 Counterfeit Racks (2011)/Breast In Class 2 Counterfeit Racks (2011) Disc 1 cd1.avi",
"/MCFAMILY-PC/Private3$/Heterosexual/Breast In Class 2 Counterfeit Racks (2011)/Breast In Class 2 Counterfeit Racks (2011) Disc 1 cd2.avi",
"/MCFAMILY-PC/Private3$/Heterosexual/Breast In Class 2 Counterfeit Racks (2011)/Breast In Class 2 Disc 2 cd1.avi",
"/MCFAMILY-PC/Private3$/Heterosexual/Breast In Class 2 Counterfeit Racks (2011)/Breast In Class 2 Disc 2 cd2.avi"
"/MCFAMILY-PC/Private3$/Heterosexual/Breast In Class 2 Counterfeit Racks (2011)/Breast In Class 2 Disc 2 cd2.avi",
};
var result = VideoListResolver.Resolve(
@@ -298,7 +298,7 @@ namespace Jellyfin.Naming.Tests.Video
{
var files = new[]
{
"/nas-markrobbo78/Videos/INDEX HTPC/Movies/Watched/3 - ACTION/Argo (2012)/movie.mkv"
"/nas-markrobbo78/Videos/INDEX HTPC/Movies/Watched/3 - ACTION/Argo (2012)/movie.mkv",
};
var result = VideoListResolver.Resolve(
@@ -313,7 +313,7 @@ namespace Jellyfin.Naming.Tests.Video
{
var files = new[]
{
"The Colony.mkv"
"The Colony.mkv",
};
var result = VideoListResolver.Resolve(
@@ -329,7 +329,7 @@ namespace Jellyfin.Naming.Tests.Video
var files = new[]
{
"Four Sisters and a Wedding - A.avi",
"Four Sisters and a Wedding - B.avi"
"Four Sisters and a Wedding - B.avi",
};
var result = VideoListResolver.Resolve(
@@ -347,7 +347,7 @@ namespace Jellyfin.Naming.Tests.Video
var files = new[]
{
"Four Rooms - A.avi",
"Four Rooms - A.mp4"
"Four Rooms - A.mp4",
};
var result = VideoListResolver.Resolve(
@@ -363,7 +363,7 @@ namespace Jellyfin.Naming.Tests.Video
var files = new[]
{
"/Server/Despicable Me/Despicable Me (2010).mkv",
"/Server/Despicable Me/trailer.mkv"
"/Server/Despicable Me/trailer.mkv",
};
var result = VideoListResolver.Resolve(
@@ -381,7 +381,7 @@ namespace Jellyfin.Naming.Tests.Video
var files = new[]
{
"/Server/Despicable Me/Despicable Me (2010).mkv",
"/Server/Despicable Me/trailers/some title.mkv"
"/Server/Despicable Me/trailers/some title.mkv",
};
var result = VideoListResolver.Resolve(
@@ -399,7 +399,7 @@ namespace Jellyfin.Naming.Tests.Video
var files = new[]
{
"/Movies/Despicable Me/Despicable Me.mkv",
"/Movies/Despicable Me/trailers/trailer.mkv"
"/Movies/Despicable Me/trailers/trailer.mkv",
};
var result = VideoListResolver.Resolve(
@@ -416,6 +416,6 @@ namespace Jellyfin.Naming.Tests.Video
{
var stack = new FileStack(string.Empty, false, Array.Empty<string>());
Assert.False(stack.ContainsFile("XX", true));
}
},
}
}
}
@@ -192,7 +192,7 @@ namespace Jellyfin.Naming.Tests.Video
foreach (var result in results)
{
Assert.Null(result?.Container);
}
}
},
},
}
}
}
@@ -1,4 +1,4 @@
// <autogenerated />
using System;
using System.Reflection;
[assembly: global::System.Runtime.Versioning.TargetFrameworkAttribute(".NETCoreApp,Version=v10.0", FrameworkDisplayName = ".NET 10.0")]
[assembly: global::System.Runtime.Versioning.TargetFrameworkAttribute(".NETCoreApp,Version=v10.0", FrameworkDisplayName = ".NET 10.0")]
@@ -20,4 +20,3 @@ using System.Reflection;
[assembly: System.Reflection.AssemblyVersionAttribute("1.0.0.0")]
// Generated by the MSBuild WriteCodeFragment class.
@@ -1,6 +1,6 @@
{
"version": 2,
"dgSpecHash": "aetk2kDndoI=",
"dgSpecHash": "w013NueXjWs=",
"success": true,
"projectFilePath": "E:\\Projects\\pgsql-jellyfin\\tests\\Jellyfin.Naming.Tests\\Jellyfin.Naming.Tests.csproj",
"expectedPackageFiles": [
@@ -1,6 +1,6 @@
{
"version": 2,
"dgSpecHash": "VqeAp96kZ+8=",
"dgSpecHash": "dtvsyCwkixc=",
"success": true,
"projectFilePath": "E:\\Projects\\pgsql-jellyfin\\tests\\Jellyfin.Networking.Tests\\Jellyfin.Networking.Tests.csproj",
"expectedPackageFiles": [
@@ -1,6 +1,6 @@
{
"version": 2,
"dgSpecHash": "yVpchsJCVR8=",
"dgSpecHash": "99YmHljNark=",
"success": true,
"projectFilePath": "E:\\Projects\\pgsql-jellyfin\\tests\\Jellyfin.Providers.Tests\\Jellyfin.Providers.Tests.csproj",
"expectedPackageFiles": [
@@ -1,6 +1,6 @@
{
"version": 2,
"dgSpecHash": "SB6n8FaqhDk=",
"dgSpecHash": "ekBTYkgmpdU=",
"success": true,
"projectFilePath": "E:\\Projects\\pgsql-jellyfin\\tests\\Jellyfin.Server.Implementations.Tests\\Jellyfin.Server.Implementations.Tests.csproj",
"expectedPackageFiles": [
@@ -1,6 +1,6 @@
{
"version": 2,
"dgSpecHash": "F/F7p6QhWSM=",
"dgSpecHash": "wWSnrqDiePs=",
"success": true,
"projectFilePath": "E:\\Projects\\pgsql-jellyfin\\tests\\Jellyfin.Server.Integration.Tests\\Jellyfin.Server.Integration.Tests.csproj",
"expectedPackageFiles": [
@@ -1,6 +1,6 @@
{
"version": 2,
"dgSpecHash": "W1tIaEHAq1A=",
"dgSpecHash": "2W4hzYZ52SM=",
"success": true,
"projectFilePath": "E:\\Projects\\pgsql-jellyfin\\tests\\Jellyfin.Server.Tests\\Jellyfin.Server.Tests.csproj",
"expectedPackageFiles": [
@@ -1,6 +1,6 @@
{
"version": 2,
"dgSpecHash": "+lkQwnGRsbE=",
"dgSpecHash": "cjfpv0pWthU=",
"success": true,
"projectFilePath": "E:\\Projects\\pgsql-jellyfin\\tests\\Jellyfin.XbmcMetadata.Tests\\Jellyfin.XbmcMetadata.Tests.csproj",
"expectedPackageFiles": [