mirror of
https://github.com/maputnik/editor.git
synced 2025-12-27 08:30:02 +00:00
Updated to new webdriverio config api, and fixed failing tests.
This commit is contained in:
@@ -6,8 +6,10 @@ var helper = require("../helper");
|
||||
|
||||
|
||||
function closeModal(wdKey) {
|
||||
const selector = wd.$(wdKey);
|
||||
|
||||
browser.waitUntil(function() {
|
||||
const elem = $(wdKey);
|
||||
const elem = $(selector);
|
||||
return elem.isDisplayedInViewport();
|
||||
});
|
||||
|
||||
@@ -15,8 +17,9 @@ function closeModal(wdKey) {
|
||||
closeBtnSelector.click();
|
||||
|
||||
browser.waitUntil(function() {
|
||||
const elem = $(wdKey);
|
||||
return !elem.isDisplayed();
|
||||
return browser.execute((selector) => {
|
||||
return !document.querySelector(selector);
|
||||
}, selector);
|
||||
});
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user