Skip to content

Commit

Permalink
Fix #2283 (#2284)
Browse files Browse the repository at this point in the history
GitHub Actions returns total_paid_minutes_used as floating point value.
The Implementation should accept this floating point value as float64.
  • Loading branch information
raynigon committed Feb 9, 2022
1 parent a842efc commit 2be8000
Show file tree
Hide file tree
Showing 2 changed files with 2 additions and 2 deletions.
2 changes: 1 addition & 1 deletion github/billing.go
Expand Up @@ -19,7 +19,7 @@ type BillingService service
// ActionBilling represents a GitHub Action billing.
type ActionBilling struct {
TotalMinutesUsed int `json:"total_minutes_used"`
TotalPaidMinutesUsed int `json:"total_paid_minutes_used"`
TotalPaidMinutesUsed float64 `json:"total_paid_minutes_used"`
IncludedMinutes int `json:"included_minutes"`
MinutesUsedBreakdown MinutesUsedBreakdown `json:"minutes_used_breakdown"`
}
Expand Down
2 changes: 1 addition & 1 deletion github/billing_test.go
Expand Up @@ -22,7 +22,7 @@ func TestBillingService_GetActionsBillingOrg(t *testing.T) {
testMethod(t, r, "GET")
fmt.Fprint(w, `{
"total_minutes_used": 305,
"total_paid_minutes_used": 0,
"total_paid_minutes_used": 0.0,
"included_minutes": 3000,
"minutes_used_breakdown": {
"UBUNTU": 205,
Expand Down

0 comments on commit 2be8000

Please sign in to comment.