cypress-cucumber-steps
Version:
Cypress Cucumber step definitions
33 lines • 978 B
JavaScript
;
Object.defineProperty(exports, "__esModule", { value: true });
exports.Then_I_count_elements = Then_I_count_elements;
var cypress_cucumber_preprocessor_1 = require("@badeball/cypress-cucumber-preprocessor");
var utils_1 = require("../utils");
/**
* Then I count elements:
*
* ```gherkin
* Then I count {int} elements
* ```
*
* @example
*
* Assert 10 elements are found:
*
* ```gherkin
* Then I count 10 elements
* ```
*
* A preceding step like {@link When_I_find_links_by_text | "When I find links by text"} is required. For example:
*
* ```gherkin
* When I find links by text "Link"
* Then I count 1 element
* ```
*/
function Then_I_count_elements(count) {
(0, utils_1.getCypressElement)().should('have.length', count);
}
(0, cypress_cucumber_preprocessor_1.Then)('I count {int} element', Then_I_count_elements);
(0, cypress_cucumber_preprocessor_1.Then)('I count {int} elements', Then_I_count_elements);
//# sourceMappingURL=count.js.map