Closed eazylaykzy closed 6 years ago
Yes @ljharb , I'm using v21+ After going through the Readme Notice Github page, I found out the package has been donated to Facebook Jest, so i did a little search query on it, and fixed it with the code below:
it('should return the square of the number', () => {
let res = utils.square(5);
expect(res).toBe(25);
expect(typeof res).toBe('number');
});
Thanks @ljharb
I've been trying to figure out what went wrong with my code for the past few hours, but i think the
toBeA()
is giving this the below error message:1) should add two number: TypeError: Cannot read property 'toBeA' of undefined at Context.it (utils\utils.test.js:7:23)
Below is the actual code: