feat: add systemPreferences.getAnimationSettings() (#17382)

This commit is contained in:
Milan Burda 2019-03-19 20:15:40 +01:00 committed by Samuel Attard
parent 4d8e024b6d
commit 4c51fa93f5
4 changed files with 38 additions and 1 deletions

View file

@ -173,4 +173,14 @@ describe('systemPreferences module', () => {
assert.strictEqual(typeof systemPreferences.isInvertedColorScheme(), 'boolean')
})
})
describe('systemPreferences.getAnimationSettings()', () => {
it('returns an object with all properties', () => {
const settings = systemPreferences.getAnimationSettings()
assert.strictEqual(typeof settings, 'object')
assert.strictEqual(typeof settings.shouldRenderRichAnimation, 'boolean')
assert.strictEqual(typeof settings.scrollAnimationsEnabledBySystem, 'boolean')
assert.strictEqual(typeof settings.prefersReducedMotion, 'boolean')
})
})
})