title: Integrating payu payment gateway (active_merchant_payu_in) with spree
body: <p>I am trying to integrate payu.in payment gateway with spree into my rails application. I have included gem 'active_merchant_payu_in' in the application. </p>
  
  <p>My app/models/spree/gateway/payu.rb looks like this:</p>
  
  <pre><code>module Spree
    class Gateway::Payu &lt; Gateway
      def provider_class
        ActiveMerchant::Billing::Integrations::PayuIn
      end
    end
  end
  </code></pre>
  
  <p>In application.rb</p>
  
  <pre><code>config.after_initialize do |app|
    app.config.spree.payment_methods += [
      Spree::Gateway::Payu
    ]
  end
  </code></pre>
  
  <p>Development.rb</p>
  
  <pre><code>config.after_initialize do
    ActiveMerchant::Billing::Base.mode = :test    
    $payu_merchant_id = ActiveMerchant::Billing::Integrations::PayuIn.merchant_id = '--ID--'
    $payu_secret_key = ActiveMerchant::Billing::Integrations::PayuIn.secret_key = '--Key--'    
  end
  </code></pre>
  
  <p>I have enabled Spree::Gateway::Payu from admin credentials. Now when i do a checkout i get below error.</p>
  
  <p><strong>NoMethodError in Spree::CheckoutController#update
  undefined method `authorize' for ActiveMerchant::Billing::Integrations::PayuIn:Module</strong></p>
  
  <p>can someone guide me towards right path.
  Many Thanks :)</p>