2013-03-18 3 views

답변

5

당신은 10 사용자 당신이 expect 정규

expect{my_magic_method}.to change{User.count}.by(10) 

를 사용할 수 있습니다 만들어진 당신은 또한 반환 테스트하려는 경우하는지 테스트하려면 진정한

my_magic_method.should be_true 

official documentation

관련 문제