进行邮件测试,你需要在dummy目录下的虚拟程序添加一个配置
In your config/enviroments/test.rb, by default you should have the line config.action_mailer.delivery_method = :test
config.action_mailer.delivery_method = :test
from
https://stackoverflow.com/questions/3995994/rspec-sends-emails-not-storing-in-actionmailerbase-deliveries-dont-know-wh