extension update for countsearchresult to be coutnElement

This commit is contained in:
Carlos Jimenez 2018-08-02 14:07:57 +02:00
parent 8a9f69753a
commit 99d31f304f
1 changed files with 1 additions and 1 deletions

View File

@ -134,7 +134,7 @@ Nightmare.action('selectText', function(selector, done) {
.then(done); .then(done);
}); });
Nightmare.action('countSearchResults', function(selector, done) { Nightmare.action('countElement', function(selector, done) {
this.evaluate_now(selector => { this.evaluate_now(selector => {
return document.querySelectorAll(selector).length; return document.querySelectorAll(selector).length;
}, done, selector); }, done, selector);