Skip to content

Commit

Permalink
Event: RessourceId renamed as ResourceId
Browse files Browse the repository at this point in the history
  • Loading branch information
Sergiusz Woźnicki committed Dec 11, 2013
1 parent 0721b27 commit 8695374
Show file tree
Hide file tree
Showing 3 changed files with 7 additions and 4 deletions.
2 changes: 1 addition & 1 deletion lib/mangopay/version.rb
Original file line number Diff line number Diff line change
@@ -1,3 +1,3 @@
module MangoPay
VERSION = '3.0.6'
VERSION = '3.0.7'
end
2 changes: 1 addition & 1 deletion spec/lib/mangopay/event_spec.rb
Original file line number Diff line number Diff line change
Expand Up @@ -27,7 +27,7 @@
events = MangoPay::Event.fetch({'AfterDate' => payin['CreationDate'], 'BeforeDate' => payin['CreationDate']})
expect(events).to be_kind_of(Array)
expect(events.count).to be >= 1
expect(events.count {|e| e['RessourceId'] == payin['Id']}).to be >= 1
expect(events.count {|e| e['ResourceId'] == payin['Id']}).to be >= 1
end
end
end
7 changes: 5 additions & 2 deletions spec/lib/mangopay/transaction_spec.rb
Original file line number Diff line number Diff line change
Expand Up @@ -25,10 +25,13 @@
payin = new_payin_card_direct
payout = create_new_payout_bankwire(payin)
transactions = MangoPay::Transaction.fetch(new_wallet['Id'])

expect(transactions).to be_kind_of(Array)
expect(transactions.count).to eq 2
expect(transactions[0]['Id']).to eq payout['Id'] # last on top, so payout is before payin
expect(transactions[1]['Id']).to eq payin['Id']

transactions_ids = transactions.map {|t| t['Id']}
expect(transactions_ids).to include payin['Id']
expect(transactions_ids).to include payout['Id']
end

it 'accepts filtering params' do
Expand Down

0 comments on commit 8695374

Please sign in to comment.