(theme)
| 127 | // jsdom normalises hex to rgb(), so compare two themes rather than |
| 128 | // asserting on a literal colour value. |
| 129 | const bg = (theme) => |
| 130 | render( |
| 131 | <Editor code="const x = 1;" language="js" theme={theme} />, |
| 132 | ).container.querySelector("pre").style.backgroundColor; |
| 133 | |
| 134 | expect(bg(themes.github)).not.toBe(""); |
| 135 | expect(bg(themes.github)).not.toBe(bg(themes.nightOwl)); |