From bb76f7139062a9d69dce9a21dc48b3baffaa92eb Mon Sep 17 00:00:00 2001 From: Genteure Date: Tue, 9 Mar 2021 22:13:44 +0800 Subject: [PATCH] FLV: Update tests --- BililiveRecorder.Flv/Tag.cs | 1 + .../Integrated/BadTests.cs | 2 +- .../Integrated/GoodTests.cs | 46 +- .../Integrated/TestBase.cs | 95 +- .../SampleFileTestDataAttribute.cs | 2 +- .../samples/good-strict/obs-fps10.xml | 295 ------ .../samples/good-strict/obs-fps10.xml.gz | Bin 0 -> 8723 bytes .../samples/good-strict/obs-fps2997.xml | 715 ------------- .../samples/good-strict/obs-fps2997.xml.gz | Bin 0 -> 10201 bytes .../obs-fps30-end_with_keyframe.xml.gz | Bin 0 -> 6686 bytes .../samples/good-strict/obs-fps30.xml | 473 --------- .../samples/good-strict/obs-fps30.xml.gz | Bin 0 -> 9867 bytes .../samples/good-strict/obs-fps5994.xml | 612 ----------- .../samples/good-strict/obs-fps60.xml | 952 ------------------ .../samples/good-strict/obs-fps60.xml.gz | Bin 0 -> 8982 bytes .../Flv/TagTests.cs | 39 + 16 files changed, 141 insertions(+), 3091 deletions(-) delete mode 100644 test/BililiveRecorder.Flv.RuleTests/samples/good-strict/obs-fps10.xml create mode 100644 test/BililiveRecorder.Flv.RuleTests/samples/good-strict/obs-fps10.xml.gz delete mode 100644 test/BililiveRecorder.Flv.RuleTests/samples/good-strict/obs-fps2997.xml create mode 100644 test/BililiveRecorder.Flv.RuleTests/samples/good-strict/obs-fps2997.xml.gz create mode 100644 test/BililiveRecorder.Flv.RuleTests/samples/good-strict/obs-fps30-end_with_keyframe.xml.gz delete mode 100644 test/BililiveRecorder.Flv.RuleTests/samples/good-strict/obs-fps30.xml create mode 100644 test/BililiveRecorder.Flv.RuleTests/samples/good-strict/obs-fps30.xml.gz delete mode 100644 test/BililiveRecorder.Flv.RuleTests/samples/good-strict/obs-fps5994.xml delete mode 100644 test/BililiveRecorder.Flv.RuleTests/samples/good-strict/obs-fps60.xml create mode 100644 test/BililiveRecorder.Flv.RuleTests/samples/good-strict/obs-fps60.xml.gz create mode 100644 test/BililiveRecorder.Flv.UnitTests/Flv/TagTests.cs diff --git a/BililiveRecorder.Flv/Tag.cs b/BililiveRecorder.Flv/Tag.cs index 0ea385f..1d5df17 100644 --- a/BililiveRecorder.Flv/Tag.cs +++ b/BililiveRecorder.Flv/Tag.cs @@ -85,6 +85,7 @@ namespace BililiveRecorder.Flv Type = this.Type, Flag = this.Flag, Size = this.Size, + Index = this.Index, Timestamp = this.Timestamp, BinaryData = binaryData, ScriptData = scriptData, diff --git a/test/BililiveRecorder.Flv.RuleTests/Integrated/BadTests.cs b/test/BililiveRecorder.Flv.RuleTests/Integrated/BadTests.cs index 4581136..1ed9614 100644 --- a/test/BililiveRecorder.Flv.RuleTests/Integrated/BadTests.cs +++ b/test/BililiveRecorder.Flv.RuleTests/Integrated/BadTests.cs @@ -15,7 +15,7 @@ namespace BililiveRecorder.Flv.RuleTests.Integrated public void Test(string path) { var path_input = Path.Combine(path, "input.xml"); - var path_output = Path.Combine(path, "output.xml"); + var path_expected = Path.Combine(path, "expected.xml"); } diff --git a/test/BililiveRecorder.Flv.RuleTests/Integrated/GoodTests.cs b/test/BililiveRecorder.Flv.RuleTests/Integrated/GoodTests.cs index c8d25da..1ee3080 100644 --- a/test/BililiveRecorder.Flv.RuleTests/Integrated/GoodTests.cs +++ b/test/BililiveRecorder.Flv.RuleTests/Integrated/GoodTests.cs @@ -1,5 +1,4 @@ using System.Collections.Generic; -using System.Linq; using System.Threading.Tasks; using BililiveRecorder.Flv.Grouping; using BililiveRecorder.Flv.Pipeline; @@ -30,7 +29,9 @@ namespace BililiveRecorder.Flv.RuleTests.Integrated var file = Assert.Single(output.Files); Assert.Equal(original.Count, file.Count); - AssertTags(original, file); + this.AssertTagsShouldPassBasicChecks(file); + this.AssertTagsAlmostEqual(original, file); + await this.AssertTagsByRerunPipeline(file).ConfigureAwait(false); } [Theory] @@ -59,44 +60,9 @@ namespace BililiveRecorder.Flv.RuleTests.Integrated var file = Assert.Single(output.Files); Assert.Equal(original.Count, file.Count); - AssertTags(original, file); - } - - private static void AssertTags(List original, List file) - { - Assert.Single(file.Where(x => x.Type == TagType.Script)); - Assert.Single(file.Where(x => x.Type == TagType.Audio && x.Flag == TagFlag.Header)); - Assert.Single(file.Where(x => x.Type == TagType.Video && x.Flag == (TagFlag.Header | TagFlag.Keyframe))); - - for (var i = 0; i < original.Count; i++) - { - var a = original[i]; - var b = file[i]; - - Assert.NotSame(a, b); - Assert.Equal(a.Type, b.Type); - Assert.Equal(a.Flag, b.Flag); - - if (a.IsScript()) - { - Assert.Equal(0, b.Timestamp); - } - else if (a.IsEnd()) - { - } - else if (a.IsHeader()) - { - Assert.Equal(0, b.Timestamp); - var binaryDataForSerializationUseOnly = a.BinaryDataForSerializationUseOnly; - Assert.False(string.IsNullOrWhiteSpace(binaryDataForSerializationUseOnly)); - Assert.Equal(binaryDataForSerializationUseOnly, b.BinaryDataForSerializationUseOnly); - } - else - { - Assert.Equal(a.Timestamp, b.Timestamp); - Assert.Equal(a.Index, b.Index); - } - } + this.AssertTagsShouldPassBasicChecks(file); + this.AssertTagsAlmostEqual(original, file); + await this.AssertTagsByRerunPipeline(file).ConfigureAwait(false); } //[Theory(Skip = "no data yet")] diff --git a/test/BililiveRecorder.Flv.RuleTests/Integrated/TestBase.cs b/test/BililiveRecorder.Flv.RuleTests/Integrated/TestBase.cs index 0fe2232..6671a05 100644 --- a/test/BililiveRecorder.Flv.RuleTests/Integrated/TestBase.cs +++ b/test/BililiveRecorder.Flv.RuleTests/Integrated/TestBase.cs @@ -1,17 +1,30 @@ using System.Collections.Generic; using System.IO; +using System.IO.Compression; +using System.Linq; using System.Threading.Tasks; +using BililiveRecorder.Flv.Grouping; using BililiveRecorder.Flv.Pipeline; using BililiveRecorder.Flv.Writer; using BililiveRecorder.Flv.Xml; using Microsoft.Extensions.DependencyInjection; +using Xunit; namespace BililiveRecorder.Flv.RuleTests.Integrated { public abstract class TestBase { - protected XmlFlvFile LoadFile(string path) => - (XmlFlvFile)XmlFlvFile.Serializer.Deserialize(File.Open(path, FileMode.Open, FileAccess.Read, FileShare.Read)); + protected XmlFlvFile LoadFile(string path) + { + if (Path.GetExtension(path) == ".gz") + return (XmlFlvFile)XmlFlvFile.Serializer.Deserialize(new GZipStream(File.Open(path, FileMode.Open, FileAccess.Read, FileShare.Read), CompressionMode.Decompress)); + + var gz = path + ".gz"; + if (File.Exists(gz)) + return (XmlFlvFile)XmlFlvFile.Serializer.Deserialize(new GZipStream(File.Open(gz, FileMode.Open, FileAccess.Read, FileShare.Read), CompressionMode.Decompress)); + + return (XmlFlvFile)XmlFlvFile.Serializer.Deserialize(File.Open(path, FileMode.Open, FileAccess.Read, FileShare.Read)); + } protected ProcessingDelegate BuildPipeline() => new ProcessingPipelineBuilder(new ServiceCollection().BuildServiceProvider()).AddDefault().AddRemoveFillerData().Build(); @@ -37,5 +50,83 @@ namespace BililiveRecorder.Flv.RuleTests.Integrated await writer.WriteAsync(context).ConfigureAwait(false); } } + + protected async Task AssertTagsByRerunPipeline(List tags) + { + var reader = new TagGroupReader(new FlvTagListReader(tags.Select(x => x.Clone()).ToList())); + var output = new FlvTagListWriter(); + var comments = new List(); + + await this.RunPipeline(reader, output, comments).ConfigureAwait(false); + + Assert.Empty(comments); + Assert.Empty(output.AlternativeHeaders); + + var file = Assert.Single(output.Files); + Assert.Equal(tags.Count, file.Count); + for (var i = 0; i < tags.Count; i++) + { + var a = tags[i]; + var b = file[i]; + + Assert.NotSame(a, b); + Assert.Equal(a.Type, b.Type); + Assert.Equal(a.Flag, b.Flag); + Assert.Equal(a.Index, b.Index); + Assert.Equal(a.Size, b.Size); + Assert.Equal(a.Timestamp, b.Timestamp); + Assert.Equal(a.BinaryDataForSerializationUseOnly, b.BinaryDataForSerializationUseOnly); + } + } + + protected void AssertTagsShouldPassBasicChecks(List tags) + { + Assert.True(tags.Any2((a, b) => (a.Timestamp <= b.Timestamp) && (b.Timestamp - a.Timestamp < 50))); + + Assert.Equal(TagType.Script, tags[0].Type); + + Assert.Equal(TagType.Video, tags[1].Type); + Assert.Equal(TagFlag.Header | TagFlag.Keyframe, tags[1].Flag); + + Assert.Equal(TagType.Audio, tags[2].Type); + Assert.Equal(TagFlag.Header, tags[2].Flag); + } + + protected void AssertTagsAlmostEqual(List expected, List actual) + { + Assert.Single(actual.Where(x => x.Type == TagType.Script)); + Assert.Single(actual.Where(x => x.Type == TagType.Audio && x.Flag == TagFlag.Header)); + Assert.Single(actual.Where(x => x.Type == TagType.Video && x.Flag == (TagFlag.Header | TagFlag.Keyframe))); + + for (var i = 0; i < expected.Count; i++) + { + var a = expected[i]; + var b = actual[i]; + + Assert.NotSame(a, b); + Assert.Equal(a.Type, b.Type); + Assert.Equal(a.Flag, b.Flag); + + if (a.IsScript()) + { + Assert.Equal(0, b.Timestamp); + } + else if (a.IsEnd()) + { + } + else if (a.IsHeader()) + { + Assert.Equal(0, b.Timestamp); + var binaryDataForSerializationUseOnly = a.BinaryDataForSerializationUseOnly; + Assert.False(string.IsNullOrWhiteSpace(binaryDataForSerializationUseOnly)); + Assert.Equal(binaryDataForSerializationUseOnly, b.BinaryDataForSerializationUseOnly); + } + else + { + Assert.Equal(a.Timestamp, b.Timestamp); + Assert.Equal(a.Index, b.Index); + } + } + } } } diff --git a/test/BililiveRecorder.Flv.RuleTests/SampleFileTestDataAttribute.cs b/test/BililiveRecorder.Flv.RuleTests/SampleFileTestDataAttribute.cs index f61de91..a672ded 100644 --- a/test/BililiveRecorder.Flv.RuleTests/SampleFileTestDataAttribute.cs +++ b/test/BililiveRecorder.Flv.RuleTests/SampleFileTestDataAttribute.cs @@ -23,7 +23,7 @@ namespace BililiveRecorder.Flv.RuleTests if (!Directory.Exists(fullPath)) throw new ArgumentException($"Could not find directory at path: {fullPath}"); - return Directory.GetFiles(fullPath, "*.xml").Select(x => new object[] { x }); + return new[] { "*.xml", "*.gz" }.SelectMany(x => Directory.GetFiles(fullPath, x)).Select(x => new object[] { x }); } } } diff --git a/test/BililiveRecorder.Flv.RuleTests/samples/good-strict/obs-fps10.xml b/test/BililiveRecorder.Flv.RuleTests/samples/good-strict/obs-fps10.xml deleted file mode 100644 index b8d16a4..0000000 --- a/test/BililiveRecorder.Flv.RuleTests/samples/good-strict/obs-fps10.xml +++ /dev/null @@ -1,295 +0,0 @@ - - - - - [{"Type":"String","Value":"onMetaData"},{"Type":"EcmaArray","Value":{"duration":{"Type":"Number","Value":3.9},"width":{"Type":"Number","Value":1920.0},"height":{"Type":"Number","Value":1080.0},"videodatarate":{"Type":"Number","Value":1464.84375},"framerate":{"Type":"Number","Value":10.0},"videocodecid":{"Type":"Number","Value":7.0},"audiodatarate":{"Type":"Number","Value":156.25},"audiosamplerate":{"Type":"Number","Value":48000.0},"audiosamplesize":{"Type":"Number","Value":16.0},"stereo":{"Type":"Boolean","Value":true},"audiocodecid":{"Type":"Number","Value":10.0},"encoder":{"Type":"String","Value":"Lavf58.29.100"},"filesize":{"Type":"Number","Value":9462.0}}}] - - - 170000000001640028FFE1001E67640028ACD940780227E59A808080A000000300200000030291E30632C001000468EF8FCB - - - AF00119056E500 - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - \ No newline at end of file diff --git a/test/BililiveRecorder.Flv.RuleTests/samples/good-strict/obs-fps10.xml.gz b/test/BililiveRecorder.Flv.RuleTests/samples/good-strict/obs-fps10.xml.gz new file mode 100644 index 0000000000000000000000000000000000000000..356b7bda1724c296947d355e0d81f4ec82f67cc7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h`y3Y{|*$-1b-|vg1%n#eK4m#lhi(6t)WM?X&0yp*s&*v+YnT!JY6* zDoSw|7A8Bk9+q_$CK|I;?<>tzItpu-RdAa0^@QvG^Pb?LyPJ}}l+@q2NT9m8TB=?=je z#kJF`op#^^a{hx%{MPcJskc!lro%f?R5 JQ6>)j_J0j_`uG3< literal 0 HcmV?d00001 diff --git a/test/BililiveRecorder.Flv.RuleTests/samples/good-strict/obs-fps2997.xml b/test/BililiveRecorder.Flv.RuleTests/samples/good-strict/obs-fps2997.xml deleted file mode 100644 index 3fd6dcb..0000000 --- a/test/BililiveRecorder.Flv.RuleTests/samples/good-strict/obs-fps2997.xml +++ /dev/null @@ -1,715 +0,0 @@ - - - - - [{"Type":"String","Value":"onMetaData"},{"Type":"EcmaArray","Value":{"duration":{"Type":"Number","Value":5.172},"width":{"Type":"Number","Value":1920.0},"height":{"Type":"Number","Value":1080.0},"videodatarate":{"Type":"Number","Value":1464.84375},"framerate":{"Type":"Number","Value":29.970029970029969},"videocodecid":{"Type":"Number","Value":7.0},"audiodatarate":{"Type":"Number","Value":156.25},"audiosamplerate":{"Type":"Number","Value":48000.0},"audiosamplesize":{"Type":"Number","Value":16.0},"stereo":{"Type":"Boolean","Value":true},"audiocodecid":{"Type":"Number","Value":10.0},"encoder":{"Type":"String","Value":"Lavf58.29.100"},"filesize":{"Type":"Number","Value":21485.0}}}] - - - 170000000001640028FFE1001C67640028ACD940780227E59A808080A000007D20001D4C11E30632C001000468EF8FCB - - - AF00119056E500 - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - \ No newline at end of file diff --git a/test/BililiveRecorder.Flv.RuleTests/samples/good-strict/obs-fps2997.xml.gz b/test/BililiveRecorder.Flv.RuleTests/samples/good-strict/obs-fps2997.xml.gz new file mode 100644 index 0000000000000000000000000000000000000000..ab899b386d9c31c0802c8e939cfb5fa539b9944b GIT binary patch literal 10201 zcmXw9cRbbK|F_pAGqY@2*GSijo0UDXU6OG{ND(S7$<568-0You&1;0)`jE`5NH#58 zGOtj$MB#U?-{fRCT-!d=nnaEwYal8 zZ3N9%ukUmj7AavIbW9%&MXKPpbw!NKUw^0Dp0#WCcK#AbPM?DK+#04~cwWg@;E=o^ zUPJPHu*H77Kfhlp61d?u+lty>b%-jg6P|t>c|iKSKF}70BEKsLJZ^PAd?#`=H2Yv{ ze|>v@xwqh9OZWk4U13!pCJ8_vu6O zHur33ckU$aiqrcP~b2TOy~XErA`>yFkB_Sq|sf07n;X5ThlIvk&vjoMqo zJlNmqCf~S!e@dtA`2BG!YWLkVxj-|#vh8>)y5zH zKYi>=Vyk!Zb$(9|uDiEIY!iwt4%e?7h5h-lH1VQpWqf|giyiT*clu@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-strict/obs-fps30-end_with_keyframe.xml.gz b/test/BililiveRecorder.Flv.RuleTests/samples/good-strict/obs-fps30-end_with_keyframe.xml.gz new file mode 100644 index 0000000000000000000000000000000000000000..4f4ff9ad88d42ddb2ad81f473a640f2abda7b5f8 GIT binary patch literal 6686 zcmYLKc|4Tw*QT+ChAfk95?T6|L1<)`t+I`xMY3iOBkS0bENMcdkR?l`goKQJ-?EfY z82gfKOpNWPN#6SzeLnAB&)m0j&UKyZT<3Ni&%)ArPv7Pcou{3*v?JDAURK({6zo{(4N`<%N~2E`h)W?y4IWf{5ExS9>U zc7a>X@EM%Yx)c^#uph$o;z}9sqZ{I#c-DonAaaLXQM`Z4VA^7i0`9xsF!S8fnLh4k zM6KjC1ZYV zRX5XRZmaj8jXUbM)Y9l@)r z{CNH{`|CiH{Ch#T`5URhy`#I261}qjBWeT{dm(10Wp1C*iuhl|w>K~a#Y>7eV69yA z$IoE1dRMb7q8X|*jSX`)S`SzJx2b%HyC?Zc)L5d&VZ}i~mQCH@nxo3+x&(Zbm=w1rLhsT!2F39isT;3OME?roV!FJ#>U7t%oFqix8JJ(w=6B$=^ zl|*g%@ng}@$b+zXY0jQb!L4>g>Lqvk`7-{@%+OEa^VQ#(Sl+|_o@?2al4QqgEGd*gTB;Bk@_?v)OByH$*e@jw5&S-c_ey(=3$L=$?p8<#f|8*K*WU zjp_*%Rav1(oCYPH!kF7X^WOeMxZTl?9oUS=8k>eZba_~713S+%Bc7r2g=AXAsB$l{ z>}7Bj$IS}_{JkDV??jo3S2q?;?hUs7UNMrSrt>6A6t_oy(yGjS60{KAoXYAD8ztI& z|G%2f{rGeK);hz6f<*JQm6O*6VfFv@vAtXq_xs-!jp>|8(V*-BBc4)e` znu_R;YOZkcgu=LIQA3fahPU!_Y1i~43sHA^qfC}A2Z>I6P%Bovbk*}wrMt=EyB51Q zLlV@A(e#pnXB-*u1i>)<9syi<@%J=NMI`C}JWy>YM|@Ru9+h4)Y*{v)iIdrZe)bn2Rp+)Q{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hftp`Cg;~jVQcpaN`H6UPc?QcB= z2sbuy|3_evAHNMJUv1J&St5fzIZ%%CfN?}J8OaDh@Upoh4~je=|IpM0A%M<%+w?>a4SOeX7b h`y0y?!ub&O5NgQZQ04oCYTOQdi=8)dhUpO9{{f=8;V}RJ literal 0 HcmV?d00001 diff --git a/test/BililiveRecorder.Flv.RuleTests/samples/good-strict/obs-fps30.xml b/test/BililiveRecorder.Flv.RuleTests/samples/good-strict/obs-fps30.xml deleted file mode 100644 index 76d0b29..0000000 --- a/test/BililiveRecorder.Flv.RuleTests/samples/good-strict/obs-fps30.xml +++ /dev/null @@ -1,473 +0,0 @@ - - - - - [{"Type":"String","Value":"onMetaData"},{"Type":"EcmaArray","Value":{"duration":{"Type":"Number","Value":3.433},"width":{"Type":"Number","Value":1920.0},"height":{"Type":"Number","Value":1080.0},"videodatarate":{"Type":"Number","Value":1464.84375},"framerate":{"Type":"Number","Value":30.0},"videocodecid":{"Type":"Number","Value":7.0},"audiodatarate":{"Type":"Number","Value":156.25},"audiosamplerate":{"Type":"Number","Value":48000.0},"audiosamplesize":{"Type":"Number","Value":16.0},"stereo":{"Type":"Boolean","Value":true},"audiocodecid":{"Type":"Number","Value":10.0},"encoder":{"Type":"String","Value":"Lavf58.29.100"},"filesize":{"Type":"Number","Value":14836.0}}}] - - - 170000000001640028FFE1001D67640028ACD940780227E59A808080A0000003002000000791E30632C001000468EF8FCB - - - AF00119056E500 - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - \ No newline at end of file diff --git a/test/BililiveRecorder.Flv.RuleTests/samples/good-strict/obs-fps30.xml.gz b/test/BililiveRecorder.Flv.RuleTests/samples/good-strict/obs-fps30.xml.gz new file mode 100644 index 0000000000000000000000000000000000000000..2d3ad8f7c93d57a7cda88c7a8d3cbc5db4055b73 GIT binary patch literal 9867 zcmZu%cOVr0`wt;mC7jGYM(Sg4nU!owDyy?UA*XYdl~obSEJ~8>%&e@-S?7$3j5zz^ zqHK|j%-?h8`{&Oeyw|f{@8@~m&vQ;F>d*no&%pyLR`i(O%N@ly|szoosF_=*d8g&6|xIj-dugz5cp^MwP*dkjTp_qds_qgVsE#n z8+Mnrx>5sg`vnKB5+XciBZ`oWQJ*eZ4ADb7TJJ-r8QSB+h?n>h)B_o6jpU+Ox=fYz5ga zp;POpdMEyn=Sot)jY=f-3ni}YAnX=i{+Z8h%2#;%XDzPwZ)f37&Dgr@<_vR*oe-K` zX6)~1n~c4dIqT9*Kyi@e>&3weq9Oj3jAm4(&`Q&dP}2SKW;s( zQ=)R$(0FF|{<@@!9N&unrIp`pI~?|!8y*7>2GZ&Sy;nB-3Kj$JZxhR1$LPPsjs^FI z2%w7vH8!8f#C;pv@we6v+-kR6-&j-InpoYEx$mDQ)1{d7(O0U(_5Sv)`Gz5-sTtQU zbSnSu%1WHwc3bbrCC}8_-PyGz<({qDSH2_LJzd|P5W9_MCOSW^32o#y``Fp72{E@= z>@k(SA!hqJ7v?)+JbP=p)?Kx>c2j(V_v-K6^$-t}&+T8CzH|6z?3*c5tzDG_&7M0! zJ@aLEcBA62Gij0TNu*{eIoti2nXfhcl+|iifBe5Lcl`XBl4LO(mCYOF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VrXLdZCS=gyALwkMq%#RQ zh=6VxueaWEB9PF6`D+pq6%SA0{U#W^3AxJnS&jP-e?8f$#zYw30^K)W4_}jFh`Ah} zwCGcG?g_lJE$L6kopPZ$?k@SYVSp*S(mi_?&(a4L5yBj8rA4u)3{8A35kgGTK8I~Y z=m)mSWU+38={%JAckh<(DoBTfo0L<=zUv{EtPFv}Q(lj8>pAs$S*(?n<-bhQv6LuY zl3fu1CPo}tL%z+3Tk@>N<|26L2cc~(OH$@QLeHpo_~XU6WnIfV;=9F)uu@#x?~vsb zFaU*{=*xo?J_f`Wv)`#?&_*V#sn;*DB96TdH3h4iy{h>zc|3+8$Dg1Y zT_b<{f-;n-@jPElt-4(~kydx(3@G^YIS>Y37*a<4296HDT*L9YO~HRe@w$dkaW9D# z19xb?0R1-3Y&EmubJn6*=$KiR-Mw2*1QWub2gjbWHumM4FCr~J0~Dc=FArz}s=@Y- zC)Ar^<4iqOH6eo6{R9Qf2oBPun2Iw8g^e4lGDb{g>J+w-PR<8bs2@;ZX8&>JKt7ku z!I3L^oCC>sFCRV$*D;W8P!0z`vUwjs9Spkrm?=L7UifWuT+N}XrEZbEvDnxA0@1F<3@804rDbamr zw!aW{(S?e$M=3e=DU~K9wN%Lsni_<{B9tS~pbFtT?M3Oxli!f|0PTm~AIistqh=Pv z6C^aDF6-Qyf&cdkEi9U&K|KJ+o9ShsvRyU;nXr&q6s#6OTbNO`ijJXn7R zHMYQ4fP&#GQ`<}935ZMgr(H&u)5pZTB4>%a1MGr9|Ic^5Ece(?xSaT{UrKx6{{ZzM B`Y!+g literal 0 HcmV?d00001 diff --git a/test/BililiveRecorder.Flv.RuleTests/samples/good-strict/obs-fps5994.xml b/test/BililiveRecorder.Flv.RuleTests/samples/good-strict/obs-fps5994.xml deleted file mode 100644 index 103b56b..0000000 --- a/test/BililiveRecorder.Flv.RuleTests/samples/good-strict/obs-fps5994.xml +++ /dev/null @@ -1,612 +0,0 @@ - - - - - [{"Type":"String","Value":"onMetaData"},{"Type":"EcmaArray","Value":{"duration":{"Type":"Number","Value":2.653},"width":{"Type":"Number","Value":1920.0},"height":{"Type":"Number","Value":1080.0},"videodatarate":{"Type":"Number","Value":1464.84375},"framerate":{"Type":"Number","Value":59.940059940059939},"videocodecid":{"Type":"Number","Value":7.0},"audiodatarate":{"Type":"Number","Value":156.25},"audiosamplerate":{"Type":"Number","Value":48000.0},"audiosamplesize":{"Type":"Number","Value":16.0},"stereo":{"Type":"Boolean","Value":true},"audiocodecid":{"Type":"Number","Value":10.0},"encoder":{"Type":"String","Value":"Lavf58.29.100"},"filesize":{"Type":"Number","Value":19080.0}}}] - - - 17000000000164002AFFE1001C6764002AACD940780227E59A808080A000007D20003A9811E30632C001000468EF8FCB - - - AF00119056E500 - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - \ No newline at end of file diff --git a/test/BililiveRecorder.Flv.RuleTests/samples/good-strict/obs-fps60.xml b/test/BililiveRecorder.Flv.RuleTests/samples/good-strict/obs-fps60.xml deleted file mode 100644 index 2cbf419..0000000 --- a/test/BililiveRecorder.Flv.RuleTests/samples/good-strict/obs-fps60.xml +++ /dev/null @@ -1,952 +0,0 @@ - - - - - [{"Type":"String","Value":"onMetaData"},{"Type":"EcmaArray","Value":{"duration":{"Type":"Number","Value":4.183},"width":{"Type":"Number","Value":1920.0},"height":{"Type":"Number","Value":1080.0},"videodatarate":{"Type":"Number","Value":1464.84375},"framerate":{"Type":"Number","Value":60.0},"videocodecid":{"Type":"Number","Value":7.0},"audiodatarate":{"Type":"Number","Value":156.25},"audiosamplerate":{"Type":"Number","Value":48000.0},"audiosamplesize":{"Type":"Number","Value":16.0},"stereo":{"Type":"Boolean","Value":true},"audiocodecid":{"Type":"Number","Value":10.0},"encoder":{"Type":"String","Value":"Lavf58.29.100"},"filesize":{"Type":"Number","Value":28683.0}}}] - - - 17000000000164002AFFE1001D6764002AACD940780227E59A808080A0000003002000000F11E30632C001000468EF8FCB - - - AF00119056E500 - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - \ No newline at end of file diff --git a/test/BililiveRecorder.Flv.RuleTests/samples/good-strict/obs-fps60.xml.gz b/test/BililiveRecorder.Flv.RuleTests/samples/good-strict/obs-fps60.xml.gz new file mode 100644 index 0000000000000000000000000000000000000000..d9c8f6649a82f90da722b4d2b5cf23d88d585208 GIT binary patch literal 8982 zcmYLNcOcaN|F@HjD0_z@S%p+KT_{Rf$x$L9d&e0mBXnjeqO6Ln>@%}d))gYNBYS4g z-}8O?e1G@X>)!9@>-l^<_v4N?jG6@bP>{5~9>8)nxit)tkNWYg_VSlkWl?;g5{l8_ z`^9*rj{5NE9X0xN%JnA$LY9pkdr7Zu>V7>ZB);|g{X3oIW1_!g-r?qFtK7}1j-u)VHW>zt=SMh7d zZEbmFtYBb_z&by-qGpE1EMl{)%wF#}Vs`$79boX?UToS@3fjt*sP-Fb4)lVc4D z(*@pGvqX;%eqK8^9`5sB8unK9unr?LgG1t`bDP2vLq2ZBi90^7O1ppFD`M0N8Q-ctzcuMmz1^GoPNJRH)HJEOdgrTO zl7hFlm+!#U!QCOh-SX-R%tm$j*I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x=U_42Pa(n`O&k*!0Y2pq^4ZSzpO1!sHNfi_ zZy#<;yR7KbH!_%N*zVi=d{^|yj@O&O%&gs9GsX4I-xv4B2j+6i-{ndq&x-R_d#-Km O9hgfttBq_YBl$l$1ZD*Q literal 0 HcmV?d00001 diff --git a/test/BililiveRecorder.Flv.UnitTests/Flv/TagTests.cs b/test/BililiveRecorder.Flv.UnitTests/Flv/TagTests.cs new file mode 100644 index 0000000..4f2f3bf --- /dev/null +++ b/test/BililiveRecorder.Flv.UnitTests/Flv/TagTests.cs @@ -0,0 +1,39 @@ +using System; +using System.IO; +using System.Text; +using Xunit; + +namespace BililiveRecorder.Flv.UnitTests.Flv +{ + public class TagTests + { + [Fact] + public void CloneTest() + { + var random = new Random(); + + var source = new Tag() + { + Type = (TagType)random.Next(), + Flag = (TagFlag)random.Next(), + Index = random.Next(), + Size = (uint)random.Next(), + Timestamp = random.Next(), + BinaryData = new MemoryStream(Encoding.UTF8.GetBytes("asdf" + random.Next())), + }; + + var result = source.Clone(); + + Assert.NotSame(source, result); + + Assert.Equal(source.Type, result.Type); + Assert.Equal(source.Flag, result.Flag); + Assert.Equal(source.Index, result.Index); + Assert.Equal(source.Size, result.Size); + Assert.Equal(source.Timestamp, result.Timestamp); + + Assert.NotSame(source.BinaryData, result.BinaryData); + Assert.Equal(source.BinaryDataForSerializationUseOnly, result.BinaryDataForSerializationUseOnly); + } + } +}