Fix qmtest self test mode