Test migration to jest by hand
Apparently using regular expressions is way easier.
This commit is contained in:
5
test/smoothScroll/smoothScroll.js
Normal file
5
test/smoothScroll/smoothScroll.js
Normal file
@ -0,0 +1,5 @@
|
||||
const smoothScroll = element =>
|
||||
document.querySelector(element).scrollIntoView({
|
||||
behavior: 'smooth'
|
||||
|
||||
module.exports = smoothScroll;
|
||||
8
test/smoothScroll/smoothScroll.test.js
Normal file
8
test/smoothScroll/smoothScroll.test.js
Normal file
@ -0,0 +1,8 @@
|
||||
const expect = require('expect');
|
||||
const smoothScroll = require('./smoothScroll.js');
|
||||
|
||||
|
||||
test('smoothScroll is a Function', () => {
|
||||
expect(smoothScroll).toBeInstanceOf(Function);
|
||||
});
|
||||
|
||||
Reference in New Issue
Block a user