Skip to main content

Stage 2 Integration with Cypress


[Step 0] - Installation of dependencies

 npm --save @mapgrab/cypress

[Step 1] - Integration with framework

Add this changes to support/e2e.ts file

//support/e2e.ts

import { setupCommands } from '@mapgrab/cypress';

import './commands';

setupCommands();

[Step 2] - Write first test

describe('Map', { testIsolation: false }, () => {
it('should display city on map', () => {
cy.mapLocator('layer[id=cities]').first().should('be.visibleOnMap');
});
});