mirror of
https://github.com/gosticks/DefinitelyTyped.git
synced 2025-10-16 12:05:41 +00:00
* add types for chai-webdriverio * fix lint warning and remove extra lint rules * fix compilation * added types from webdriverio * try to fix build * try to fix build
31 lines
676 B
TypeScript
31 lines
676 B
TypeScript
import chai = require('chai');
|
|
import webdriverio = require('webdriverio');
|
|
import chaiWebdriverio = require('chai-webdriverio');
|
|
|
|
const options = {
|
|
desiredCapabilities: {
|
|
browserName: 'firefox'
|
|
}
|
|
};
|
|
|
|
const browser = webdriverio.remote(options);
|
|
chai.use(chaiWebdriverio(browser));
|
|
|
|
const selector = 'Hello, World!';
|
|
|
|
chai.expect(selector).to.be.there();
|
|
|
|
chai.expect(selector).to.be.visible();
|
|
|
|
chai.expect(selector).to.have.text(selector);
|
|
|
|
chai.expect(selector).to.have.text(/regex/);
|
|
|
|
chai.expect(selector).to.have.count(10);
|
|
|
|
chai.expect(selector).to.have.value('x');
|
|
|
|
chai.expect(selector).to.have.value(/regex/);
|
|
|
|
chai.expect(selector).to.have.focus();
|