From ff85797ffcce6dffe9a36ec14e1d1efbba1c1e5b Mon Sep 17 00:00:00 2001 From: Shin'ya Ueoka Date: Sun, 26 May 2019 21:39:38 +0900 Subject: Fix settings parsing --- test/shared/Settings.test.ts | 4 ++++ 1 file changed, 4 insertions(+) (limited to 'test/shared') diff --git a/test/shared/Settings.test.ts b/test/shared/Settings.test.ts index 02cd022..04b28c4 100644 --- a/test/shared/Settings.test.ts +++ b/test/shared/Settings.test.ts @@ -186,5 +186,9 @@ describe('Settings', () => { expect(value.search.engines).to.be.an('object'); expect(value.blacklist).to.be.empty; }); + + it('throws a TypeError with an unknown field', () => { + expect(() => settings.valueOf({ name: 'alice' })).to.throw(TypeError) + }); }); }); -- cgit v1.2.3