attempt to fix integration tests (#1085)

main
Michael Fix 4 years ago committed by GitHub
parent 361d170f7e
commit 53b838edd5
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23

@ -29,9 +29,7 @@ describe('background color', () => {
const darkRed = '#D0021B' const darkRed = '#D0021B'
const darkRedTile = `[title="${darkRed}"]` const darkRedTile = `[title="${darkRed}"]`
openPicker() openPicker()
cy.get(picker) cy.get(picker).find(darkRedTile).click()
.find(darkRedTile)
.click()
closePicker() closePicker()
// changing background color triggers url change // changing background color triggers url change
@ -52,13 +50,10 @@ describe('background color', () => {
editorVisible() editorVisible()
const pink = 'ff00ff' const pink = 'ff00ff'
openPicker() openPicker().find(`input[value="FF0000"]`).clear().type(`${pink}{enter}`)
.find(`input[value="FF0000"]`)
.clear()
.type(`${pink}{enter}`)
closePicker() closePicker()
cy.url().should('contain', `?bg=rgba(${encodeURIComponent('255,0,255,1')}`) cy.url().should(url => expect(decodeURIComponent(url)).to.contain(`?bg=rgba(255,0,255,1)`))
cy.get('.container-bg .bg').should('have.css', 'background-color', 'rgb(255, 0, 255)') cy.get('.container-bg .bg').should('have.css', 'background-color', 'rgb(255, 0, 255)')
}) })
}) })

Loading…
Cancel
Save