Sha256: 8daeeb90cb6ddff807b7510e9f35cc34ca0b194300b82be0f9e385522eb5e0fa
Contents?: true
Size: 635 Bytes
Versions: 2
Compression:
Stored size: 635 Bytes
Contents
require 'spec_helper' describe Api do let(:empty_response) { double('Request', body: '<xml />') } let(:host) { 'secure' } let(:key) { 'merchant' } let(:password) { 'password' } describe 'send request with defined host and key' do subject { Api.new(host, key, password) } it 'should send request with settings' do expect(RestClient).to receive(:post).with( "https://#{host}.payture.com/apim/Charge", { "OrderId" => 1, "Password" => password, "Key" => key } ).and_return(empty_response) subject.charge(1) end end end
Version data entries
2 entries across 2 versions & 1 rubygems
Version | Path |
---|---|
paytureman-1.0.0 | spec/requests/payture/api_spec.rb |
paytureman-0.7.0 | spec/requests/payture/api_spec.rb |