mirror of
https://github.com/pulsar-edit/pulsar.git
synced 2024-09-20 07:28:08 +03:00
Use correct fontWeight value in ThemeManager spec
In Chrome 66+ it seems that getComputedStyle().fontWeight returns the computed numeric value of the style instead of the original descriptive name. We now look for value '700' which corresponds to the value of 'bold'.
This commit is contained in:
parent
eee7ae8abe
commit
ff429230f1
@ -251,9 +251,9 @@ h2 {
|
||||
it('returns a disposable allowing styles applied by the given path to be removed', function () {
|
||||
const cssPath = require.resolve('./fixtures/css.css')
|
||||
|
||||
expect(getComputedStyle(document.body).fontWeight).not.toBe('bold')
|
||||
expect(getComputedStyle(document.body).fontWeight).not.toBe('700')
|
||||
const disposable = atom.themes.requireStylesheet(cssPath)
|
||||
expect(getComputedStyle(document.body).fontWeight).toBe('bold')
|
||||
expect(getComputedStyle(document.body).fontWeight).toBe('700')
|
||||
|
||||
let styleElementRemovedHandler
|
||||
atom.styles.onDidRemoveStyleElement(styleElementRemovedHandler = jasmine.createSpy('styleElementRemovedHandler'))
|
||||
|
Loading…
Reference in New Issue
Block a user