Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- /* eslint-env mocha */
- /* global cy */
- describe('Date component sample', () => {
- before(() => {
- cy.visit('https://github-ylq5q4.stackblitz.io');
- });
- context('Calendar', () => {
- it('Auto closes the calendar', () => {
- const day = 5;
- cy.get('[data-context="container"]', { timeout: 20000 }).within(() => {
- cy.get('input').click();
- });
- cy.get('.owl-dt-popup').within(() => {
- cy.get('.owl-dt-calendar-cell-content')
- .contains(new RegExp(`^\\b${day}\\b$`))
- .click({ force: true });
- cy.wait(2000);
- });
- cy.get('.owl-dt-popup').should('.not.exist');
- });
- });
- });
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement