fix in the registration function, added more test cases