diff --git a/src/app/malihu-scrollbar/malihu-scrollbar.service.spec.ts b/src/app/malihu-scrollbar/malihu-scrollbar.service.spec.ts index 1a0e29d..69774de 100644 --- a/src/app/malihu-scrollbar/malihu-scrollbar.service.spec.ts +++ b/src/app/malihu-scrollbar/malihu-scrollbar.service.spec.ts @@ -168,5 +168,12 @@ describe('MalihuScrollbarService:unit', () => { expect(returnValue).toBe(jQueryElement); }); + + it('should throw error when element type is unsupported', () => { + + const object = { object: null }; + + expect(() => mScrollbarService['getElement'](object)).toThrowError(`Unsupported element type in MalihuScrollbarService: ${object}`); + }); }); });