Skip to content

Commit

Permalink
Test storage of !important as this creates a tuple rather than a st…
Browse files Browse the repository at this point in the history
…ring for the style
  • Loading branch information
eoghanmurray committed Feb 3, 2021
1 parent 87f740d commit b92e85a
Show file tree
Hide file tree
Showing 2 changed files with 24 additions and 0 deletions.
22 changes: 22 additions & 0 deletions test/__snapshots__/integration.test.ts.snap
Original file line number Diff line number Diff line change
Expand Up @@ -6006,6 +6006,28 @@ exports[`select2 1`] = `
\\"id\\": 35
}
},
{
\\"type\\": 3,
\\"data\\": {
\\"source\\": 0,
\\"texts\\": [],
\\"attributes\\": [
{
\\"id\\": 36,
\\"attributes\\": {
\\"style\\": {
\\"color\\": [
\\"black\\",
\\"important\\"
]
}
}
}
],
\\"removes\\": [],
\\"adds\\": []
}
},
{
\\"type\\": 3,
\\"data\\": {
Expand Down
2 changes: 2 additions & 0 deletions test/integration.test.ts
Original file line number Diff line number Diff line change
Expand Up @@ -134,6 +134,8 @@ describe('record integration tests', function (this: ISuite) {

// toggle the select box
await page.click('.select2-container');
// test storage of !important style
await page.evaluate('document.getElementById("select2-drop").setAttribute("style", document.getElementById("select2-drop").style.cssText + "color:black !important")');
await page.click('.select2-container');

const snapshots = await page.evaluate('window.snapshots');
Expand Down

0 comments on commit b92e85a

Please sign in to comment.