]> git.ipfire.org Git - thirdparty/foundation/foundation-sites.git/commitdiff
Try putting a timeout before checking on test that's flaking on travis 9974/head
authorKevin Ball <kmball11@gmail.com>
Thu, 20 Apr 2017 21:02:45 +0000 (14:02 -0700)
committerKevin Ball <kmball11@gmail.com>
Thu, 20 Apr 2017 21:02:45 +0000 (14:02 -0700)
test/javascript/components/accordionMenu.js

index 140ee27706cdc1bef5df2021fbe1cd119ce63004..d2b57796d1f0f046f4f73db957ffead2c98a7ecd 100644 (file)
@@ -45,7 +45,7 @@ describe('Accordion Menu', function() {
   });
   
   describe('up()', function() {
-    it('closes the targeted submenu', function() {
+    it('closes the targeted submenu', function(done) {
       $html = $(template).appendTo('body');
       plugin = new Foundation.AccordionMenu($html);
 
@@ -53,7 +53,10 @@ describe('Accordion Menu', function() {
       plugin.down($html.find('.is-accordion-submenu').eq(0));
       
       plugin.up($html.find('.is-accordion-submenu').eq(0));
-      $html.find('.is-accordion-submenu').eq(0).should.be.hidden;
+      setTimeout(() => {
+        $html.find('.is-accordion-submenu').eq(0).should.be.hidden;
+        done();
+      }, 1);
     });
 
     it('toggles attributes of title of the targeted container', function() {
@@ -172,4 +175,4 @@ describe('Accordion Menu', function() {
     });
   });
 
-});
\ No newline at end of file
+});