Browse Source

driver.switchTo().alert().accept()

Artur Paikin 8 years ago
parent
commit
e3a5e6b156
1 changed files with 5 additions and 0 deletions
  1. 5 0
      test/acceptance/fallback.spec.js

+ 5 - 0
test/acceptance/fallback.spec.js

@@ -25,6 +25,11 @@ module.exports = function (driver, platform, host) {
 
     driver.findElement({css: '.UppyForm button'}).click()
 
+    // this should solve some mysterious alert error when Travis runs the test
+    driver.switchTo().alert().accept().catch(function (err) {
+      console.log(err)
+    })
+
     function isRedirectedAfterUpload () {
       return driver.getCurrentUrl().then(function (val) {
         console.log('current url is ', val)