Sha256: 544ccdeb3bdec48bc3df7f1d1f0290c612f10cab64fae7401ace89ffa208f888

Contents?: true

Size: 721 Bytes

Versions: 7

Compression:

Stored size: 721 Bytes

Contents

require 'spec_helper'

module GoTransverseTractApi

  RSpec.describe BillingAccount::Refund do
    before(:each) { http_auth }

    let(:response)  { '<?xml version="1.0" encoding="UTF-8" standalone="yes"?>' }
    let(:eid) { '48406' }

    context ".create_refund" do
      it "creates a refund to the account" do
        data = {
          :amount => '47.00',
          :description => 'Refund Create',
          :original_payment => {
            eid: '123'
          },
          :refund_reason => {
            eid: '456'
          }
        }

        allow(subject).to receive(:create_refund).with(data).and_return(response)
        expect(subject.create_refund(data)).to eq(response)
      end
    end

  end
end

Version data entries

7 entries across 7 versions & 1 rubygems

Version Path
gotransverse-tract-api-0.5.2 spec/gotransverse-tract-api/billing_account/refund_spec.rb
gotransverse-tract-api-0.5.1 spec/gotransverse-tract-api/billing_account/refund_spec.rb
gotransverse-tract-api-0.5.0 spec/gotransverse-tract-api/billing_account/refund_spec.rb
gotransverse-tract-api-0.4.3 spec/gotransverse-tract-api/billing_account/refund_spec.rb
gotransverse-tract-api-0.4.2 spec/gotransverse-tract-api/billing_account/refund_spec.rb
gotransverse-tract-api-0.4.1 spec/gotransverse-tract-api/billing_account/refund_spec.rb
gotransverse-tract-api-0.4.0 spec/gotransverse-tract-api/billing_account/refund_spec.rb