# ActionMailer failing test

**URL:** <https://www.ruby-forum.com/t/actionmailer-failing-test/156558>\
**Category:** Engines\
**Created:** [December 30, 2008, 12:33am UTC](https://www.ruby-forum.com/t/actionmailer-failing-test/156558 "2008-12-30T00:33:01Z")\
**Posts on this page:** 4\
**Page:** 1

<div class="post-metadata">

**Author:** ![Diego\_Algorta](https://www.ruby-forum.com/letter_avatar_proxy/v4/letter/d/ad7895/32.png) [@Diego\_Algorta](https://www.ruby-forum.com/u/Diego_Algorta)\
**Post date:** [December 30, 2008, 12:33am UTC](https://www.ruby-forum.com/t/actionmailer-failing-test/156558/1 "2008-12-30T00:33:01Z")

</div>

Hi all,

I have an app using rails 2.2.2 and engines from master branch commit  
5a2fb6db.

I have an Emailer \< ActionMailer::Base but I need to have some of the  
templates in the app and some others in an engines plugin. But as soon  
as I move some templates from app/views/emailer/ to  
vendor/plugins/my\_plugin/app/views/emailer/, it starts failing with  
MissingTemplate.

running rake test in engines says:

Finished in 0.403761 seconds.

1. Failure:  
test\_should\_work(ExceptionNotificationCompatibilityTest)

[./test/functional/exception\_notification\_compatibility\_test.rb:25:in  
`test\_should\_work’

/usr/local/lib/ruby/gems/1.8/gems/activesupport-2.2.2/lib/active\_support/testing/setup\_and\_teardown.rb:60:in  
` **send** ’

/usr/local/lib/ruby/gems/1.8/gems/activesupport-2.2.2/lib/active\_support/testing/setup\_and\_teardown.rb:60:in  
`run']: Exception raised: Class: <ActionView::MissingTemplate> Message: <"Missing template exception_notifier/exception_notification.erb in view path /home/diego/repos/git/activerain/activeagent-mainline-master/vendor/plugins/engines/test_app/app/views:/home/diego/repos/git/activerain/activeagent-mainline-master/vendor/plugins/engines/test_app/vendor/plugins/test_plugin_mailing/app/views:/home/diego/repos/git/activerain/activeagent-mainline-master/vendor/plugins/engines/test_app/vendor/plugins/test_assets/app/views:/home/diego/repos/git/activerain/activeagent-mainline-master/vendor/plugins/engines/test_app/vendor/plugins/beta_plugin/app/views:/home/diego/repos/git/activerain/activeagent-mainline-master/vendor/plugins/engines/test_app/vendor/plugins/alpha_plugin/app/views:/home/diego/repos/git/activerain/activeagent-mainline-master/vendor/plugins/engines/test_app/app/views:"> ---Backtrace--- /usr/local/lib/ruby/gems/1.8/gems/actionpack-2.2.2/lib/action_view/template.rb:95:in`find\_full\_path’  
/usr/local/lib/ruby/gems/1.8/gems/actionpack-2.2.2/lib/action\_view/template.rb:16:in  
`initialize’

Is this working for anyone else? Is it just my setup or do we have a  
real bug here? If this is failing for someone else too, I’ll be working  
on a patch. But I’d prefer to avoid it if it’s only MY problem.

Thanks,  
Diego

---

<div class="post-metadata">

**Author:** ![Diego\_Algorta](https://www.ruby-forum.com/letter_avatar_proxy/v4/letter/d/ad7895/32.png) [@Diego\_Algorta](https://www.ruby-forum.com/u/Diego_Algorta)\
**Post date:** [January 1, 2009, 6:05am UTC](https://www.ruby-forum.com/t/actionmailer-failing-test/156558/2 "2009-01-01T06:05:58Z")

</div>

Exactly the same problem with only using ExceptionNotifier. Please let  
me know if you find a solution.

Thanks,  
Eric

Diego Algorta wrote:

> Hi all,
> 
> I have an app using rails 2.2.2 and engines from master branch commit  
> 5a2fb6db.
> 
> I have an Emailer \< ActionMailer::Base but I need to have some of the  
> templates in the app and some others in an engines plugin. But as soon  
> as I move some templates from app/views/emailer/ to  
> vendor/plugins/my\_plugin/app/views/emailer/, it starts failing with  
> MissingTemplate.
> 
> running rake test in engines says:
> 
> Finished in 0.403761 seconds.
> 
> 1. Failure:  
> test\_should\_work(ExceptionNotificationCompatibilityTest)
> 
> [./test/functional/exception\_notification\_compatibility\_test.rb:25:in  
> `test\_should\_work’
> 
> /usr/local/lib/ruby/gems/1.8/gems/activesupport-2.2.2/lib/active\_support/testing/setup\_and\_teardown.rb:60:in  
> ` **send** ’
> 
> /usr/local/lib/ruby/gems/1.8/gems/activesupport-2.2.2/lib/active\_support/testing/setup\_and\_teardown.rb:60:in  
> `run’]:  
> Exception raised:  
> Class: ActionView::MissingTemplate  
> Message: \<"Missing template

---

<div class="post-metadata">

**Author:** ![Diego\_Algorta](https://www.ruby-forum.com/letter_avatar_proxy/v4/letter/d/ad7895/32.png) [@Diego\_Algorta](https://www.ruby-forum.com/u/Diego_Algorta)\
**Post date:** [January 6, 2009, 10:50am UTC](https://www.ruby-forum.com/t/actionmailer-failing-test/156558/3 "2009-01-06T10:50:41Z")

</div>

Hi,

This was caused by, I think, the ‘official’ plugin disappearing from  
visibility to script/plugin (the svn servers for rubyonrails were  
turned off). I’ve amended the test setup to use a direct URL to the  
plugin, and all should be good now.

James

---

<div class="post-metadata">

**Author:** ![Diego\_Algorta](https://www.ruby-forum.com/letter_avatar_proxy/v4/letter/d/ad7895/32.png) [@Diego\_Algorta](https://www.ruby-forum.com/u/Diego_Algorta)\
**Post date:** [January 6, 2009, 5:16pm UTC](https://www.ruby-forum.com/t/actionmailer-failing-test/156558/4 "2009-01-06T17:16:43Z")

</div>

Thanks James.

Also, it looks like the latest version of ExceptionNotifier, which is  
available through github, fixes the problem. It’s good to go.

Eric

James A. wrote:

> Hi,
> 
> This was caused by, I think, the ‘official’ plugin disappearing from  
> visibility to script/plugin (the svn servers for rubyonrails were  
> turned off). I’ve amended the test setup to use a direct URL to the  
> plugin, and all should be good now.
> 
> James
