Additional tests and updated hide footprint to match show
This commit is contained in:
@ -4,3 +4,9 @@ const {hide} = require('./_30s.js');
|
||||
test('hide is a Function', () => {
|
||||
expect(hide).toBeInstanceOf(Function);
|
||||
});
|
||||
test('hide hides an element', () => {
|
||||
let el = document.createElement('div');
|
||||
el.setAttribute('style', 'display: block;');
|
||||
hide(el);
|
||||
expect(el.style.display).toBe('none');
|
||||
});
|
||||
|
||||
Reference in New Issue
Block a user