Skip to content

Commit

Permalink
test: clear segment transmuxer in media segment request tests (#1043)
Browse files Browse the repository at this point in the history
  • Loading branch information
brandonocasey authored Jan 13, 2021
1 parent ee39672 commit 83057a8
Showing 1 changed file with 4 additions and 1 deletion.
5 changes: 4 additions & 1 deletion test/media-segment-request.test.js
Original file line number Diff line number Diff line change
Expand Up @@ -10,6 +10,7 @@ import {
} from './test-helpers';
import TransmuxWorker from 'worker!../src/transmuxer-worker.worker.js';
import Decrypter from 'worker!../src/decrypter-worker.worker.js';
import {dispose as segmentTransmuxerDispose} from '../src/segment-transmuxer.js';
import {
aacWithoutId3 as aacWithoutId3Segment,
aacWithId3 as aacWithId3Segment,
Expand Down Expand Up @@ -91,6 +92,9 @@ const sharedHooks = {
if (this.transmuxer) {
this.transmuxer.terminate();
}

// clear current transmux on segment transmuxer
segmentTransmuxerDispose();
}

};
Expand Down Expand Up @@ -1209,7 +1213,6 @@ QUnit.test('callbacks fire for TS segment with partial data', function(assert) {
this.standardXHRResponse(request, muxedSegment());
});

// TODO: tests after this one appear to fail
QUnit.test('data callback does not fire if too little partial data', function(assert) {
const progressSpy = sinon.spy();
const dataSpy = sinon.spy();
Expand Down

0 comments on commit 83057a8

Please sign in to comment.