Fixed tests for new $resource