test detaching