title: how can I send an email from an IronWorker for a rails3 app?
body: <p>I followed all the docs for IronWorkerNG::Client.new and rails:</p>
  
  <p><a href="https://github.com/iron-io/iron_worker_rails_example" rel="nofollow">https://github.com/iron-io/iron_worker_rails_example</a></p>
  
  <p>My .worker file is doing:</p>
  
  <pre><code>runtime 'ruby'
  
  name 'CompanyList'
  
  merge_gem 'activerecord'
  merge_gem 'actionmailer'
  merge_gem 'pg'
  merge_gem 'aws-s3'
  
  dir '../app/models'
  file '../app/mailers/result_mailer.rb'
  file "../app/views/result_mailer/email.html.erb", "result_mailer"
  
  exec 'company_list.rb'
  remote
  </code></pre>
  
  <p>and my ruby file does:</p>
  
  <pre><code>require 'action_mailer'
  require 'active_record'
  require 'aws/s3'
  require 'pg'
  require 'models/company_list.rb' 
  require 'result_mailer.rb'
  
  puts "Starting CompanyList worker at #{Time.now}"
  
  ActiveRecord::Base.establish_connection(params['database'])
  mailer_config = params['mailer'].inject({}) { |memo, (k, v)| memo[k.to_sym] = v; memo }
  #ActionMailer::Base.prepend_view_path('.')
  ActionMailer::Base.view_paths = ['.']
  ActionMailer::Base.smtp_settings = mailer_config
  ActionMailer::Base.delivery_method = :smtp
  </code></pre>
  
  <p>But everytime I get this error:</p>
  
  <pre><code>/task/__gems__/gems/actionmailer-2.3.18/lib/action_mailer/base.rb:433:
  in `method_missing': undefined method `email' for ResultMailer:Class 
  (NoMethodError)
  from /task/models/company_list.rb:16:in `process_file'
  from /task/company_list.rb:18:in `&lt;top (required)&gt;'
  from /usr/local/lib/site_ruby/1.9.1/rubygems/custom_require.rb:36:in `require'
  from /usr/local/lib/site_ruby/1.9.1/rubygems/custom_require.rb:36:in `require'
  from __runner__.rb:213:in `&lt;main&gt;'
  </code></pre>
  
  <p>and ResultMailer DOES have an email method:</p>
  
  <pre><code>class ResultMailer &lt; ActionMailer::Base
  
    def email
      to = 'andrew@testdomain.com'
      mail :from =&gt; 'test@testdomain.com', :to =&gt; to, :subject =&gt; "Test"
    end
  
  end
  </code></pre>
  
  <p>any idea why action_mailer base line 433 is throwing that error?  I can call ResultMailer.email.deliver from the console on my local system just fine.  This error is on production with heroku and iron.io.</p>