adding basic jest tests

This commit is contained in:
Ken
2019-02-15 20:23:26 -08:00
parent 988aea6c1d
commit f019207dba
4 changed files with 28 additions and 0 deletions
+16
View File
@@ -0,0 +1,16 @@
import { square } from '.';
describe('square', () => {
beforeEach(() => {
console.log('this happens before each test');
});
afterEach(() => {
console.log('this happens after each test');
});
it('should be able to give the square of two numbers', () => {
console.log('test');
expect(square(5)).toBe(25);
});
});