コード例 #1
0
ファイル: SrtMakerTests.cs プロジェクト: jokalee/Tuto
        public void TestLocation()
        {
            var array = new StreamChunk[]
            {
                new StreamChunk(0000, 1000, Editor.Mode.Drop, false),
                new StreamChunk(1000, 2000, Editor.Mode.Face, false),
                new StreamChunk(2000, 3000, Editor.Mode.Drop, false),
                new StreamChunk(3000, 4000, Editor.Mode.Desktop, false),
            };

            Assert.AreEqual(1500, SrtMaker.FindFinalLocation(3500, array));
        }
コード例 #2
0
ファイル: SrtMakerTests.cs プロジェクト: jokalee/Tuto
 public void TestMsOutput()
 {
     Assert.AreEqual("00:00:10,500", SrtMaker.MsInSrtFormat(10500));
     Assert.AreEqual("00:02:10,500", SrtMaker.MsInSrtFormat((2 * 60 + 10) * 1000 + 500));
 }