зеркало из https://github.com/mozilla/popcorn-js.git
[#468] popcorn.position audio test
This commit is contained in:
Родитель
a79f2af651
Коммит
5472b203ba
|
@ -404,7 +404,7 @@
|
|||
|
||||
// Popcorn Object Element Utils
|
||||
position: function() {
|
||||
var media = this.video,
|
||||
var media = this.media,
|
||||
clientRect = media.getBoundingClientRect(),
|
||||
bounds = {},
|
||||
doc = media.ownerDocument,
|
||||
|
|
|
@ -343,7 +343,7 @@ test("exec", function () {
|
|||
module("Popcorn Position");
|
||||
test("position", function () {
|
||||
|
||||
expect(24);
|
||||
expect(25);
|
||||
|
||||
var $absolute = $(".absolute"),
|
||||
$relative = $(".relative"),
|
||||
|
@ -401,6 +401,11 @@ test("position", function () {
|
|||
equals( Popcorn( "#vid-" + test.id ).position().left, test.left, "Popcorn('#vid-" + test.id + "').position().left" );
|
||||
});
|
||||
|
||||
try {
|
||||
ok( Popcorn( "#audio" ).position(), "position called from audio" );
|
||||
} catch( e ) {
|
||||
ok( false, e );
|
||||
}
|
||||
|
||||
$("#position-tests").hide();
|
||||
});
|
||||
|
|
Загрузка…
Ссылка в новой задаче