Sha256: 91f80515a0e467eca1ecbcf1a889f1313bf592779339b97198285f9b6abd23e5
Contents?: true
Size: 801 Bytes
Versions: 9
Compression:
Stored size: 801 Bytes
Contents
require "spec_helper" describe PagSeguro::Notification do let(:code) { '766B9C-AD4B044B04DA-77742F5FA653-E1AB24' } let(:type) { 'transaction' } let(:notification) { PagSeguro::Notification.new(code, type) } subject { notification } it { should respond_to(:transaction) } before do PagSeguro.email = 'mail' PagSeguro.token = 'token' end describe "#transaction" do context "with default credencials" do subject { notification.transaction } before do stub_request(:get, "https://ws.pagseguro.uol.com.br/v2/transactions/notifications/766B9C-AD4B044B04DA-77742F5FA653-E1AB24?email=mail&token=token"). to_return(:status => 200, :body => "", :headers => {}) end it { should be_a_kind_of(PagSeguro::Transaction) } end end end
Version data entries
9 entries across 9 versions & 1 rubygems