fixed most test errors for register and reset