From 6387a9448dec3a903271745e7baddd14e0ba90c9 Mon Sep 17 00:00:00 2001 From: griffin_stewie Date: Tue, 5 Jan 2016 20:40:54 +0900 Subject: [PATCH] Add "SuspendedAt" field to User struct. --- github/users.go | 1 + github/users_test.go | 2 ++ 2 files changed, 3 insertions(+) diff --git a/github/users.go b/github/users.go index a041bbf..d8c74e2 100644 --- a/github/users.go +++ b/github/users.go @@ -35,6 +35,7 @@ type User struct { Following *int `json:"following,omitempty"` CreatedAt *Timestamp `json:"created_at,omitempty"` UpdatedAt *Timestamp `json:"updated_at,omitempty"` + SuspendedAt *Timestamp `json:"suspended_at,omitempty"` Type *string `json:"type,omitempty"` SiteAdmin *bool `json:"site_admin,omitempty"` TotalPrivateRepos *int `json:"total_private_repos,omitempty"` diff --git a/github/users_test.go b/github/users_test.go index 15ea3e8..c66ec22 100644 --- a/github/users_test.go +++ b/github/users_test.go @@ -32,6 +32,7 @@ func TestUser_marshall(t *testing.T) { Followers: Int(1), Following: Int(1), CreatedAt: &Timestamp{referenceTime}, + SuspendedAt: &Timestamp{referenceTime}, } want := `{ "login": "l", @@ -48,6 +49,7 @@ func TestUser_marshall(t *testing.T) { "followers": 1, "following": 1, "created_at": ` + referenceTimeStr + `, + "suspended_at": ` + referenceTimeStr + `, "url": "u" }` testJSONMarshal(t, u, want)