Is it possible to do this in the code of unit testing?