blob: e34d6c01a3680917158e1dae6a2d2232ce2957e4 [file] [log] [blame]
EXPECTED (source.readyState == 'closed') OK
EVENT(sourceopen)
RUN(sourceBuffer = source.addSourceBuffer("video/mock; codecs=mock"))
RUN(sourceBuffer.appendBuffer(initSegment))
EVENT(updateend)
RUN(sourceBuffer.appendBuffer(ibpSampleRun()))
EVENT(updateend)
{PTS({0/1 = 0.000000}), DTS({-1/1 = -1.000000}), duration({1/1 = 1.000000}), flags(1), generation(0)}
{PTS({2/1 = 2.000000}), DTS({0/1 = 0.000000}), duration({1/1 = 1.000000}), flags(0), generation(0)}
{PTS({1/1 = 1.000000}), DTS({1/1 = 1.000000}), duration({1/1 = 1.000000}), flags(0), generation(0)}
RUN(sourceBuffer.remove(1, 2))
EVENT(updateend)
RUN(sourceBuffer.appendBuffer(new Uint8Array()))
EVENT(updateend)
The frame with presentation time [1, 2) should have been deleted from the buffered samples and a reenqueue must have happened. That frame should not have been enqueued.
Buffered:
{PTS({0/1 = 0.000000}), DTS({-1/1 = -1.000000}), duration({1/1 = 1.000000}), flags(1), generation(0)}
{PTS({2/1 = 2.000000}), DTS({0/1 = 0.000000}), duration({1/1 = 1.000000}), flags(0), generation(0)}
Enqueued:
{PTS({0/1 = 0.000000}), DTS({-1/1 = -1.000000}), duration({1/1 = 1.000000}), flags(1), generation(0)}
{PTS({2/1 = 2.000000}), DTS({0/1 = 0.000000}), duration({1/1 = 1.000000}), flags(0), generation(0)}
END OF TEST