]> khamidou — GitHub mirrors - popcorn-js.git/commitdiff
fixed unit test as per review [#358 state:peer-review-requested]
authorAnna Sobiepanek <annaopensource@gmail.com>
Mon, 14 Mar 2011 16:34:23 +0000 (12:34 -0400)
committerAnna Sobiepanek <annaopensource@gmail.com>
Mon, 14 Mar 2011 16:34:23 +0000 (12:34 -0400)
plugins/wikipedia/popcorn.wikipedia.unit.js

index e3cf43a3d00124a2f9fd051d06b56184e058446c..03b64f931f48d86cc70bfa79b9ece0771172ec1d 100644 (file)
@@ -22,43 +22,43 @@ test("Popcorn wikipedia Plugin", function () {
   plus();
   
   popped.wikipedia({
-      start: 5, // seconds
-      end: 10, // seconds
+      start: 1, // seconds
+      end: 3, // seconds
       src: 'http://en.wikipedia.org/wiki/Cape_Town',
       title: "this is an article",
       target: 'wikidiv'
     } )
     .wikipedia({
-      start: 12, // seconds
-      end: 20, // seconds
+      start: 4, // seconds
+      end: 8, // seconds
       src: 'http://en.wikipedia.org/wiki/S%C3%A3o_Paulo',
       target: 'wikidiv'
     } )
     .volume(0)
     .play();
     
-  popped.exec( 5, function() {
+  popped.exec( 2, function() {
     ok (theArticle.innerHTML !== "", "wikidiv now contains information" );
     plus();
     equals (theArticle.childElementCount, 2, "wikidiv now contains two child elements" );
     plus();
     equals (theArticle.childNodes[0].innerHTML, "this is an article", "wikidiv has the right title" );
     plus();
-    ok (theArticle.childNodes[1].innerHTML !="", "wikidiv has some content" );
+    ok (theArticle.childNodes[1].innerHTML !=="", "wikidiv has some content" );
     plus();
   });
   
-  popped.exec( 10, function() {
+  popped.exec( 3, function() {
     equals (theArticle.innerHTML, "", "wikidiv was cleared properly" );
     plus();
   });
   
-  popped.exec( 13, function() {
+  popped.exec( 5, function() {
     ok (theArticle.innerHTML !== "", "wikidiv now contains information" );
     plus();
     equals (theArticle.childElementCount, 2, "wikidiv now contains two child elements" );
     plus();
-    ok (theArticle.childNodes[1].innerHTML != "", "wikidiv has the right content" );
+    ok (theArticle.childNodes[1].innerHTML !== "", "wikidiv has the right content" );
     plus();
   });
 });