test terminate