public
Rubygem
Description: Makes tests easy on the fingers and the eyes
Homepage: http://www.thoughtbot.com/projects/shoulda
Clone URL: git://github.com/thoughtbot/shoulda.git
fixed docs and added to test for should_have_instance_methods

git-svn-id: https://svn.thoughtbot.com/plugins/shoulda/trunk@234 
7bbfaf0e-4d1d-0410-9690-a8bb5f8ef2aa
tsaleh (author)
Wed Oct 31 06:50:08 -0700 2007
commit  2aba771ceed5d054d1fd15a8b4dba6194ea9018e
tree    ef9c4c1f0f3225f23fafed71c653137f3241ce62
parent  c07bff350ac626f5d8ad39bef007ebbf4cbbdb50
...
343
344
345
346
 
347
348
 
349
350
351
...
343
344
345
 
346
347
 
348
349
350
351
0
@@ -343,9 +343,9 @@ module ThoughtBot # :nodoc:
0
         end
0
       end
0
 
0
- # Ensure that instance methods exist.
0
+ # Ensure that the given instance methods are defined on the model.
0
       #
0
- # should_have_instance_methods :instance_method
0
+ # should_have_instance_methods :email, :name, :name=
0
       def should_have_instance_methods(*methods)
0
         get_options!(methods)
0
         klass = model_class
...
11
12
13
14
 
15
...
11
12
13
 
14
15
0
@@ -11,5 +11,5 @@ class UserTest < Test::Unit::TestCase
0
   should_ensure_value_in_range :age, 1..100
0
   should_protect_attributes :password
0
   should_have_class_methods :find, :destroy
0
- should_have_instance_methods :email, :age
0
+ should_have_instance_methods :email, :age, :email=, :valid?
0
 end

Comments

    No one has commented yet.