pagseguro_catcher 0.0.3 → 0.0.4
Sign up to get free protection for your applications and to get access to all the features.
- data/README.textile +16 -0
- data/VERSION +1 -1
- data/lib/pagseguro_catcher/constants.rb +1 -1
- data/lib/pagseguro_catcher/core_ext/string.rb +5 -0
- data/lib/pagseguro_catcher/transaction/amount.rb +6 -7
- data/lib/pagseguro_catcher/transaction/base.rb +20 -5
- data/lib/pagseguro_catcher/transaction/item.rb +16 -0
- data/lib/pagseguro_catcher/transaction/sender.rb +25 -0
- data/lib/pagseguro_catcher/transaction.rb +17 -0
- data/lib/pagseguro_catcher.rb +1 -0
- data/pagseguro_catcher.gemspec +13 -7
- data/spec/support/return.xml +1 -1
- data/spec/transaction/amount_spec.rb +4 -10
- data/spec/transaction/base_spec.rb +36 -3
- data/spec/transaction/item_spec.rb +21 -0
- data/spec/transaction/sender_spec.rb +36 -0
- metadata +129 -79
data/README.textile
CHANGED
@@ -6,6 +6,22 @@ h2. Soon
|
|
6
6
|
|
7
7
|
I'll describe how to use this one, but it's easy :-)
|
8
8
|
|
9
|
+
h2. TODO
|
10
|
+
|
11
|
+
h3. 0.1.0
|
12
|
+
|
13
|
+
* parse correctly all the sections of the return (items, sender, shipping are missing);
|
14
|
+
* implement a @method_missing@ in @::Transaction::Base@ to delegate to @#[]@
|
15
|
+
|
16
|
+
h3. 0.2.0
|
17
|
+
|
18
|
+
* implement a nice way to rescue the @::Checker#check@ method, when the request isn't successfull or the return is invalid
|
19
|
+
|
20
|
+
h3. 0.3.0:
|
21
|
+
|
22
|
+
* maybe some nice logs?
|
23
|
+
|
24
|
+
|
9
25
|
h2. Contributing to pagseguro_catcher
|
10
26
|
|
11
27
|
* Check out the latest master to make sure the feature hasn't been implemented or the bug hasn't been fixed yet
|
data/VERSION
CHANGED
@@ -1 +1 @@
|
|
1
|
-
0.0.
|
1
|
+
0.0.4
|
@@ -1,31 +1,30 @@
|
|
1
1
|
module PagseguroCatcher
|
2
2
|
module Transaction
|
3
3
|
|
4
|
-
class Amount
|
5
|
-
attr_accessor :body
|
4
|
+
class Amount < Transaction::Body
|
6
5
|
|
7
6
|
def initialize(body)
|
8
7
|
self.body = body
|
9
8
|
end
|
10
9
|
|
11
10
|
def gross
|
12
|
-
self
|
11
|
+
self[:grossAmount].to_f
|
13
12
|
end
|
14
13
|
|
15
14
|
def discount
|
16
|
-
self
|
15
|
+
self[:discountAmount].to_f
|
17
16
|
end
|
18
17
|
|
19
18
|
def fee
|
20
|
-
self
|
19
|
+
self[:feeAmount].to_f
|
21
20
|
end
|
22
21
|
|
23
22
|
def net
|
24
|
-
self
|
23
|
+
self[:netAmount].to_f
|
25
24
|
end
|
26
25
|
|
27
26
|
def extra
|
28
|
-
self
|
27
|
+
self[:extraAmount].to_f
|
29
28
|
end
|
30
29
|
|
31
30
|
end
|
@@ -1,8 +1,8 @@
|
|
1
|
+
#p = PagseguroCatcher::Transaction::Base.new(File.open('spec/support/return.xml').read)
|
1
2
|
module PagseguroCatcher
|
2
3
|
module Transaction
|
3
4
|
|
4
|
-
class Base
|
5
|
-
attr_accessor :body
|
5
|
+
class Base < Transaction::Body
|
6
6
|
|
7
7
|
def initialize(xml)
|
8
8
|
self.body = Hash.from_xml(xml)["transaction"]
|
@@ -14,8 +14,23 @@ module PagseguroCatcher
|
|
14
14
|
@amount
|
15
15
|
end
|
16
16
|
|
17
|
-
def
|
18
|
-
self.body
|
17
|
+
def sender
|
18
|
+
@sender ||= PagseguroCatcher::Transaction::Sender.new(self.body)
|
19
|
+
@sender
|
20
|
+
end
|
21
|
+
|
22
|
+
def items
|
23
|
+
@items = []
|
24
|
+
|
25
|
+
self[:items][:item].each do |item|
|
26
|
+
@items << PagseguroCatcher::Transaction::Item.new(item)
|
27
|
+
end
|
28
|
+
|
29
|
+
@items
|
30
|
+
end
|
31
|
+
|
32
|
+
def each_item
|
33
|
+
self.items.each { |item| yield item }
|
19
34
|
end
|
20
35
|
|
21
36
|
def date
|
@@ -42,7 +57,7 @@ module PagseguroCatcher
|
|
42
57
|
PAYMENT_CODES[self[:paymentMethod][:code].to_i]
|
43
58
|
end
|
44
59
|
|
45
|
-
#TODO -
|
60
|
+
#TODO - items, shipping
|
46
61
|
|
47
62
|
end
|
48
63
|
|
@@ -0,0 +1,25 @@
|
|
1
|
+
module PagseguroCatcher
|
2
|
+
module Transaction
|
3
|
+
|
4
|
+
class Sender < Transaction::Body
|
5
|
+
|
6
|
+
def initialize(body)
|
7
|
+
self.body = body[:sender]
|
8
|
+
end
|
9
|
+
|
10
|
+
def name
|
11
|
+
self[:name]
|
12
|
+
end
|
13
|
+
|
14
|
+
def email
|
15
|
+
self[:email]
|
16
|
+
end
|
17
|
+
|
18
|
+
def phone
|
19
|
+
{ :area => self[:phone][:areaCode], :number => self[:phone][:number] }
|
20
|
+
end
|
21
|
+
|
22
|
+
end
|
23
|
+
|
24
|
+
end
|
25
|
+
end
|
@@ -1,6 +1,23 @@
|
|
1
1
|
module PagseguroCatcher
|
2
2
|
module Transaction
|
3
|
+
|
4
|
+
class Body
|
5
|
+
attr_accessor :body
|
6
|
+
|
7
|
+
def [](param)
|
8
|
+
self.body[param.to_sym]
|
9
|
+
end
|
10
|
+
|
11
|
+
def method_missing(name, *args)
|
12
|
+
return self[name] if self.body.has_key?(name.to_sym)
|
13
|
+
super
|
14
|
+
end
|
15
|
+
|
16
|
+
end
|
17
|
+
|
3
18
|
autoload :Base, 'pagseguro_catcher/transaction/base'
|
4
19
|
autoload :Amount, 'pagseguro_catcher/transaction/amount'
|
20
|
+
autoload :Sender, 'pagseguro_catcher/transaction/sender'
|
21
|
+
autoload :Item, 'pagseguro_catcher/transaction/item'
|
5
22
|
end
|
6
23
|
end
|
data/lib/pagseguro_catcher.rb
CHANGED
data/pagseguro_catcher.gemspec
CHANGED
@@ -5,11 +5,11 @@
|
|
5
5
|
|
6
6
|
Gem::Specification.new do |s|
|
7
7
|
s.name = %q{pagseguro_catcher}
|
8
|
-
s.version = "0.0.
|
8
|
+
s.version = "0.0.4"
|
9
9
|
|
10
10
|
s.required_rubygems_version = Gem::Requirement.new(">= 0") if s.respond_to? :required_rubygems_version=
|
11
|
-
s.authors = [
|
12
|
-
s.date = %q{2011-10-
|
11
|
+
s.authors = ["Matias H. Leidemer"]
|
12
|
+
s.date = %q{2011-10-15}
|
13
13
|
s.description = %q{This gem provides a simple way to check and parse the PagSeguro transaction notification.}
|
14
14
|
s.email = %q{matiasleidemer@gmail.com}
|
15
15
|
s.extra_rdoc_files = [
|
@@ -30,24 +30,30 @@ Gem::Specification.new do |s|
|
|
30
30
|
"lib/pagseguro_catcher/checker.rb",
|
31
31
|
"lib/pagseguro_catcher/constants.rb",
|
32
32
|
"lib/pagseguro_catcher/core_ext/Hash.rb",
|
33
|
+
"lib/pagseguro_catcher/core_ext/string.rb",
|
33
34
|
"lib/pagseguro_catcher/transaction.rb",
|
34
35
|
"lib/pagseguro_catcher/transaction/amount.rb",
|
35
36
|
"lib/pagseguro_catcher/transaction/base.rb",
|
37
|
+
"lib/pagseguro_catcher/transaction/item.rb",
|
38
|
+
"lib/pagseguro_catcher/transaction/sender.rb",
|
36
39
|
"pagseguro_catcher.gemspec",
|
37
40
|
"spec/checker_spec.rb",
|
38
41
|
"spec/pagseguro_catcher_spec.rb",
|
39
42
|
"spec/spec_helper.rb",
|
40
43
|
"spec/support/return.xml",
|
41
44
|
"spec/transaction/amount_spec.rb",
|
42
|
-
"spec/transaction/base_spec.rb"
|
45
|
+
"spec/transaction/base_spec.rb",
|
46
|
+
"spec/transaction/item_spec.rb",
|
47
|
+
"spec/transaction/sender_spec.rb"
|
43
48
|
]
|
44
49
|
s.homepage = %q{http://github.com/matiasleidemer/pagseguro_catcher}
|
45
|
-
s.licenses = [
|
46
|
-
s.require_paths = [
|
47
|
-
s.rubygems_version = %q{1.
|
50
|
+
s.licenses = ["MIT"]
|
51
|
+
s.require_paths = ["lib"]
|
52
|
+
s.rubygems_version = %q{1.3.7}
|
48
53
|
s.summary = %q{A simple gem to parse PagSeguro transaction notification.}
|
49
54
|
|
50
55
|
if s.respond_to? :specification_version then
|
56
|
+
current_version = Gem::Specification::CURRENT_SPECIFICATION_VERSION
|
51
57
|
s.specification_version = 3
|
52
58
|
|
53
59
|
if Gem::Version.new(Gem::VERSION) >= Gem::Version.new('1.2.0') then
|
data/spec/support/return.xml
CHANGED
@@ -14,38 +14,32 @@ describe "Amount" do
|
|
14
14
|
|
15
15
|
describe "#gross" do
|
16
16
|
it "returns the gross amount as a float" do
|
17
|
-
amount.body[:grossAmount] = "49900.00"
|
18
17
|
amount.gross.should == 49900.00
|
19
18
|
end
|
20
19
|
end
|
21
20
|
|
22
21
|
describe "#discount" do
|
23
22
|
it "returns the discount amount as a float" do
|
24
|
-
amount.
|
25
|
-
amount.discount.should == 900.00
|
23
|
+
amount.discount.should == 0.00
|
26
24
|
end
|
27
25
|
end
|
28
26
|
|
29
27
|
describe "#fee" do
|
30
28
|
it "returns the fee amount as a float" do
|
31
|
-
amount.
|
32
|
-
amount.fee.should == 150.00
|
29
|
+
amount.fee.should == 0.00
|
33
30
|
end
|
34
31
|
end
|
35
32
|
|
36
33
|
describe "#net" do
|
37
34
|
it "returns the net amount as a float" do
|
38
|
-
amount.
|
39
|
-
amount.net.should == 160.00
|
35
|
+
amount.net.should == 49900.00
|
40
36
|
end
|
41
37
|
end
|
42
38
|
|
43
39
|
describe "#extra" do
|
44
40
|
it "returns the extra amount as a float" do
|
45
|
-
amount.
|
46
|
-
amount.extra.should == 170.00
|
41
|
+
amount.extra.should == 0.00
|
47
42
|
end
|
48
43
|
end
|
49
|
-
|
50
44
|
|
51
45
|
end
|
@@ -25,6 +25,27 @@ describe "Transaction" do
|
|
25
25
|
end
|
26
26
|
end
|
27
27
|
|
28
|
+
describe "#sender" do
|
29
|
+
it "returns an Sender object" do
|
30
|
+
transaction.sender.should be_a(PagseguroCatcher::Transaction::Sender)
|
31
|
+
end
|
32
|
+
end
|
33
|
+
|
34
|
+
describe "#items" do
|
35
|
+
it "returns an array of items objects" do
|
36
|
+
transaction.items.should be_a(Array)
|
37
|
+
transaction.items.first.should be_a(PagseguroCatcher::Transaction::Item)
|
38
|
+
end
|
39
|
+
end
|
40
|
+
|
41
|
+
describe "#each_item" do
|
42
|
+
it "yields each item" do
|
43
|
+
transaction.each_item do |item|
|
44
|
+
item.should be_a(PagseguroCatcher::Transaction::Item)
|
45
|
+
end
|
46
|
+
end
|
47
|
+
end
|
48
|
+
|
28
49
|
describe "#date" do
|
29
50
|
it "returns the date response as a DateTime object" do
|
30
51
|
transaction.body[:date] = "2011-02-10T16:13:41.000-03:00"
|
@@ -32,7 +53,7 @@ describe "Transaction" do
|
|
32
53
|
end
|
33
54
|
end
|
34
55
|
|
35
|
-
describe "#
|
56
|
+
describe "#last_event_date" do
|
36
57
|
it "returns the last event date response as a DateTime object" do
|
37
58
|
transaction.body[:lastEventDate] = "2011-10-04T15:48:59.000-03:00"
|
38
59
|
transaction.last_event_date.should == DateTime.new(2011, 10, 04, 15, 48, 59, "-03:00")
|
@@ -54,17 +75,29 @@ describe "Transaction" do
|
|
54
75
|
end
|
55
76
|
|
56
77
|
describe "#payment_method_type" do
|
57
|
-
it "
|
78
|
+
it "returns the human value for the payment method" do
|
58
79
|
transaction.body[:paymentMethod][:type] = "1"
|
59
80
|
transaction.payment_method_type.should == "Cartão de crédito"
|
60
81
|
end
|
61
82
|
end
|
62
83
|
|
63
84
|
describe "#payment_method_code" do
|
64
|
-
it "
|
85
|
+
it "returns the human value for the payment method" do
|
65
86
|
transaction.body[:paymentMethod][:code] = "101"
|
66
87
|
transaction.payment_method_code.should == "Cartão de crédito Visa"
|
67
88
|
end
|
68
89
|
end
|
69
90
|
|
91
|
+
describe "#method_missing" do
|
92
|
+
it "tries to run #[] with the method name" do
|
93
|
+
transaction.should_not respond_to :installmentCount
|
94
|
+
transaction.installmentCount.should == "1"
|
95
|
+
end
|
96
|
+
|
97
|
+
it "raises exception if the parameter does not exist" do
|
98
|
+
transaction.should_not respond_to :non_existant_method
|
99
|
+
lambda { transaction.non_existant_method }.should raise_error(NoMethodError)
|
100
|
+
end
|
101
|
+
end
|
102
|
+
|
70
103
|
end
|
@@ -0,0 +1,21 @@
|
|
1
|
+
require File.expand_path(File.dirname(__FILE__) + '/../spec_helper')
|
2
|
+
|
3
|
+
describe "Item" do
|
4
|
+
|
5
|
+
let(:xml) { File.open(File.expand_path(File.dirname(__FILE__) + '/../support/return.xml')).read }
|
6
|
+
let(:transaction) { PagseguroCatcher::Transaction::Base.new(xml) }
|
7
|
+
let(:item) { PagseguroCatcher::Transaction::Item.new(transaction[:items][:item].first) }
|
8
|
+
|
9
|
+
describe ".initialize" do
|
10
|
+
it "assigns the body" do
|
11
|
+
item.body.should be_a(Hash)
|
12
|
+
end
|
13
|
+
end
|
14
|
+
|
15
|
+
describe "#amount" do
|
16
|
+
it "returns the amount as a float" do
|
17
|
+
item.amount.should == 24300.00
|
18
|
+
end
|
19
|
+
end
|
20
|
+
|
21
|
+
end
|
@@ -0,0 +1,36 @@
|
|
1
|
+
# -*- encoding: utf-8 -*-
|
2
|
+
require File.expand_path(File.dirname(__FILE__) + '/../spec_helper')
|
3
|
+
|
4
|
+
describe "Sender" do
|
5
|
+
|
6
|
+
let(:xml) { File.open(File.expand_path(File.dirname(__FILE__) + '/../support/return.xml')).read }
|
7
|
+
let(:transaction) { PagseguroCatcher::Transaction::Base.new(xml) }
|
8
|
+
let(:sender) { PagseguroCatcher::Transaction::Sender.new(transaction.body) }
|
9
|
+
|
10
|
+
describe ".initialize" do
|
11
|
+
it "assigns the body" do
|
12
|
+
sender.body.should be_a(Hash)
|
13
|
+
end
|
14
|
+
end
|
15
|
+
|
16
|
+
describe "#name" do
|
17
|
+
it "returns the senders name" do
|
18
|
+
sender.name.should eql "José Comprador"
|
19
|
+
end
|
20
|
+
end
|
21
|
+
|
22
|
+
describe "#email" do
|
23
|
+
it "returns the senders email" do
|
24
|
+
sender.email.should eql "comprador@uol.com.br"
|
25
|
+
end
|
26
|
+
end
|
27
|
+
|
28
|
+
describe "#phone" do
|
29
|
+
it "returns the senders phone" do
|
30
|
+
phone = sender.phone
|
31
|
+
phone.should == { :area => "11", :number => "56273440" }
|
32
|
+
end
|
33
|
+
end
|
34
|
+
|
35
|
+
|
36
|
+
end
|
metadata
CHANGED
@@ -1,113 +1,151 @@
|
|
1
|
-
--- !ruby/object:Gem::Specification
|
1
|
+
--- !ruby/object:Gem::Specification
|
2
2
|
name: pagseguro_catcher
|
3
|
-
version: !ruby/object:Gem::Version
|
4
|
-
|
5
|
-
prerelease:
|
3
|
+
version: !ruby/object:Gem::Version
|
4
|
+
hash: 23
|
5
|
+
prerelease: false
|
6
|
+
segments:
|
7
|
+
- 0
|
8
|
+
- 0
|
9
|
+
- 4
|
10
|
+
version: 0.0.4
|
6
11
|
platform: ruby
|
7
|
-
authors:
|
12
|
+
authors:
|
8
13
|
- Matias H. Leidemer
|
9
14
|
autorequire:
|
10
15
|
bindir: bin
|
11
16
|
cert_chain: []
|
12
|
-
|
13
|
-
|
14
|
-
|
17
|
+
|
18
|
+
date: 2011-10-15 00:00:00 -03:00
|
19
|
+
default_executable:
|
20
|
+
dependencies:
|
21
|
+
- !ruby/object:Gem::Dependency
|
22
|
+
type: :runtime
|
23
|
+
prerelease: false
|
15
24
|
name: httparty
|
16
|
-
|
25
|
+
version_requirements: &id001 !ruby/object:Gem::Requirement
|
17
26
|
none: false
|
18
|
-
requirements:
|
19
|
-
- -
|
20
|
-
- !ruby/object:Gem::Version
|
21
|
-
|
27
|
+
requirements:
|
28
|
+
- - ">="
|
29
|
+
- !ruby/object:Gem::Version
|
30
|
+
hash: 3
|
31
|
+
segments:
|
32
|
+
- 0
|
33
|
+
version: "0"
|
34
|
+
requirement: *id001
|
35
|
+
- !ruby/object:Gem::Dependency
|
22
36
|
type: :runtime
|
23
37
|
prerelease: false
|
24
|
-
version_requirements: *70216239563300
|
25
|
-
- !ruby/object:Gem::Dependency
|
26
38
|
name: activesupport
|
27
|
-
|
39
|
+
version_requirements: &id002 !ruby/object:Gem::Requirement
|
28
40
|
none: false
|
29
|
-
requirements:
|
30
|
-
- -
|
31
|
-
- !ruby/object:Gem::Version
|
32
|
-
|
41
|
+
requirements:
|
42
|
+
- - ">="
|
43
|
+
- !ruby/object:Gem::Version
|
44
|
+
hash: 3
|
45
|
+
segments:
|
46
|
+
- 0
|
47
|
+
version: "0"
|
48
|
+
requirement: *id002
|
49
|
+
- !ruby/object:Gem::Dependency
|
33
50
|
type: :runtime
|
34
51
|
prerelease: false
|
35
|
-
version_requirements: *70216239562580
|
36
|
-
- !ruby/object:Gem::Dependency
|
37
52
|
name: i18n
|
38
|
-
|
53
|
+
version_requirements: &id003 !ruby/object:Gem::Requirement
|
39
54
|
none: false
|
40
|
-
requirements:
|
41
|
-
- -
|
42
|
-
- !ruby/object:Gem::Version
|
43
|
-
|
44
|
-
|
55
|
+
requirements:
|
56
|
+
- - ">="
|
57
|
+
- !ruby/object:Gem::Version
|
58
|
+
hash: 3
|
59
|
+
segments:
|
60
|
+
- 0
|
61
|
+
version: "0"
|
62
|
+
requirement: *id003
|
63
|
+
- !ruby/object:Gem::Dependency
|
64
|
+
type: :development
|
45
65
|
prerelease: false
|
46
|
-
version_requirements: *70216239561880
|
47
|
-
- !ruby/object:Gem::Dependency
|
48
66
|
name: rspec
|
49
|
-
|
67
|
+
version_requirements: &id004 !ruby/object:Gem::Requirement
|
50
68
|
none: false
|
51
|
-
requirements:
|
69
|
+
requirements:
|
52
70
|
- - ~>
|
53
|
-
- !ruby/object:Gem::Version
|
71
|
+
- !ruby/object:Gem::Version
|
72
|
+
hash: 3
|
73
|
+
segments:
|
74
|
+
- 2
|
75
|
+
- 3
|
76
|
+
- 0
|
54
77
|
version: 2.3.0
|
78
|
+
requirement: *id004
|
79
|
+
- !ruby/object:Gem::Dependency
|
55
80
|
type: :development
|
56
81
|
prerelease: false
|
57
|
-
version_requirements: *70216239561360
|
58
|
-
- !ruby/object:Gem::Dependency
|
59
82
|
name: bundler
|
60
|
-
|
83
|
+
version_requirements: &id005 !ruby/object:Gem::Requirement
|
61
84
|
none: false
|
62
|
-
requirements:
|
85
|
+
requirements:
|
63
86
|
- - ~>
|
64
|
-
- !ruby/object:Gem::Version
|
87
|
+
- !ruby/object:Gem::Version
|
88
|
+
hash: 23
|
89
|
+
segments:
|
90
|
+
- 1
|
91
|
+
- 0
|
92
|
+
- 0
|
65
93
|
version: 1.0.0
|
94
|
+
requirement: *id005
|
95
|
+
- !ruby/object:Gem::Dependency
|
66
96
|
type: :development
|
67
97
|
prerelease: false
|
68
|
-
version_requirements: *70216239560820
|
69
|
-
- !ruby/object:Gem::Dependency
|
70
98
|
name: jeweler
|
71
|
-
|
99
|
+
version_requirements: &id006 !ruby/object:Gem::Requirement
|
72
100
|
none: false
|
73
|
-
requirements:
|
101
|
+
requirements:
|
74
102
|
- - ~>
|
75
|
-
- !ruby/object:Gem::Version
|
103
|
+
- !ruby/object:Gem::Version
|
104
|
+
hash: 7
|
105
|
+
segments:
|
106
|
+
- 1
|
107
|
+
- 6
|
108
|
+
- 4
|
76
109
|
version: 1.6.4
|
110
|
+
requirement: *id006
|
111
|
+
- !ruby/object:Gem::Dependency
|
77
112
|
type: :development
|
78
113
|
prerelease: false
|
79
|
-
version_requirements: *70216239560220
|
80
|
-
- !ruby/object:Gem::Dependency
|
81
114
|
name: rcov
|
82
|
-
|
115
|
+
version_requirements: &id007 !ruby/object:Gem::Requirement
|
83
116
|
none: false
|
84
|
-
requirements:
|
85
|
-
- -
|
86
|
-
- !ruby/object:Gem::Version
|
87
|
-
|
117
|
+
requirements:
|
118
|
+
- - ">="
|
119
|
+
- !ruby/object:Gem::Version
|
120
|
+
hash: 3
|
121
|
+
segments:
|
122
|
+
- 0
|
123
|
+
version: "0"
|
124
|
+
requirement: *id007
|
125
|
+
- !ruby/object:Gem::Dependency
|
88
126
|
type: :development
|
89
127
|
prerelease: false
|
90
|
-
version_requirements: *70216239559400
|
91
|
-
- !ruby/object:Gem::Dependency
|
92
128
|
name: fakeweb
|
93
|
-
|
129
|
+
version_requirements: &id008 !ruby/object:Gem::Requirement
|
94
130
|
none: false
|
95
|
-
requirements:
|
96
|
-
- -
|
97
|
-
- !ruby/object:Gem::Version
|
98
|
-
|
99
|
-
|
100
|
-
|
101
|
-
|
102
|
-
|
103
|
-
|
131
|
+
requirements:
|
132
|
+
- - ">="
|
133
|
+
- !ruby/object:Gem::Version
|
134
|
+
hash: 3
|
135
|
+
segments:
|
136
|
+
- 0
|
137
|
+
version: "0"
|
138
|
+
requirement: *id008
|
139
|
+
description: This gem provides a simple way to check and parse the PagSeguro transaction notification.
|
104
140
|
email: matiasleidemer@gmail.com
|
105
141
|
executables: []
|
142
|
+
|
106
143
|
extensions: []
|
107
|
-
|
144
|
+
|
145
|
+
extra_rdoc_files:
|
108
146
|
- LICENSE.txt
|
109
147
|
- README.textile
|
110
|
-
files:
|
148
|
+
files:
|
111
149
|
- .document
|
112
150
|
- .rspec
|
113
151
|
- .travis.yml
|
@@ -121,9 +159,12 @@ files:
|
|
121
159
|
- lib/pagseguro_catcher/checker.rb
|
122
160
|
- lib/pagseguro_catcher/constants.rb
|
123
161
|
- lib/pagseguro_catcher/core_ext/Hash.rb
|
162
|
+
- lib/pagseguro_catcher/core_ext/string.rb
|
124
163
|
- lib/pagseguro_catcher/transaction.rb
|
125
164
|
- lib/pagseguro_catcher/transaction/amount.rb
|
126
165
|
- lib/pagseguro_catcher/transaction/base.rb
|
166
|
+
- lib/pagseguro_catcher/transaction/item.rb
|
167
|
+
- lib/pagseguro_catcher/transaction/sender.rb
|
127
168
|
- pagseguro_catcher.gemspec
|
128
169
|
- spec/checker_spec.rb
|
129
170
|
- spec/pagseguro_catcher_spec.rb
|
@@ -131,32 +172,41 @@ files:
|
|
131
172
|
- spec/support/return.xml
|
132
173
|
- spec/transaction/amount_spec.rb
|
133
174
|
- spec/transaction/base_spec.rb
|
175
|
+
- spec/transaction/item_spec.rb
|
176
|
+
- spec/transaction/sender_spec.rb
|
177
|
+
has_rdoc: true
|
134
178
|
homepage: http://github.com/matiasleidemer/pagseguro_catcher
|
135
|
-
licenses:
|
179
|
+
licenses:
|
136
180
|
- MIT
|
137
181
|
post_install_message:
|
138
182
|
rdoc_options: []
|
139
|
-
|
183
|
+
|
184
|
+
require_paths:
|
140
185
|
- lib
|
141
|
-
required_ruby_version: !ruby/object:Gem::Requirement
|
186
|
+
required_ruby_version: !ruby/object:Gem::Requirement
|
142
187
|
none: false
|
143
|
-
requirements:
|
144
|
-
- -
|
145
|
-
- !ruby/object:Gem::Version
|
146
|
-
|
147
|
-
segments:
|
188
|
+
requirements:
|
189
|
+
- - ">="
|
190
|
+
- !ruby/object:Gem::Version
|
191
|
+
hash: 3
|
192
|
+
segments:
|
148
193
|
- 0
|
149
|
-
|
150
|
-
required_rubygems_version: !ruby/object:Gem::Requirement
|
194
|
+
version: "0"
|
195
|
+
required_rubygems_version: !ruby/object:Gem::Requirement
|
151
196
|
none: false
|
152
|
-
requirements:
|
153
|
-
- -
|
154
|
-
- !ruby/object:Gem::Version
|
155
|
-
|
197
|
+
requirements:
|
198
|
+
- - ">="
|
199
|
+
- !ruby/object:Gem::Version
|
200
|
+
hash: 3
|
201
|
+
segments:
|
202
|
+
- 0
|
203
|
+
version: "0"
|
156
204
|
requirements: []
|
205
|
+
|
157
206
|
rubyforge_project:
|
158
|
-
rubygems_version: 1.
|
207
|
+
rubygems_version: 1.3.7
|
159
208
|
signing_key:
|
160
209
|
specification_version: 3
|
161
210
|
summary: A simple gem to parse PagSeguro transaction notification.
|
162
211
|
test_files: []
|
212
|
+
|