It should behave like resource

One pillar of my high code-coverage is this little plugin, which allows you to simply state that a controller or a action should behave RESTfully.

So far it is experimental, meaning it works on my machine 🙂
Any testers and contributes highly welcome.

Install instruction and usage.

Example

describe UsersController do
  before :each do
    login_as :quentin #if your controllers need login
    @item = @user = stub_model(User)#or anything else that has a to_param method
  end

  behave_like_resource
end
Advertisements

Leave a Reply

Fill in your details below or click an icon to log in:

WordPress.com Logo

You are commenting using your WordPress.com account. Log Out / Change )

Twitter picture

You are commenting using your Twitter account. Log Out / Change )

Facebook photo

You are commenting using your Facebook account. Log Out / Change )

Google+ photo

You are commenting using your Google+ account. Log Out / Change )

Connecting to %s