我在Devise中发送确认电子邮件时遇到了一些问题.这就是我想为此功能编写测试的原因.当我不创建自己的邮件时,我怎么能这样做?
我决定,这应该足够了:
it 'should send an email' do
user
put :complete, params
user.send(:send_confirmation_notification?).should == true
end
Run Code Online (Sandbox Code Playgroud)
如果我错过了什么,请告诉我.