コード例 #1
0
ファイル: ExtraTests.cs プロジェクト: WWWesten/jellyfin
        public void TestExtraInfo_InvalidRuleType()
        {
            var rule    = new ExtraRule(ExtraType.Unknown, ExtraRuleType.Regex, @"([eE]x(tra)?\.\w+)", MediaType.Video);
            var options = new NamingOptions {
                VideoExtraRules = new[] { rule }
            };
            var res = ExtraResolver.GetExtraInfo("extra.mp4", options);

            Assert.Equal(rule, res.Rule);
        }
コード例 #2
0
ファイル: ExtraTests.cs プロジェクト: WWWesten/jellyfin
        private void Test(string input, ExtraType?expectedType)
        {
            var extraType = ExtraResolver.GetExtraInfo(input, _videoOptions).ExtraType;

            Assert.Equal(expectedType, extraType);
        }