UNPKG

webdriverio

Version:

Next-gen browser and mobile automation test framework for Node.js

54 lines (50 loc) 1.42 kB
/** * * Will return true when stable (in animation) or when unstable (not in animation). * * __Note:__ it's best to disable animations instead of using this command. * * <example> :index.html <head> <style> div { width: 200px; height: 200px; background-color: red; } #has-animation { animation: 3s 0s alternate slidein; } \@keyframes slidein { from { margin-left: 100%; width: 300%; } to { margin-left: 0%; width: 100%; } } </style> </head> <body> <div #has-animation></div> <div #has-no-animation></div> </body> :isStable.js it('should detect if an element is stable', async () => { let element = await $('#has-animation'); console.log(await element.isStable()); // outputs: false element = await $('#has-no-animation') console.log(await element.isStable()); // outputs: true }); * </example> * * @alias element.isStable * @return {Boolean} true if element is stable, false if unstable * @type state * */ export declare function isStable(this: WebdriverIO.Element): Promise<boolean>; //# sourceMappingURL=isStable.d.ts.map