Skip to content

Commit

Permalink
tech order
Browse files Browse the repository at this point in the history
  • Loading branch information
gkatsev committed Dec 14, 2016
1 parent e18410f commit d0eabd2
Showing 1 changed file with 9 additions and 3 deletions.
12 changes: 9 additions & 3 deletions test/unit/video.test.js
Original file line number Diff line number Diff line change
Expand Up @@ -181,7 +181,9 @@ QUnit.test('ingest player div if data-vjs-player attribute is present on video p
const playerDiv = document.querySelector('.foo');
const vid = document.querySelector('#test_vid_id');

const player = videojs(vid, {});
const player = videojs(vid, {
techOrder: ['html5']
});

assert.equal(player.el(), playerDiv, 'we re-used the given div');
assert.ok(player.hasClass('foo'), 'keeps any classes that were around previously');
Expand All @@ -204,7 +206,9 @@ QUnit.test('ingested player div should not create a new tag for movingMediaEleme
const playerDiv = document.querySelector('.foo');
const vid = document.querySelector('#test_vid_id');

const player = videojs(vid, {});
const player = videojs(vid, {
techOrder: ['html5']
});

assert.equal(player.el(), playerDiv, 'we re-used the given div');
assert.equal(player.tech_.el(), vid, 'we re-used the video element');
Expand All @@ -230,7 +234,9 @@ QUnit.test('should create a new tag for movingMediaElementInDOM', function(asser
const playerDiv = document.querySelector('.foo');
const vid = document.querySelector('#test_vid_id');

const player = videojs(vid, {});
const player = videojs(vid, {
techOrder: ['html5']
});

assert.notEqual(player.el(), playerDiv, 'we used a new div');
assert.notEqual(player.tech_.el(), vid, 'we a new video element');
Expand Down

0 comments on commit d0eabd2

Please sign in to comment.