Skip to content

Commit

Permalink
Merge pull request #731 from stripe/remi-add-refund-new-properties
Browse files Browse the repository at this point in the history
Add missing properties on the Refund resource
  • Loading branch information
brandur-stripe authored Nov 28, 2018
2 parents b83cfb3 + 638f907 commit e84eaa3
Show file tree
Hide file tree
Showing 3 changed files with 16 additions and 12 deletions.
2 changes: 1 addition & 1 deletion .travis.yml
Original file line number Diff line number Diff line change
Expand Up @@ -30,7 +30,7 @@ cache:
env:
global:
# If changing this number, please also change it in `testing/testing.go`.
- STRIPE_MOCK_VERSION=0.37.0
- STRIPE_MOCK_VERSION=0.38.0

go:
- "1.9"
Expand Down
24 changes: 14 additions & 10 deletions refund.go
Original file line number Diff line number Diff line change
Expand Up @@ -43,16 +43,20 @@ type RefundListParams struct {
// Refund is the resource representing a Stripe refund.
// For more details see https://stripe.com/docs/api#refunds.
type Refund struct {
Amount int64 `json:"amount"`
BalanceTransaction *BalanceTransaction `json:"balance_transaction"`
Charge *Charge `json:"charge"`
Created int64 `json:"created"`
Currency Currency `json:"currency"`
ID string `json:"id"`
Metadata map[string]string `json:"metadata"`
Reason RefundReason `json:"reason"`
ReceiptNumber string `json:"receipt_number"`
Status RefundStatus `json:"status"`
Amount int64 `json:"amount"`
BalanceTransaction *BalanceTransaction `json:"balance_transaction"`
Charge *Charge `json:"charge"`
Created int64 `json:"created"`
Currency Currency `json:"currency"`
FailureBalanceTransaction *BalanceTransaction `json:"failure_balance_transaction"`
ID string `json:"id"`
Metadata map[string]string `json:"metadata"`
Object string `json:"object"`
Reason RefundReason `json:"reason"`
ReceiptNumber string `json:"receipt_number"`
SourceTransferReversal *Reversal `json:"source_transfer_reversal"`
Status RefundStatus `json:"status"`
TransferReversal *Reversal `json:"transfer_reversal"`
}

// RefundList is a list object for refunds.
Expand Down
2 changes: 1 addition & 1 deletion testing/testing.go
Original file line number Diff line number Diff line change
Expand Up @@ -25,7 +25,7 @@ const (
// added in a more recent version of stripe-mock, we can show people a
// better error message instead of the test suite crashing with a bunch of
// confusing 404 errors or the like.
MockMinimumVersion = "0.37.0"
MockMinimumVersion = "0.38.0"

// TestMerchantID is a token that can be used to represent a merchant ID in
// simple tests.
Expand Down

0 comments on commit e84eaa3

Please sign in to comment.