prepared code for autotest