Skip to content

Commit

Permalink
test: Migrate embedded-mode test
Browse files Browse the repository at this point in the history
- remove check for place-input-component as it should not be visible
- remove old test
  • Loading branch information
TheGreatRefrigerator committed Dec 7, 2022
1 parent 15760d6 commit 1068b30
Show file tree
Hide file tree
Showing 2 changed files with 28 additions and 31 deletions.
28 changes: 28 additions & 0 deletions cypress/e2e/embedded-mode.cy.js
Original file line number Diff line number Diff line change
@@ -0,0 +1,28 @@
describe('embedded mode', () => {
it('renders correctly', () => {
cy.visit('/#/place/Heidelberg,BW,Germany/@8.692416,49.401247/data/%7B%22zoom%22:8,%22layer%22:%22county%22,%22country%22:%22Germany%22%7D/embed/en-us')
cy.get('.app-content')
cy.get('#app')
cy.get('#map-view').should('be.visible')
cy.get('.view-on-ors').should('be.visible')

cy.get('.leaflet-control-layers-toggle').should('not.be.visible')
cy.get('.simple-place-search').should('not.exist')
cy.get('.leaflet-control-zoom').should('not.exist')
cy.get('.leaflet-draw').should('not.exist')
cy.get('#polyline-measure-control').should('not.exist')
cy.get('.my-location-btn').should('not.exist')
cy.get('.accessibility-btn').should('not.exist')

cy.get('.place-input-component input[type=text]')
cy.get('.custom-html-icon-div').as('point')
cy.get('@point')
.should('have.css', 'background-color', 'rgb(255, 0, 0)')
cy.get('@point').should('have.length', 1)
cy.get('@point').click({force: true})
cy.get('.leaflet-popup')
cy.get('.leaflet-popup-content').should('contain.text', 'Heidelberg, BW,Germany')

// TODO: check scroll behaviour
})
})
31 changes: 0 additions & 31 deletions tests/e2e/specs/embedded-mode.spec.js

This file was deleted.

0 comments on commit 1068b30

Please sign in to comment.