apply mock cleanup and mock cfg file