Browse Source

fix(fifty-shades-of-cold): fix test

- change querySelector for first test
pull/1819/merge
nprimo 2 years ago committed by Niccolò Primo
parent
commit
4df6305906
  1. 11
      dom/fifty-shades-of-cold_test.js

11
dom/fifty-shades-of-cold_test.js

@ -13,10 +13,13 @@ export const tests = []
tests.push(async ({ page, eq }) => {
// check that the css is properly generated
const style = await page.$$eval('style', nodes => nodes[1].innerHTML)
const classes = style
.split('}')
.map(s => s.replace(/(\.|{|:|;|\s+)/g, ''))
const style = await page.$$eval('head style', nodes =>
nodes.map(n => n.innerText),
)
const classes = style[0]
.split('\n')
.map(s => s.replace(/(\.|{|:|;|\s+|})/g, ''))
.filter(Boolean)
.sort()

Loading…
Cancel
Save