correct few bugs in the debug test