17
describe("st._arrow_table styling", () => {
19
cy.loadApp("http://localhost:3000/");
21
cy.get("[data-testid='stTable']").should("have.length", 3);
23
cy.prepForElementSnapshots();
26
it("displays unstyled table", () => {
27
cy.get("[data-testid='stTable']")
29
.find("table tbody tr td")
31
.should("contain", "1");
33
cy.get("[data-testid='stTable']")
35
.matchThemedSnapshots("arrow-table-unstyled");
38
it("displays table with custom formatted cells", () => {
39
cy.getIndexed("[data-testid='stTable']", 1)
40
.find("table tbody tr td")
42
.should("contain", "100.00%");
44
cy.getIndexed("[data-testid='stTable']", 1).matchThemedSnapshots(
45
"arrow-table-formatted-cells"
49
it("displays table with colored cells", () => {
50
cy.getIndexed("[data-testid='stTable']", 2)
51
.find("table tbody tr")
56
return cy.wrap(el).should("have.css", "color", "rgb(0, 0, 0)");
58
return cy.wrap(el).should("have.css", "color", "rgb(255, 0, 0)");
62
cy.getIndexed("[data-testid='stTable']", 2).matchThemedSnapshots(
63
"arrow-table-colored-cells"