Error after listing 21.8

I am getting an error after writing the code of listing 21.8. I am getting an error for the mock function import statement. When I am trying to import the package it is not showing the mock function in the import statement. I have to import
But I am not getting this reference. Instead of this I am getting
But even after importing it the error is not resolving.
Pls anyone help me.