зеркало из https://github.com/mozilla/popcorn-js.git
Merge remote-tracking branch 'dseif/t534b' into develop
This commit is contained in:
Коммит
67c5c51924
|
@ -25,7 +25,7 @@ test("Popcorn attribution Plugin", function () {
|
||||||
|
|
||||||
popped.attribution({
|
popped.attribution({
|
||||||
start: 0, // seconds
|
start: 0, // seconds
|
||||||
end: 0.5, // seconds
|
end: 2, // seconds
|
||||||
nameofwork: "A Shared Culture",
|
nameofwork: "A Shared Culture",
|
||||||
copyrightholder:"Jesse Dylan",
|
copyrightholder:"Jesse Dylan",
|
||||||
license: "CC-BY-N6",
|
license: "CC-BY-N6",
|
||||||
|
@ -33,8 +33,8 @@ test("Popcorn attribution Plugin", function () {
|
||||||
target: 'attribdiv'
|
target: 'attribdiv'
|
||||||
} )
|
} )
|
||||||
.attribution({
|
.attribution({
|
||||||
start: 0.5, // seconds
|
start: 2, // seconds
|
||||||
end: 1, // seconds
|
end: 4, // seconds
|
||||||
nameofwork: "Internet",
|
nameofwork: "Internet",
|
||||||
nameofworkurl:"http://www.archive.org/details/CC1232_internet",
|
nameofworkurl:"http://www.archive.org/details/CC1232_internet",
|
||||||
copyrightholder:"The Computer Chronicles",
|
copyrightholder:"The Computer Chronicles",
|
||||||
|
@ -53,12 +53,12 @@ test("Popcorn attribution Plugin", function () {
|
||||||
plus();
|
plus();
|
||||||
});
|
});
|
||||||
|
|
||||||
popped.exec( 0.5, function() {
|
popped.exec( 2, function() {
|
||||||
equals (attributiondiv.children[1].style.display , "inline", "second attribution is visible on the page" );
|
equals (attributiondiv.children[1].style.display , "inline", "second attribution is visible on the page" );
|
||||||
plus();
|
plus();
|
||||||
});
|
});
|
||||||
|
|
||||||
popped.exec( 1, function() {
|
popped.exec( 4, function() {
|
||||||
equals(attributiondiv.children[1].style.display , "none", "second attribution is no longer visible on the page" );
|
equals(attributiondiv.children[1].style.display , "none", "second attribution is no longer visible on the page" );
|
||||||
plus();
|
plus();
|
||||||
equals(attributiondiv.children[0].style.display , "none", "first attribution is no longer visible on the page" );
|
equals(attributiondiv.children[0].style.display , "none", "first attribution is no longer visible on the page" );
|
||||||
|
|
|
@ -23,8 +23,8 @@ test('Popcorn Code Plugin', function () {
|
||||||
plus();
|
plus();
|
||||||
|
|
||||||
popped.code({
|
popped.code({
|
||||||
start: 1,
|
start: 0,
|
||||||
end: 3,
|
end: 2,
|
||||||
onStart: function( options ) {
|
onStart: function( options ) {
|
||||||
codeDiv.innerHTML = 'Test 1 - onStart (no onEnd)';
|
codeDiv.innerHTML = 'Test 1 - onStart (no onEnd)';
|
||||||
ok(true, 'Test 1 onStart was run.');
|
ok(true, 'Test 1 onStart was run.');
|
||||||
|
@ -33,8 +33,8 @@ test('Popcorn Code Plugin', function () {
|
||||||
});
|
});
|
||||||
|
|
||||||
popped.code({
|
popped.code({
|
||||||
start: 5,
|
start: 2,
|
||||||
end: 8,
|
end: 4,
|
||||||
onStart: function( options ) {
|
onStart: function( options ) {
|
||||||
codeDiv.innerHTML = 'Test 2 - onStart';
|
codeDiv.innerHTML = 'Test 2 - onStart';
|
||||||
ok(true, 'Test 2 onStart was run.');
|
ok(true, 'Test 2 onStart was run.');
|
||||||
|
@ -48,8 +48,8 @@ test('Popcorn Code Plugin', function () {
|
||||||
});
|
});
|
||||||
|
|
||||||
popped.code({
|
popped.code({
|
||||||
start: 10,
|
start: 4,
|
||||||
end: 14,
|
end: 6,
|
||||||
onStart: function( options ) {
|
onStart: function( options ) {
|
||||||
codeDiv.innerHTML = 'Test 3 - onStart [Frames: ';
|
codeDiv.innerHTML = 'Test 3 - onStart [Frames: ';
|
||||||
ok(true, 'Test 3 onStart was run.');
|
ok(true, 'Test 3 onStart was run.');
|
||||||
|
|
|
@ -25,28 +25,28 @@ test("Popcorn Facebook Plugin", function () {
|
||||||
popped.facebook({
|
popped.facebook({
|
||||||
target: "likediv",
|
target: "likediv",
|
||||||
start : 1,
|
start : 1,
|
||||||
end : 7
|
end : 6
|
||||||
} )
|
} )
|
||||||
.facebook({
|
.facebook({
|
||||||
href : "http://www.facebook.com/senecacollege",
|
href : "http://www.facebook.com/senecacollege",
|
||||||
type : "LIKE_BOX",
|
type : "LIKE_BOX",
|
||||||
target: "likeboxdiv",
|
target: "likeboxdiv",
|
||||||
start : 2,
|
start : 2,
|
||||||
end : 7
|
end : 6
|
||||||
} )
|
} )
|
||||||
.facebook({
|
.facebook({
|
||||||
site : "http://popcornjs.org/",
|
site : "http://popcornjs.org/",
|
||||||
type : "ACTIVITY",
|
type : "ACTIVITY",
|
||||||
target : "activitydiv",
|
target : "activitydiv",
|
||||||
start : 3,
|
start : 3,
|
||||||
end : 7
|
end : 6
|
||||||
} )
|
} )
|
||||||
.facebook({
|
.facebook({
|
||||||
href : "http://www.facebook.com/senecacollege",
|
href : "http://www.facebook.com/senecacollege",
|
||||||
type : "FACEPILE",
|
type : "FACEPILE",
|
||||||
target : "facepilediv",
|
target : "facepilediv",
|
||||||
start : 4,
|
start : 4,
|
||||||
end : 7,
|
end : 6,
|
||||||
width : 300
|
width : 300
|
||||||
} )
|
} )
|
||||||
.volume(0)
|
.volume(0)
|
||||||
|
|
|
@ -24,14 +24,14 @@ test("Popcorn Flickr Plugin", function () {
|
||||||
|
|
||||||
popped.flickr({
|
popped.flickr({
|
||||||
start: 0, // seconds
|
start: 0, // seconds
|
||||||
end: 1, // seconds
|
end: 2, // seconds
|
||||||
userid: '35034346917@N01',
|
userid: '35034346917@N01',
|
||||||
numberofimages: '1',
|
numberofimages: '1',
|
||||||
target: 'flickrdiv'
|
target: 'flickrdiv'
|
||||||
} )
|
} )
|
||||||
.flickr({
|
.flickr({
|
||||||
start: 1, // seconds
|
start: 2, // seconds
|
||||||
end: 2, // seconds
|
end: 4, // seconds
|
||||||
username: 'AniaSob',
|
username: 'AniaSob',
|
||||||
apikey: 'd1d249260dd1673ec8810c8ce5150ae1',
|
apikey: 'd1d249260dd1673ec8810c8ce5150ae1',
|
||||||
numberofimages: '1',
|
numberofimages: '1',
|
||||||
|
@ -40,21 +40,21 @@ test("Popcorn Flickr Plugin", function () {
|
||||||
|
|
||||||
setupId = popped.getLastTrackEventId();
|
setupId = popped.getLastTrackEventId();
|
||||||
|
|
||||||
popped.exec( 0.5, function() {
|
popped.exec( 1, function() {
|
||||||
ok( /display: inline;/.test( flickrdiv.innerHTML ), "Div contents are displayed" );
|
ok( /display: inline;/.test( flickrdiv.innerHTML ), "Div contents are displayed" );
|
||||||
plus();
|
plus();
|
||||||
ok( /img/.test( flickrdiv.innerHTML ), "An image exists" );
|
ok( /img/.test( flickrdiv.innerHTML ), "An image exists" );
|
||||||
plus();
|
plus();
|
||||||
});
|
});
|
||||||
|
|
||||||
popped.exec( 1.5, function() {
|
popped.exec( 3, function() {
|
||||||
ok( /display: inline;/.test( flickrdiv.innerHTML ), "Div contents are displayed" );
|
ok( /display: inline;/.test( flickrdiv.innerHTML ), "Div contents are displayed" );
|
||||||
plus();
|
plus();
|
||||||
ok( /img/.test( flickrdiv.innerHTML ), "An image exists" );
|
ok( /img/.test( flickrdiv.innerHTML ), "An image exists" );
|
||||||
plus();
|
plus();
|
||||||
});
|
});
|
||||||
|
|
||||||
popped.exec( 2, function() {
|
popped.exec( 4, function() {
|
||||||
ok( /display: none;/.test( flickrdiv.innerHTML ), "Div contents are hidden again" );
|
ok( /display: none;/.test( flickrdiv.innerHTML ), "Div contents are hidden again" );
|
||||||
plus();
|
plus();
|
||||||
|
|
||||||
|
|
|
@ -24,13 +24,13 @@ test("Popcorn Footnote Plugin", function () {
|
||||||
|
|
||||||
popped.footnote({
|
popped.footnote({
|
||||||
start: 0, // seconds
|
start: 0, // seconds
|
||||||
end: 1, // seconds
|
end: 2, // seconds
|
||||||
text: 'This video made exclusively for drumbeat.org',
|
text: 'This video made exclusively for drumbeat.org',
|
||||||
target: 'footnotediv'
|
target: 'footnotediv'
|
||||||
})
|
})
|
||||||
.footnote({
|
.footnote({
|
||||||
start: 1, // seconds
|
start: 2, // seconds
|
||||||
end: 2, // seconds
|
end: 4, // seconds
|
||||||
text: 'Visit webmademovies.org for more details',
|
text: 'Visit webmademovies.org for more details',
|
||||||
target: 'footnotediv'
|
target: 'footnotediv'
|
||||||
});
|
});
|
||||||
|
@ -46,12 +46,12 @@ test("Popcorn Footnote Plugin", function () {
|
||||||
plus();
|
plus();
|
||||||
});
|
});
|
||||||
|
|
||||||
popped.exec( 1, function() {
|
popped.exec( 3, function() {
|
||||||
equals (footnotediv.children[1].style.display , "inline", "second footnote is visible on the page" );
|
equals (footnotediv.children[1].style.display , "inline", "second footnote is visible on the page" );
|
||||||
plus();
|
plus();
|
||||||
});
|
});
|
||||||
|
|
||||||
popped.exec( 2, function() {
|
popped.exec( 4, function() {
|
||||||
ok (footnotediv.children[1].style.display === 'none' && footnotediv.children[0].style.display === 'none', "footnote are no longer vidible on the page" );
|
ok (footnotediv.children[1].style.display === 'none' && footnotediv.children[0].style.display === 'none', "footnote are no longer vidible on the page" );
|
||||||
plus();
|
plus();
|
||||||
|
|
||||||
|
|
|
@ -24,13 +24,13 @@ test("Popcorn GML Plugin", function () {
|
||||||
|
|
||||||
popped.gml({
|
popped.gml({
|
||||||
start: 0, // seconds
|
start: 0, // seconds
|
||||||
end: 1, // seconds
|
end: 2, // seconds
|
||||||
gmltag: '29582',
|
gmltag: '29582',
|
||||||
target: 'gmldiv'
|
target: 'gmldiv'
|
||||||
})
|
})
|
||||||
.gml({
|
.gml({
|
||||||
start: 1, // seconds
|
start: 2, // seconds
|
||||||
end: 2, // seconds
|
end: 4, // seconds
|
||||||
gmltag: '155',
|
gmltag: '155',
|
||||||
target: 'gmldiv'
|
target: 'gmldiv'
|
||||||
}).volume( 0 );
|
}).volume( 0 );
|
||||||
|
@ -42,12 +42,12 @@ test("Popcorn GML Plugin", function () {
|
||||||
plus();
|
plus();
|
||||||
});
|
});
|
||||||
|
|
||||||
popped.exec( 1, function() {
|
popped.exec( 3, function() {
|
||||||
equals( gmldiv.children[1].style.display , "block", "second GML is visible on the page" );
|
equals( gmldiv.children[1].style.display , "block", "second GML is visible on the page" );
|
||||||
plus();
|
plus();
|
||||||
});
|
});
|
||||||
|
|
||||||
popped.exec( 2, function() {
|
popped.exec( 4, function() {
|
||||||
equals( gmldiv.children[1].style.display , "none", "second GML is no longer visible on the page" );
|
equals( gmldiv.children[1].style.display , "none", "second GML is no longer visible on the page" );
|
||||||
plus();
|
plus();
|
||||||
equals( gmldiv.children[0].style.display , "none", "first GML is no longer visible on the page" );
|
equals( gmldiv.children[0].style.display , "none", "first GML is no longer visible on the page" );
|
||||||
|
|
|
@ -24,7 +24,7 @@ test("Popcorn Google Feed Plugin", function () {
|
||||||
|
|
||||||
popped.googlefeed({
|
popped.googlefeed({
|
||||||
start: 0, // seconds
|
start: 0, // seconds
|
||||||
end: 1, // seconds
|
end: 2, // seconds
|
||||||
target: "feed",
|
target: "feed",
|
||||||
url: "http://zenit.senecac.on.ca/~chris.tyler/planet/rss20.xml",
|
url: "http://zenit.senecac.on.ca/~chris.tyler/planet/rss20.xml",
|
||||||
title: "Planet Feed",
|
title: "Planet Feed",
|
||||||
|
@ -32,7 +32,7 @@ test("Popcorn Google Feed Plugin", function () {
|
||||||
})
|
})
|
||||||
.googlefeed({
|
.googlefeed({
|
||||||
start: 0, // seconds
|
start: 0, // seconds
|
||||||
end: 2, // seconds
|
end: 4, // seconds
|
||||||
target: "feed1",
|
target: "feed1",
|
||||||
url: "http://blog.pikimal.com/geek/feed/",
|
url: "http://blog.pikimal.com/geek/feed/",
|
||||||
title: "pikiGeek",
|
title: "pikiGeek",
|
||||||
|
@ -52,13 +52,13 @@ test("Popcorn Google Feed Plugin", function () {
|
||||||
equals (document.getElementById('_feed1').offsetParent.id, "feed", "First feed is inside the 'feed' div" );
|
equals (document.getElementById('_feed1').offsetParent.id, "feed", "First feed is inside the 'feed' div" );
|
||||||
plus();
|
plus();
|
||||||
});
|
});
|
||||||
popped.exec( 1, function() {
|
popped.exec( 3, function() {
|
||||||
ok (document.getElementById('_feed2'), "Second feed is on the page" );
|
ok (document.getElementById('_feed2'), "Second feed is on the page" );
|
||||||
plus();
|
plus();
|
||||||
equals (document.getElementById('_feed2').offsetParent.id, "feed1", "Second feed is inside the 'feed2' div" );
|
equals (document.getElementById('_feed2').offsetParent.id, "feed1", "Second feed is inside the 'feed2' div" );
|
||||||
plus();
|
plus();
|
||||||
});
|
});
|
||||||
popped.exec( 2, function() {
|
popped.exec( 4, function() {
|
||||||
ok (document.getElementById('_feed2').style.display === "none" &&
|
ok (document.getElementById('_feed2').style.display === "none" &&
|
||||||
document.getElementById('_feed1').style.display === "none", "Both feeds are no lnger visible" );
|
document.getElementById('_feed1').style.display === "none", "Both feeds are no lnger visible" );
|
||||||
plus();
|
plus();
|
||||||
|
|
|
@ -29,7 +29,7 @@ test("Popcorn Google Map Plugin", function () {
|
||||||
|
|
||||||
popped.googlemap({
|
popped.googlemap({
|
||||||
start: 0, // seconds
|
start: 0, // seconds
|
||||||
end: 5, // seconds
|
end: 2, // seconds
|
||||||
type: 'ROADMAP',
|
type: 'ROADMAP',
|
||||||
target: 'map',
|
target: 'map',
|
||||||
lat: 43.665429,
|
lat: 43.665429,
|
||||||
|
@ -38,15 +38,15 @@ test("Popcorn Google Map Plugin", function () {
|
||||||
})
|
})
|
||||||
.googlemap({
|
.googlemap({
|
||||||
start: 0, // seconds
|
start: 0, // seconds
|
||||||
end: 10, // seconds
|
end: 2, // seconds
|
||||||
type: 'SATELLITE',
|
type: 'SATELLITE',
|
||||||
target: 'map2',
|
target: 'map2',
|
||||||
location:'toronto',
|
location:'toronto',
|
||||||
zoom: 15
|
zoom: 15
|
||||||
});
|
});
|
||||||
var mapz = popped.googlemap({
|
var mapz = popped.googlemap({
|
||||||
start: 0, // seconds
|
start: 2, // seconds
|
||||||
end: 10, // seconds
|
end: 4, // seconds
|
||||||
type: "STREETVIEW",
|
type: "STREETVIEW",
|
||||||
target: "map3",
|
target: "map3",
|
||||||
location: "6th Line, Oakville, Ontario",
|
location: "6th Line, Oakville, Ontario",
|
||||||
|
@ -60,7 +60,7 @@ test("Popcorn Google Map Plugin", function () {
|
||||||
|
|
||||||
setupId = popped.getLastTrackEventId();
|
setupId = popped.getLastTrackEventId();
|
||||||
|
|
||||||
popped.exec( 4, function() {
|
popped.exec( 1, function() {
|
||||||
ok(google.maps, "Google maps is available");
|
ok(google.maps, "Google maps is available");
|
||||||
plus();
|
plus();
|
||||||
ok(google.maps.Geocoder, "Google maps Geocoder is available");
|
ok(google.maps.Geocoder, "Google maps Geocoder is available");
|
||||||
|
@ -71,19 +71,19 @@ test("Popcorn Google Map Plugin", function () {
|
||||||
plus();
|
plus();
|
||||||
});
|
});
|
||||||
|
|
||||||
popped.exec( 4, function() {
|
popped.exec( 1, function() {
|
||||||
ok (document.getElementById('actualmap2'), "Second map is on the page" );
|
ok (document.getElementById('actualmap2'), "Second map is on the page" );
|
||||||
plus();
|
plus();
|
||||||
equals (document.getElementById('actualmap2').offsetParent.id, "map2", "Second map is inside the 'map2' div" );
|
equals (document.getElementById('actualmap2').offsetParent.id, "map2", "Second map is inside the 'map2' div" );
|
||||||
plus();
|
plus();
|
||||||
});
|
});
|
||||||
|
|
||||||
popped.exec( 4, function() {
|
popped.exec( 3, function() {
|
||||||
equals (document.getElementById('actualmap3').offsetParent.id, "map3", "Tweening map is inside the 'map3' div" );
|
equals (document.getElementById('actualmap3').offsetParent.id, "map3", "Tweening map is inside the 'map3' div" );
|
||||||
plus();
|
plus();
|
||||||
});
|
});
|
||||||
|
|
||||||
popped.exec( 11, function() {
|
popped.exec( 5, function() {
|
||||||
ok (document.getElementById('actualmap2').style.display === "none" &&
|
ok (document.getElementById('actualmap2').style.display === "none" &&
|
||||||
document.getElementById('actualmap1').style.display === "none" &&
|
document.getElementById('actualmap1').style.display === "none" &&
|
||||||
document.getElementById('actualmap3').style.display === "none", "All maps are no longer visible" );
|
document.getElementById('actualmap3').style.display === "none", "All maps are no longer visible" );
|
||||||
|
|
|
@ -24,13 +24,13 @@ test( "Popcorn google news Plugin", function () {
|
||||||
|
|
||||||
popped.googlenews({
|
popped.googlenews({
|
||||||
start: 0, // seconds
|
start: 0, // seconds
|
||||||
end: 1, // seconds
|
end: 2, // seconds
|
||||||
topic: "Oil Spill",
|
topic: "Oil Spill",
|
||||||
target: "googlenewsdiv"
|
target: "googlenewsdiv"
|
||||||
})
|
})
|
||||||
.googlenews({
|
.googlenews({
|
||||||
start: 1, // seconds
|
start: 2, // seconds
|
||||||
end: 2, // seconds
|
end: 4, // seconds
|
||||||
topic: "Village Telco",
|
topic: "Village Telco",
|
||||||
target: "googlenewsdiv"
|
target: "googlenewsdiv"
|
||||||
})
|
})
|
||||||
|
@ -45,12 +45,12 @@ test( "Popcorn google news Plugin", function () {
|
||||||
plus();
|
plus();
|
||||||
});
|
});
|
||||||
|
|
||||||
popped.exec( 1, function() {
|
popped.exec( 3, function() {
|
||||||
equals( googlenewsdiv.children[1].style.display , "inline", "second googlenews is visible on the page" );
|
equals( googlenewsdiv.children[1].style.display , "inline", "second googlenews is visible on the page" );
|
||||||
plus();
|
plus();
|
||||||
});
|
});
|
||||||
|
|
||||||
popped.exec( 2, function() {
|
popped.exec( 4, function() {
|
||||||
equals( googlenewsdiv.children[1].style.display , "none", "second googlenews is no longer visible on the page" );
|
equals( googlenewsdiv.children[1].style.display , "none", "second googlenews is no longer visible on the page" );
|
||||||
plus();
|
plus();
|
||||||
equals( googlenewsdiv.children[0].style.display , "none", "first googlenews is no longer visible on the page" );
|
equals( googlenewsdiv.children[0].style.display , "none", "first googlenews is no longer visible on the page" );
|
||||||
|
|
|
@ -39,9 +39,9 @@ test("Popcorn Image Plugin", function () {
|
||||||
})
|
})
|
||||||
.image({
|
.image({
|
||||||
// seconds
|
// seconds
|
||||||
start: 5,
|
start: 4,
|
||||||
// seconds
|
// seconds
|
||||||
end: 7,
|
end: 6,
|
||||||
// no href
|
// no href
|
||||||
src: sources[1],
|
src: sources[1],
|
||||||
target: "imagediv"
|
target: "imagediv"
|
||||||
|
@ -50,7 +50,7 @@ test("Popcorn Image Plugin", function () {
|
||||||
// seconds
|
// seconds
|
||||||
start: 5,
|
start: 5,
|
||||||
// seconds
|
// seconds
|
||||||
end: 7,
|
end: 6,
|
||||||
// no href
|
// no href
|
||||||
src: sources[2],
|
src: sources[2],
|
||||||
target: "imagediv"
|
target: "imagediv"
|
||||||
|
@ -65,19 +65,19 @@ test("Popcorn Image Plugin", function () {
|
||||||
plus();
|
plus();
|
||||||
});
|
});
|
||||||
|
|
||||||
popped.exec( 4, function() {
|
popped.exec( 3, function() {
|
||||||
ok( /display: none;/.test( imagediv.innerHTML ), "Div contents are hidden again" );
|
ok( /display: none;/.test( imagediv.innerHTML ), "Div contents are hidden again" );
|
||||||
plus();
|
plus();
|
||||||
});
|
});
|
||||||
|
|
||||||
popped.exec( 6, function() {
|
popped.exec( 5, function() {
|
||||||
[].forEach.call( document.querySelectorAll( "#imagediv a img" ), function( img, idx ) {
|
[].forEach.call( document.querySelectorAll( "#imagediv a img" ), function( img, idx ) {
|
||||||
ok( img.src === sources[ idx ], "Image " + idx + " is in the right order" );
|
ok( img.src === sources[ idx ], "Image " + idx + " is in the right order" );
|
||||||
plus();
|
plus();
|
||||||
});
|
});
|
||||||
});
|
});
|
||||||
|
|
||||||
popped.exec( 8, function() {
|
popped.exec( 7, function() {
|
||||||
popped.pause().removeTrackEvent( setupId );
|
popped.pause().removeTrackEvent( setupId );
|
||||||
ok( !imagediv.children[2], "removed image was properly destroyed" );
|
ok( !imagediv.children[2], "removed image was properly destroyed" );
|
||||||
plus();
|
plus();
|
||||||
|
|
|
@ -66,11 +66,11 @@ test("Popcorn LinkedIn Plugin", function () {
|
||||||
companyid: "LinkedIn",
|
companyid: "LinkedIn",
|
||||||
productid: "201714",
|
productid: "201714",
|
||||||
apikey: "ZOLRI2rzQS_oaXELpPF0aksxwFFEvoxAFZRLfHjaAhcGPfOX0Ds4snkJpWwKs8gk",
|
apikey: "ZOLRI2rzQS_oaXELpPF0aksxwFFEvoxAFZRLfHjaAhcGPfOX0Ds4snkJpWwKs8gk",
|
||||||
start: 5,
|
start: 1,
|
||||||
end: 7
|
end: 3
|
||||||
});
|
});
|
||||||
|
|
||||||
popped.exec( 6, function() {
|
popped.exec( 2, function() {
|
||||||
|
|
||||||
ok( /block/.test( recommenddiv.style.display ), "recommenddiv contents are displayed" );
|
ok( /block/.test( recommenddiv.style.display ), "recommenddiv contents are displayed" );
|
||||||
plus();
|
plus();
|
||||||
|
@ -78,7 +78,7 @@ test("Popcorn LinkedIn Plugin", function () {
|
||||||
plus();
|
plus();
|
||||||
});
|
});
|
||||||
|
|
||||||
popped.exec( 8, function() {
|
popped.exec( 4, function() {
|
||||||
|
|
||||||
ok( /none/.test( recommenddiv.style.display ), "recommenddiv contents are hidden again" );
|
ok( /none/.test( recommenddiv.style.display ), "recommenddiv contents are hidden again" );
|
||||||
plus();
|
plus();
|
||||||
|
@ -94,11 +94,11 @@ test("Popcorn LinkedIn Plugin", function () {
|
||||||
format: "inline",
|
format: "inline",
|
||||||
target: "memberprofilediv",
|
target: "memberprofilediv",
|
||||||
apikey: "ZOLRI2rzQS_oaXELpPF0aksxwFFEvoxAFZRLfHjaAhcGPfOX0Ds4snkJpWwKs8gk",
|
apikey: "ZOLRI2rzQS_oaXELpPF0aksxwFFEvoxAFZRLfHjaAhcGPfOX0Ds4snkJpWwKs8gk",
|
||||||
start: 9,
|
start: 1,
|
||||||
end: 11
|
end: 3
|
||||||
});
|
});
|
||||||
|
|
||||||
popped.exec( 10, function() {
|
popped.exec( 2, function() {
|
||||||
|
|
||||||
ok( /block/.test( memberprofilediv.style.display ), "memberprofilediv contents are displayed" );
|
ok( /block/.test( memberprofilediv.style.display ), "memberprofilediv contents are displayed" );
|
||||||
plus();
|
plus();
|
||||||
|
@ -106,7 +106,7 @@ test("Popcorn LinkedIn Plugin", function () {
|
||||||
plus();
|
plus();
|
||||||
});
|
});
|
||||||
|
|
||||||
popped.exec( 12, function() {
|
popped.exec( 4, function() {
|
||||||
|
|
||||||
ok( /none/.test( memberprofilediv.style.display ), "memberprofilediv contents are hidden again" );
|
ok( /none/.test( memberprofilediv.style.display ), "memberprofilediv contents are hidden again" );
|
||||||
plus();
|
plus();
|
||||||
|
@ -121,11 +121,11 @@ test("Popcorn LinkedIn Plugin", function () {
|
||||||
companyid: "1441",
|
companyid: "1441",
|
||||||
target: "companyinsiderdiv",
|
target: "companyinsiderdiv",
|
||||||
apikey: "ZOLRI2rzQS_oaXELpPF0aksxwFFEvoxAFZRLfHjaAhcGPfOX0Ds4snkJpWwKs8gk",
|
apikey: "ZOLRI2rzQS_oaXELpPF0aksxwFFEvoxAFZRLfHjaAhcGPfOX0Ds4snkJpWwKs8gk",
|
||||||
start: 13,
|
start: 1,
|
||||||
end: 15
|
end: 3
|
||||||
});
|
});
|
||||||
|
|
||||||
popped.exec( 14, function() {
|
popped.exec( 2, function() {
|
||||||
|
|
||||||
ok( /block/.test( companyinsiderdiv.style.display ), "companyinsiderdiv contents are displayed" );
|
ok( /block/.test( companyinsiderdiv.style.display ), "companyinsiderdiv contents are displayed" );
|
||||||
plus();
|
plus();
|
||||||
|
@ -133,7 +133,7 @@ test("Popcorn LinkedIn Plugin", function () {
|
||||||
plus();
|
plus();
|
||||||
});
|
});
|
||||||
|
|
||||||
popped.exec( 16, function() {
|
popped.exec( 4, function() {
|
||||||
|
|
||||||
ok( /none/.test( companyinsiderdiv.style.display ), "companyinsiderdiv contents are hidden again" );
|
ok( /none/.test( companyinsiderdiv.style.display ), "companyinsiderdiv contents are hidden again" );
|
||||||
plus();
|
plus();
|
||||||
|
@ -149,13 +149,13 @@ test("Popcorn LinkedIn Plugin", function () {
|
||||||
format: "inline",
|
format: "inline",
|
||||||
target: "companyprofilediv",
|
target: "companyprofilediv",
|
||||||
apikey: "ZOLRI2rzQS_oaXELpPF0aksxwFFEvoxAFZRLfHjaAhcGPfOX0Ds4snkJpWwKs8gk",
|
apikey: "ZOLRI2rzQS_oaXELpPF0aksxwFFEvoxAFZRLfHjaAhcGPfOX0Ds4snkJpWwKs8gk",
|
||||||
start: 17,
|
start: 1,
|
||||||
end: 19
|
end: 3
|
||||||
});
|
});
|
||||||
|
|
||||||
setupId = popped.getLastTrackEventId();
|
setupId = popped.getLastTrackEventId();
|
||||||
|
|
||||||
popped.exec( 18, function() {
|
popped.exec( 2, function() {
|
||||||
|
|
||||||
ok( /block/.test( companyprofilediv.style.display ), "companyprofilediv contents are displayed" );
|
ok( /block/.test( companyprofilediv.style.display ), "companyprofilediv contents are displayed" );
|
||||||
plus();
|
plus();
|
||||||
|
@ -163,7 +163,7 @@ test("Popcorn LinkedIn Plugin", function () {
|
||||||
plus();
|
plus();
|
||||||
});
|
});
|
||||||
|
|
||||||
popped.exec( 20, function() {
|
popped.exec( 4, function() {
|
||||||
|
|
||||||
ok( /none/.test( companyprofilediv.style.display ), "companyprofilediv contents are hidden again" );
|
ok( /none/.test( companyprofilediv.style.display ), "companyprofilediv contents are hidden again" );
|
||||||
plus();
|
plus();
|
||||||
|
|
|
@ -27,14 +27,14 @@ test( "Popcorn lower third Plugin", function () {
|
||||||
|
|
||||||
popped.lowerthird({
|
popped.lowerthird({
|
||||||
start: 0, // seconds
|
start: 0, // seconds
|
||||||
end: 5, // seconds
|
end: 2, // seconds
|
||||||
salutation: "Mr",
|
salutation: "Mr",
|
||||||
name: "Hyde",
|
name: "Hyde",
|
||||||
role: "Monster"
|
role: "Monster"
|
||||||
} )
|
} )
|
||||||
.lowerthird({
|
.lowerthird({
|
||||||
start: 3, // seconds
|
start: 2, // seconds
|
||||||
end: 10, // seconds
|
end: 4, // seconds
|
||||||
target: "lowerthirddiv",
|
target: "lowerthirddiv",
|
||||||
salutation: "Dr",
|
salutation: "Dr",
|
||||||
name: "Jekyll",
|
name: "Jekyll",
|
||||||
|
@ -47,12 +47,12 @@ test( "Popcorn lower third Plugin", function () {
|
||||||
plus();
|
plus();
|
||||||
});
|
});
|
||||||
|
|
||||||
popped.exec( 4, function() {
|
popped.exec( 3, function() {
|
||||||
equals ( lowerthirddiv.innerHTML, "Dr Jekyll<br>Person", "second lowerthird is visible" );
|
equals ( lowerthirddiv.innerHTML, "Dr Jekyll<br>Person", "second lowerthird is visible" );
|
||||||
plus();
|
plus();
|
||||||
});
|
});
|
||||||
|
|
||||||
popped.exec( 11, function() {
|
popped.exec( 5, function() {
|
||||||
equals ( popped.container.innerHTML, "", "first lowerthird is empty" );
|
equals ( popped.container.innerHTML, "", "first lowerthird is empty" );
|
||||||
plus();
|
plus();
|
||||||
equals ( lowerthirddiv.innerHTML, "", "second lowerthird is empty" );
|
equals ( lowerthirddiv.innerHTML, "", "second lowerthird is empty" );
|
||||||
|
|
|
@ -23,8 +23,8 @@ test('Popcorn Mustache Plugin', function () {
|
||||||
|
|
||||||
// Static strings
|
// Static strings
|
||||||
popped.mustache({
|
popped.mustache({
|
||||||
start: 1, // seconds
|
start: 0, // seconds
|
||||||
end: 3, // seconds
|
end: 2, // seconds
|
||||||
template: '<h1>{{heading}}</h1>',
|
template: '<h1>{{heading}}</h1>',
|
||||||
data: '{"heading": "mustache - test 1/3"}',
|
data: '{"heading": "mustache - test 1/3"}',
|
||||||
target: 'mustache-div',
|
target: 'mustache-div',
|
||||||
|
@ -33,8 +33,8 @@ test('Popcorn Mustache Plugin', function () {
|
||||||
|
|
||||||
// Dynamic functions
|
// Dynamic functions
|
||||||
popped.mustache({
|
popped.mustache({
|
||||||
start: 5, // seconds
|
start: 2, // seconds
|
||||||
end: 7, // seconds
|
end: 4, // seconds
|
||||||
template: function(plugin, options) {
|
template: function(plugin, options) {
|
||||||
return '<h1>{{heading}}</h1>';
|
return '<h1>{{heading}}</h1>';
|
||||||
},
|
},
|
||||||
|
@ -46,8 +46,8 @@ test('Popcorn Mustache Plugin', function () {
|
||||||
|
|
||||||
// Template + Object literal
|
// Template + Object literal
|
||||||
popped.mustache({
|
popped.mustache({
|
||||||
start: 9, // seconds
|
start: 4, // seconds
|
||||||
end: 11, // seconds
|
end: 5, // seconds
|
||||||
template: function(plugin, options) {
|
template: function(plugin, options) {
|
||||||
return '<h1>{{heading}}</h1>';
|
return '<h1>{{heading}}</h1>';
|
||||||
},
|
},
|
||||||
|
@ -68,18 +68,18 @@ test('Popcorn Mustache Plugin', function () {
|
||||||
|
|
||||||
var t = Math.floor(video.currentTime);
|
var t = Math.floor(video.currentTime);
|
||||||
|
|
||||||
if (t === 2 && !two) {
|
if (t === 1 && !two) {
|
||||||
pass(1, 3);
|
pass(1, 3);
|
||||||
two = true;
|
two = true;
|
||||||
} else if (t === 6 && !six) {
|
} else if (t === 3 && !six) {
|
||||||
pass(2, 3);
|
pass(2, 3);
|
||||||
six = true;
|
six = true;
|
||||||
} else if (t === 10 && !ten) {
|
} else if (t === 4 && !ten) {
|
||||||
pass(3, 3);
|
pass(3, 3);
|
||||||
ten = true;
|
ten = true;
|
||||||
}
|
}
|
||||||
|
|
||||||
if (t === 11) {
|
if (t === 6) {
|
||||||
video.pause();
|
video.pause();
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
|
@ -28,7 +28,7 @@ test( "Popcorn OpenMap Plugin", function () {
|
||||||
|
|
||||||
popped.openmap({
|
popped.openmap({
|
||||||
start: 0,
|
start: 0,
|
||||||
end: 5,
|
end: 4,
|
||||||
type: 'ROADMAP',
|
type: 'ROADMAP',
|
||||||
target: 'map',
|
target: 'map',
|
||||||
lat: 43.665429,
|
lat: 43.665429,
|
||||||
|
@ -37,7 +37,7 @@ test( "Popcorn OpenMap Plugin", function () {
|
||||||
} )
|
} )
|
||||||
.openmap({
|
.openmap({
|
||||||
start: 0,
|
start: 0,
|
||||||
end: 5,
|
end: 4,
|
||||||
type: 'SATELLITE',
|
type: 'SATELLITE',
|
||||||
target: 'map2',
|
target: 'map2',
|
||||||
lat: 40.943926,
|
lat: 40.943926,
|
||||||
|
@ -46,7 +46,7 @@ test( "Popcorn OpenMap Plugin", function () {
|
||||||
} )
|
} )
|
||||||
.openmap( {
|
.openmap( {
|
||||||
start: 0,
|
start: 0,
|
||||||
end: 5,
|
end: 4,
|
||||||
type: 'TERRAIN',
|
type: 'TERRAIN',
|
||||||
target: 'map3',
|
target: 'map3',
|
||||||
lat: 40.943926,
|
lat: 40.943926,
|
||||||
|
@ -55,7 +55,7 @@ test( "Popcorn OpenMap Plugin", function () {
|
||||||
} )
|
} )
|
||||||
.openmap( {
|
.openmap( {
|
||||||
start: 0,
|
start: 0,
|
||||||
end: 5,
|
end: 4,
|
||||||
target: 'map4',
|
target: 'map4',
|
||||||
lat: 40.943926,
|
lat: 40.943926,
|
||||||
lng: -78.968525,
|
lng: -78.968525,
|
||||||
|
@ -66,7 +66,7 @@ test( "Popcorn OpenMap Plugin", function () {
|
||||||
|
|
||||||
setupId = popped.getLastTrackEventId();
|
setupId = popped.getLastTrackEventId();
|
||||||
|
|
||||||
popped.exec( 4, function() {
|
popped.exec( 3, function() {
|
||||||
ok(OpenLayers, "OpenLayers is available");
|
ok(OpenLayers, "OpenLayers is available");
|
||||||
plus();
|
plus();
|
||||||
|
|
||||||
|
@ -94,7 +94,7 @@ test( "Popcorn OpenMap Plugin", function () {
|
||||||
plus();
|
plus();
|
||||||
|
|
||||||
} )
|
} )
|
||||||
.exec( 6, function() {
|
.exec( 5, function() {
|
||||||
ok (document.getElementById('openmapdiv2').style.display === "none" &&
|
ok (document.getElementById('openmapdiv2').style.display === "none" &&
|
||||||
document.getElementById('openmapdiv3').style.display === "none" &&
|
document.getElementById('openmapdiv3').style.display === "none" &&
|
||||||
document.getElementById('openmapdiv4').style.display === "none" &&
|
document.getElementById('openmapdiv4').style.display === "none" &&
|
||||||
|
|
|
@ -30,7 +30,7 @@ test("Popcorn wikipedia Plugin", function () {
|
||||||
} )
|
} )
|
||||||
.wikipedia({
|
.wikipedia({
|
||||||
start: 4, // seconds
|
start: 4, // seconds
|
||||||
end: 8, // seconds
|
end: 5, // seconds
|
||||||
src: 'http://en.wikipedia.org/wiki/S%C3%A3o_Paulo',
|
src: 'http://en.wikipedia.org/wiki/S%C3%A3o_Paulo',
|
||||||
target: 'wikidiv'
|
target: 'wikidiv'
|
||||||
} )
|
} )
|
||||||
|
@ -53,7 +53,7 @@ test("Popcorn wikipedia Plugin", function () {
|
||||||
plus();
|
plus();
|
||||||
});
|
});
|
||||||
|
|
||||||
popped.exec( 5, function() {
|
popped.exec( 4, function() {
|
||||||
ok (theArticle.innerHTML !== "", "wikidiv now contains information" );
|
ok (theArticle.innerHTML !== "", "wikidiv now contains information" );
|
||||||
plus();
|
plus();
|
||||||
equals (theArticle.childElementCount, 2, "wikidiv now contains two child elements" );
|
equals (theArticle.childElementCount, 2, "wikidiv now contains two child elements" );
|
||||||
|
|
Загрузка…
Ссылка в новой задаче