Register unit test and register implementation