Sha256: 8e7411c97c928ea6c8132a254af7a80d997a8cceec7360768bed70fa16f05f9b

Contents?: true

Size: 879 Bytes

Versions: 3

Compression:

Stored size: 879 Bytes

Contents

# require 'emerson/matchers/action_controller/send_html_matcher'
require 'emerson/matchers/action_controller/send_json_matcher'

module Emerson
  module Matchers
    # By using the matchers you can quickly and easily create concise and
    # easy to read test suites.
    #
    # This code segment:
    #
    #   describe UsersController, "on GET to show with a valid id" do
    #     before(:each) do
    #       get :show, :id => User.first.to_param
    #     end
    #
    #     it { should assign_to(:user) }
    #     it { should respond_with(:success) }
    #     it { should render_template(:show) }
    #     it { should not_set_the_flash) }
    #
    #     it "should do something else really cool" do
    #       assigns[:user].id.should == 1
    #     end
    #   end
    #
    # Would produce 5 tests for the show action
    module ActionController
    end
  end
end

Version data entries

3 entries across 3 versions & 1 rubygems

Version Path
emerson-0.1.0.pre.4 lib/emerson/matchers/action_controller.rb
emerson-0.1.0.pre.3 lib/emerson/matchers/action_controller.rb
emerson-0.1.0.pre.2 lib/emerson/matchers/action_controller.rb