add some unit tests for view registering and finding