chore: Audit E2E tests for color schemes in Dashboard and Explore (#20807)

* Update properties tests

* Update selectors

* Verify charts changing colors

* Test shared and label colors

* Update dashboard edit test

* Enhance viz tests

* Remove chart ids

* Update color
This commit is contained in:
Geido
2022-08-09 07:49:46 +03:00
committed by GitHub
parent 58245dd7f7
commit 03764e6ae8
18 changed files with 296 additions and 55 deletions

View File

@@ -84,4 +84,19 @@ describe('Visualization > Histogram', () => {
});
cy.get('.chart-container svg .vx-bar').should('have.length', numBins);
});
it('should allow type to search color schemes and apply the scheme', () => {
cy.get('#controlSections-tab-display').click();
cy.get('.Control[data-test="color_scheme"]').scrollIntoView();
cy.get('.Control[data-test="color_scheme"] input[type="search"]')
.focus()
.type('supersetColors{enter}');
cy.get(
'.Control[data-test="color_scheme"] .ant-select-selection-item ul[data-test="supersetColors"]',
).should('exist');
cy.get('.histogram .vx-legend .vx-legend-shape div')
.first()
.should('have.css', 'background')
.and('contains', 'rgb(31, 168, 201)');
});
});