2012-09-11 28 views
1

我只是试图测试我的用户模型。`主题':参数的错误数量(1代表0)(ArgumentError)使用水豚

错误来自测试此位。

describe User do 
    before do 
    @user = User.new(email: "[email protected]", password:"foobar", 
       password_confirmation:"foobar", goal:"cut") 
    end 

    subject(@user)  
    . 
    . 
    . 

这里是确切的错误:

rspec-core-2.10.1/lib/rspec/core/subject.rb:180:in `subject': wrong number of arguments (1 for 0) (ArgumentError) 

感谢您的帮助!

回答

相关问题