From d0527f8dfa14eb0f34f39dbef41d843fdd7d8a3e Mon Sep 17 00:00:00 2001 From: Fatema Moaiyadi Date: Fri, 29 Oct 2021 22:43:15 +0530 Subject: [PATCH] Adds test-cases for JSON resources marshaling --- github/repos_test.go | 14 ++++++++++++++ 1 file changed, 14 insertions(+) diff --git a/github/repos_test.go b/github/repos_test.go index 09b5e9277ee..f79d894bdee 100644 --- a/github/repos_test.go +++ b/github/repos_test.go @@ -2367,3 +2367,17 @@ func TestAdvancedSecurity_Marshal(t *testing.T) { testJSONMarshal(t, u, want) } + +func TestAuthorizedActorsOnly_Marshal(t *testing.T) { + testJSONMarshal(t, &AuthorizedActorsOnly{}, "{}") + + u := &AuthorizedActorsOnly{ + From: Bool(true), + } + + want := `{ + "from" : true + }` + + testJSONMarshal(t, u, want) +}