I'm trying Webdriverio Testrunner with Selenium Standalone.
(我正在尝试使用Selenium Standalone的Webdriverio Testrunner。)
One test I would like to do should check a global variable (window.myVar) but when I try to return the window object I receive something weird(我想做的一个测试应该检查一个全局变量(window.myVar),但是当我尝试返回窗口对象时,我收到一些奇怪的信息)
it('should return window', (done) => {
const url = 'http://www.example.com';
browser.url(url);
browser.waitForVisible('body', 20000);
browser.pause(1000);
browser.execute(getWindow)
.then(result => {
console.log(result);
});
});
(});)
This print:
(此打印:)
?{ sessionId: '6f0cd910-2ec8-11e8-80fb-bf4604ec860e',
status: 0,
value: { WINDOW: ':wdc:1521829902692' } }
What is WINDOW: ':wdc:1521829902692'?
(什么是WINDOW:':wdc:1521829902692'?)
How can I get the actual window object?(如何获得实际的窗口对象?)
ask by Luca S. translate from so
与恶龙缠斗过久,自身亦成为恶龙;凝视深渊过久,深渊将回以凝视…