Sha256: 9baee0e817df8c9e42c16ca6c6b859b1870192ac0dc5def34dff18e7074b619b

Contents?: true

Size: 722 Bytes

Versions: 3

Compression:

Stored size: 722 Bytes

Contents

require 'spec_helper'

describe Killbill::Cybersource::PaymentPlugin do
  before(:each) do
    Dir.mktmpdir do |dir|
      file = File.new(File.join(dir, 'cybersource.yml'), "w+")
      file.write(<<-eos)
:cybersource:
  :test: true
# As defined by spec_helper.rb
:database:
  :adapter: 'sqlite3'
  :database: 'test.db'
      eos
      file.close

      @plugin = Killbill::Cybersource::PaymentPlugin.new
      @plugin.logger = Logger.new(STDOUT)
      @plugin.logger.level = Logger::INFO
      @plugin.conf_dir = File.dirname(file)

      # Start the plugin here - since the config file will be deleted
      @plugin.start_plugin
    end
  end

  it 'should start and stop correctly' do
    @plugin.stop_plugin
  end
end

Version data entries

3 entries across 3 versions & 1 rubygems

Version Path
killbill-cybersource-0.0.4 spec/cybersource/base_plugin_spec.rb
killbill-cybersource-0.0.2 spec/cybersource/base_plugin_spec.rb
killbill-cybersource-0.0.1 spec/cybersource/base_plugin_spec.rb