Skip to content

Commit

Permalink
[mozilla#468] popcorn.position audio test
Browse files Browse the repository at this point in the history
  • Loading branch information
ScottDowne committed Apr 11, 2011
1 parent a79f2af commit 5472b20
Show file tree
Hide file tree
Showing 2 changed files with 7 additions and 2 deletions.
2 changes: 1 addition & 1 deletion popcorn.js
Original file line number Diff line number Diff line change
Expand Up @@ -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,
Expand Down
7 changes: 6 additions & 1 deletion test/popcorn.unit.js
Original file line number Diff line number Diff line change
Expand Up @@ -343,7 +343,7 @@ test("exec", function () {
module("Popcorn Position");
test("position", function () {

expect(24);
expect(25);

var $absolute = $(".absolute"),
$relative = $(".relative"),
Expand Down Expand Up @@ -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();
});
Expand Down

0 comments on commit 5472b20

Please sign in to comment.