Sha256: 21811e1f40de17f362191ec414b120ec5e209a39a40a77c47ca7dd7d9bd19e60

Contents?: true

Size: 512 Bytes

Versions: 3

Compression:

Stored size: 512 Bytes

Contents

require "spec_helper"

module PagseguroClient
  describe Notification do
    context "parse notification xml" do
      subject {
        Notification.create_by_xml(File.read("spec/support/notification.xml"))
      }

      # attr_accessor :code, :order_id, :status, :payment_method
      its(:code) { should == "9E884542-81B3-4419-9A75-BCC6FB495EF1" }
      its(:order_id) { should == "REF1234" }
      its(:status) { should == :approved }
      its(:payment_method) { should == :credit_card }
    end
  end
end

Version data entries

3 entries across 3 versions & 1 rubygems

Version Path
pagseguro_client-0.2.0 spec/pagseguro_client/notification_spec.rb
pagseguro_client-0.1.1 spec/pagseguro_client/notification_spec.rb
pagseguro_client-0.1.0 spec/pagseguro_client/notification_spec.rb