Refactored out REST view tests to rest_view_test.go.