Sha256: 46332c14c088fca5ef5503c8b1d907ecb17fad33eed2c7bfb1b093e6a6251601
Contents?: true
Size: 975 Bytes
Versions: 10
Compression:
Stored size: 975 Bytes
Contents
require 'spec_helper' require 'atpay/session' require 'atpay/token/bulk' describe AtPay::Token::Bulk do let(:partner_id) { 1 } let(:private_key) { 'DW93ArFKshINPeZOCfYer3riymL+HoRlZj92BNjek+Y=' } let(:public_key) { 'qIcshFT1NEh2JWPEp7+wVV8ibUFHKNew5apbNLGVqgI=' } let(:atpay_public_key) { 'DjnbXwK20VZpir+RLWsrLVwUinAkdeAmvla4M509GXQ=' } let(:atpay_private_key) { 'sS70ekGtxHIlzDhcogTECaJyjGJAzHUpVzM/d/M2ixA=' } let(:session) { AtPay::Session.new(partner_id, public_key, private_key) } let(:amount) { 20.0 } let(:url) { 'http://example.com/' } let(:user_data) { 'sku-123' } it 'creates a new token without exception' do token = AtPay::Token::Bulk.new(session, amount, user_data) expect(token.to_s).to match(/\A@.*@\z/) end it 'sets the authorization only version' do token = AtPay::Token::Bulk.new(session, amount, user_data) token.auth_only! expect(token.to_s).to match(/\A@.*@\z/) end end
Version data entries
10 entries across 10 versions & 1 rubygems