UNPKG

nightwatch

Version:

Easy to use Node.js based end-to-end testing solution for web applications using the W3C WebDriver API.

15 lines (14 loc) 422 B
"use strict"; Object.defineProperty(exports, "__esModule", { value: true }); const EventEmitter = require('events'); class Command extends EventEmitter { command(callback = function () { }) { this.client.setLocateStrategy(this.strategy); process.nextTick(() => { callback.call(this.api); this.emit('complete'); }); return this; } } module.exports = Command;