In this case, we're going to follow a very similar format as in case of should find user, creating the userId variable and setting it equal to a user ID that does not exist inside of our built-in users; something like 99 would get the job done:
it('should not find user', () => {
var userId = '99';
});
Next up, we'll be making a user variable, once again to store the return result from getUser, users.getUser, passing in our userId:
it('should not find user', () => {
var userId = '99';
var user = users.getUser(userId);
});
Now in this case, we would expect that undefined comes back, filter should return nothing and if you try to fetch the first item in an empty array, you're going to get undefined. We can prove that over in the Terminal by running node, and inside our little console we can create an empty array and we can access the first item:
>[][0]
We get back undefined. I'm going to shut that down, restart our test suite, and over inside users.test.js file we are going to go ahead and make our assertion. We're going to expect(user).toNotExist:
it ('should not find user', () => {
var userId = '99';
var user = users.getUser(userId);
expect(user).toNotExist();
});
I'm going to save the file and all of our test cases should still be passing:

That's great. Next up, we need to write the removeUser method and we also need to fill out the test cases.