github.com/google/go-github/v70@v70.0.0/github/github-stringify_test.go (about) 1 // Copyright 2019 The go-github AUTHORS. All rights reserved. 2 // 3 // Use of this source code is governed by a BSD-style 4 // license that can be found in the LICENSE file. 5 6 // Code generated by gen-stringify-tests; DO NOT EDIT. 7 // Instead, please run "go generate ./..." as described here: 8 // https://github.com/google/go-github/blob/master/CONTRIBUTING.md#submitting-a-patch 9 10 package github 11 12 import ( 13 "testing" 14 ) 15 16 func TestActionsAllowed_String(t *testing.T) { 17 t.Parallel() 18 v := ActionsAllowed{ 19 GithubOwnedAllowed: Ptr(false), 20 VerifiedAllowed: Ptr(false), 21 PatternsAllowed: []string{""}, 22 } 23 want := `github.ActionsAllowed{GithubOwnedAllowed:false, VerifiedAllowed:false, PatternsAllowed:[""]}` 24 if got := v.String(); got != want { 25 t.Errorf("ActionsAllowed.String = %v, want %v", got, want) 26 } 27 } 28 29 func TestActionsPermissions_String(t *testing.T) { 30 t.Parallel() 31 v := ActionsPermissions{ 32 EnabledRepositories: Ptr(""), 33 AllowedActions: Ptr(""), 34 SelectedActionsURL: Ptr(""), 35 } 36 want := `github.ActionsPermissions{EnabledRepositories:"", AllowedActions:"", SelectedActionsURL:""}` 37 if got := v.String(); got != want { 38 t.Errorf("ActionsPermissions.String = %v, want %v", got, want) 39 } 40 } 41 42 func TestActionsPermissionsEnterprise_String(t *testing.T) { 43 t.Parallel() 44 v := ActionsPermissionsEnterprise{ 45 EnabledOrganizations: Ptr(""), 46 AllowedActions: Ptr(""), 47 SelectedActionsURL: Ptr(""), 48 } 49 want := `github.ActionsPermissionsEnterprise{EnabledOrganizations:"", AllowedActions:"", SelectedActionsURL:""}` 50 if got := v.String(); got != want { 51 t.Errorf("ActionsPermissionsEnterprise.String = %v, want %v", got, want) 52 } 53 } 54 55 func TestActionsPermissionsRepository_String(t *testing.T) { 56 t.Parallel() 57 v := ActionsPermissionsRepository{ 58 Enabled: Ptr(false), 59 AllowedActions: Ptr(""), 60 SelectedActionsURL: Ptr(""), 61 } 62 want := `github.ActionsPermissionsRepository{Enabled:false, AllowedActions:"", SelectedActionsURL:""}` 63 if got := v.String(); got != want { 64 t.Errorf("ActionsPermissionsRepository.String = %v, want %v", got, want) 65 } 66 } 67 68 func TestAdminStats_String(t *testing.T) { 69 t.Parallel() 70 v := AdminStats{ 71 Issues: &IssueStats{}, 72 Hooks: &HookStats{}, 73 Milestones: &MilestoneStats{}, 74 Orgs: &OrgStats{}, 75 Comments: &CommentStats{}, 76 Pages: &PageStats{}, 77 Users: &UserStats{}, 78 Gists: &GistStats{}, 79 Pulls: &PullStats{}, 80 Repos: &RepoStats{}, 81 } 82 want := `github.AdminStats{Issues:github.IssueStats{}, Hooks:github.HookStats{}, Milestones:github.MilestoneStats{}, Orgs:github.OrgStats{}, Comments:github.CommentStats{}, Pages:github.PageStats{}, Users:github.UserStats{}, Gists:github.GistStats{}, Pulls:github.PullStats{}, Repos:github.RepoStats{}}` 83 if got := v.String(); got != want { 84 t.Errorf("AdminStats.String = %v, want %v", got, want) 85 } 86 } 87 88 func TestAdvancedSecurity_String(t *testing.T) { 89 t.Parallel() 90 v := AdvancedSecurity{ 91 Status: Ptr(""), 92 } 93 want := `github.AdvancedSecurity{Status:""}` 94 if got := v.String(); got != want { 95 t.Errorf("AdvancedSecurity.String = %v, want %v", got, want) 96 } 97 } 98 99 func TestAuthorization_String(t *testing.T) { 100 t.Parallel() 101 v := Authorization{ 102 ID: Ptr(int64(0)), 103 URL: Ptr(""), 104 Scopes: []Scope{ScopeNone}, 105 Token: Ptr(""), 106 TokenLastEight: Ptr(""), 107 HashedToken: Ptr(""), 108 App: &AuthorizationApp{}, 109 Note: Ptr(""), 110 NoteURL: Ptr(""), 111 UpdatedAt: &Timestamp{}, 112 CreatedAt: &Timestamp{}, 113 Fingerprint: Ptr(""), 114 User: &User{}, 115 } 116 want := `github.Authorization{ID:0, URL:"", Scopes:["(no scope)"], Token:"", TokenLastEight:"", HashedToken:"", App:github.AuthorizationApp{}, Note:"", NoteURL:"", UpdatedAt:github.Timestamp{0001-01-01 00:00:00 +0000 UTC}, CreatedAt:github.Timestamp{0001-01-01 00:00:00 +0000 UTC}, Fingerprint:"", User:github.User{}}` 117 if got := v.String(); got != want { 118 t.Errorf("Authorization.String = %v, want %v", got, want) 119 } 120 } 121 122 func TestAuthorizationApp_String(t *testing.T) { 123 t.Parallel() 124 v := AuthorizationApp{ 125 URL: Ptr(""), 126 Name: Ptr(""), 127 ClientID: Ptr(""), 128 } 129 want := `github.AuthorizationApp{URL:"", Name:"", ClientID:""}` 130 if got := v.String(); got != want { 131 t.Errorf("AuthorizationApp.String = %v, want %v", got, want) 132 } 133 } 134 135 func TestAuthorizationRequest_String(t *testing.T) { 136 t.Parallel() 137 v := AuthorizationRequest{ 138 Scopes: []Scope{ScopeNone}, 139 Note: Ptr(""), 140 NoteURL: Ptr(""), 141 ClientID: Ptr(""), 142 ClientSecret: Ptr(""), 143 Fingerprint: Ptr(""), 144 } 145 want := `github.AuthorizationRequest{Scopes:["(no scope)"], Note:"", NoteURL:"", ClientID:"", ClientSecret:"", Fingerprint:""}` 146 if got := v.String(); got != want { 147 t.Errorf("AuthorizationRequest.String = %v, want %v", got, want) 148 } 149 } 150 151 func TestAuthorizationUpdateRequest_String(t *testing.T) { 152 t.Parallel() 153 v := AuthorizationUpdateRequest{ 154 Scopes: []string{""}, 155 AddScopes: []string{""}, 156 RemoveScopes: []string{""}, 157 Note: Ptr(""), 158 NoteURL: Ptr(""), 159 Fingerprint: Ptr(""), 160 } 161 want := `github.AuthorizationUpdateRequest{Scopes:[""], AddScopes:[""], RemoveScopes:[""], Note:"", NoteURL:"", Fingerprint:""}` 162 if got := v.String(); got != want { 163 t.Errorf("AuthorizationUpdateRequest.String = %v, want %v", got, want) 164 } 165 } 166 167 func TestCheckRun_String(t *testing.T) { 168 t.Parallel() 169 v := CheckRun{ 170 ID: Ptr(int64(0)), 171 NodeID: Ptr(""), 172 HeadSHA: Ptr(""), 173 ExternalID: Ptr(""), 174 URL: Ptr(""), 175 HTMLURL: Ptr(""), 176 DetailsURL: Ptr(""), 177 Status: Ptr(""), 178 Conclusion: Ptr(""), 179 StartedAt: &Timestamp{}, 180 CompletedAt: &Timestamp{}, 181 Output: &CheckRunOutput{}, 182 Name: Ptr(""), 183 CheckSuite: &CheckSuite{}, 184 App: &App{}, 185 } 186 want := `github.CheckRun{ID:0, NodeID:"", HeadSHA:"", ExternalID:"", URL:"", HTMLURL:"", DetailsURL:"", Status:"", Conclusion:"", StartedAt:github.Timestamp{0001-01-01 00:00:00 +0000 UTC}, CompletedAt:github.Timestamp{0001-01-01 00:00:00 +0000 UTC}, Output:github.CheckRunOutput{}, Name:"", CheckSuite:github.CheckSuite{}, App:github.App{}}` 187 if got := v.String(); got != want { 188 t.Errorf("CheckRun.String = %v, want %v", got, want) 189 } 190 } 191 192 func TestCheckSuite_String(t *testing.T) { 193 t.Parallel() 194 v := CheckSuite{ 195 ID: Ptr(int64(0)), 196 NodeID: Ptr(""), 197 HeadBranch: Ptr(""), 198 HeadSHA: Ptr(""), 199 URL: Ptr(""), 200 BeforeSHA: Ptr(""), 201 AfterSHA: Ptr(""), 202 Status: Ptr(""), 203 Conclusion: Ptr(""), 204 CreatedAt: &Timestamp{}, 205 UpdatedAt: &Timestamp{}, 206 App: &App{}, 207 Repository: &Repository{}, 208 HeadCommit: &Commit{}, 209 LatestCheckRunsCount: Ptr(int64(0)), 210 Rerequestable: Ptr(false), 211 RunsRerequestable: Ptr(false), 212 } 213 want := `github.CheckSuite{ID:0, NodeID:"", HeadBranch:"", HeadSHA:"", URL:"", BeforeSHA:"", AfterSHA:"", Status:"", Conclusion:"", CreatedAt:github.Timestamp{0001-01-01 00:00:00 +0000 UTC}, UpdatedAt:github.Timestamp{0001-01-01 00:00:00 +0000 UTC}, App:github.App{}, Repository:github.Repository{}, HeadCommit:github.Commit{}, LatestCheckRunsCount:0, Rerequestable:false, RunsRerequestable:false}` 214 if got := v.String(); got != want { 215 t.Errorf("CheckSuite.String = %v, want %v", got, want) 216 } 217 } 218 219 func TestCodeOfConduct_String(t *testing.T) { 220 t.Parallel() 221 v := CodeOfConduct{ 222 Name: Ptr(""), 223 Key: Ptr(""), 224 URL: Ptr(""), 225 Body: Ptr(""), 226 } 227 want := `github.CodeOfConduct{Name:"", Key:"", URL:"", Body:""}` 228 if got := v.String(); got != want { 229 t.Errorf("CodeOfConduct.String = %v, want %v", got, want) 230 } 231 } 232 233 func TestCodeResult_String(t *testing.T) { 234 t.Parallel() 235 v := CodeResult{ 236 Name: Ptr(""), 237 Path: Ptr(""), 238 SHA: Ptr(""), 239 HTMLURL: Ptr(""), 240 Repository: &Repository{}, 241 } 242 want := `github.CodeResult{Name:"", Path:"", SHA:"", HTMLURL:"", Repository:github.Repository{}}` 243 if got := v.String(); got != want { 244 t.Errorf("CodeResult.String = %v, want %v", got, want) 245 } 246 } 247 248 func TestCombinedStatus_String(t *testing.T) { 249 t.Parallel() 250 v := CombinedStatus{ 251 State: Ptr(""), 252 Name: Ptr(""), 253 SHA: Ptr(""), 254 TotalCount: Ptr(0), 255 CommitURL: Ptr(""), 256 RepositoryURL: Ptr(""), 257 } 258 want := `github.CombinedStatus{State:"", Name:"", SHA:"", TotalCount:0, CommitURL:"", RepositoryURL:""}` 259 if got := v.String(); got != want { 260 t.Errorf("CombinedStatus.String = %v, want %v", got, want) 261 } 262 } 263 264 func TestCommentStats_String(t *testing.T) { 265 t.Parallel() 266 v := CommentStats{ 267 TotalCommitComments: Ptr(0), 268 TotalGistComments: Ptr(0), 269 TotalIssueComments: Ptr(0), 270 TotalPullRequestComments: Ptr(0), 271 } 272 want := `github.CommentStats{TotalCommitComments:0, TotalGistComments:0, TotalIssueComments:0, TotalPullRequestComments:0}` 273 if got := v.String(); got != want { 274 t.Errorf("CommentStats.String = %v, want %v", got, want) 275 } 276 } 277 278 func TestCommit_String(t *testing.T) { 279 t.Parallel() 280 v := Commit{ 281 SHA: Ptr(""), 282 Author: &CommitAuthor{}, 283 Committer: &CommitAuthor{}, 284 Message: Ptr(""), 285 Tree: &Tree{}, 286 HTMLURL: Ptr(""), 287 URL: Ptr(""), 288 Verification: &SignatureVerification{}, 289 NodeID: Ptr(""), 290 CommentCount: Ptr(0), 291 } 292 want := `github.Commit{SHA:"", Author:github.CommitAuthor{}, Committer:github.CommitAuthor{}, Message:"", Tree:github.Tree{}, HTMLURL:"", URL:"", Verification:github.SignatureVerification{}, NodeID:"", CommentCount:0}` 293 if got := v.String(); got != want { 294 t.Errorf("Commit.String = %v, want %v", got, want) 295 } 296 } 297 298 func TestCommitAuthor_String(t *testing.T) { 299 t.Parallel() 300 v := CommitAuthor{ 301 Date: &Timestamp{}, 302 Name: Ptr(""), 303 Email: Ptr(""), 304 Login: Ptr(""), 305 } 306 want := `github.CommitAuthor{Date:github.Timestamp{0001-01-01 00:00:00 +0000 UTC}, Name:"", Email:"", Login:""}` 307 if got := v.String(); got != want { 308 t.Errorf("CommitAuthor.String = %v, want %v", got, want) 309 } 310 } 311 312 func TestCommitFile_String(t *testing.T) { 313 t.Parallel() 314 v := CommitFile{ 315 SHA: Ptr(""), 316 Filename: Ptr(""), 317 Additions: Ptr(0), 318 Deletions: Ptr(0), 319 Changes: Ptr(0), 320 Status: Ptr(""), 321 Patch: Ptr(""), 322 BlobURL: Ptr(""), 323 RawURL: Ptr(""), 324 ContentsURL: Ptr(""), 325 PreviousFilename: Ptr(""), 326 } 327 want := `github.CommitFile{SHA:"", Filename:"", Additions:0, Deletions:0, Changes:0, Status:"", Patch:"", BlobURL:"", RawURL:"", ContentsURL:"", PreviousFilename:""}` 328 if got := v.String(); got != want { 329 t.Errorf("CommitFile.String = %v, want %v", got, want) 330 } 331 } 332 333 func TestCommitStats_String(t *testing.T) { 334 t.Parallel() 335 v := CommitStats{ 336 Additions: Ptr(0), 337 Deletions: Ptr(0), 338 Total: Ptr(0), 339 } 340 want := `github.CommitStats{Additions:0, Deletions:0, Total:0}` 341 if got := v.String(); got != want { 342 t.Errorf("CommitStats.String = %v, want %v", got, want) 343 } 344 } 345 346 func TestCommitsComparison_String(t *testing.T) { 347 t.Parallel() 348 v := CommitsComparison{ 349 BaseCommit: &RepositoryCommit{}, 350 MergeBaseCommit: &RepositoryCommit{}, 351 Status: Ptr(""), 352 AheadBy: Ptr(0), 353 BehindBy: Ptr(0), 354 TotalCommits: Ptr(0), 355 HTMLURL: Ptr(""), 356 PermalinkURL: Ptr(""), 357 DiffURL: Ptr(""), 358 PatchURL: Ptr(""), 359 URL: Ptr(""), 360 } 361 want := `github.CommitsComparison{BaseCommit:github.RepositoryCommit{}, MergeBaseCommit:github.RepositoryCommit{}, Status:"", AheadBy:0, BehindBy:0, TotalCommits:0, HTMLURL:"", PermalinkURL:"", DiffURL:"", PatchURL:"", URL:""}` 362 if got := v.String(); got != want { 363 t.Errorf("CommitsComparison.String = %v, want %v", got, want) 364 } 365 } 366 367 func TestContributorStats_String(t *testing.T) { 368 t.Parallel() 369 v := ContributorStats{ 370 Author: &Contributor{}, 371 Total: Ptr(0), 372 } 373 want := `github.ContributorStats{Author:github.Contributor{}, Total:0}` 374 if got := v.String(); got != want { 375 t.Errorf("ContributorStats.String = %v, want %v", got, want) 376 } 377 } 378 379 func TestDependabotSecurityUpdates_String(t *testing.T) { 380 t.Parallel() 381 v := DependabotSecurityUpdates{ 382 Status: Ptr(""), 383 } 384 want := `github.DependabotSecurityUpdates{Status:""}` 385 if got := v.String(); got != want { 386 t.Errorf("DependabotSecurityUpdates.String = %v, want %v", got, want) 387 } 388 } 389 390 func TestDiscussionComment_String(t *testing.T) { 391 t.Parallel() 392 v := DiscussionComment{ 393 Author: &User{}, 394 Body: Ptr(""), 395 BodyHTML: Ptr(""), 396 BodyVersion: Ptr(""), 397 CreatedAt: &Timestamp{}, 398 LastEditedAt: &Timestamp{}, 399 DiscussionURL: Ptr(""), 400 HTMLURL: Ptr(""), 401 NodeID: Ptr(""), 402 Number: Ptr(0), 403 UpdatedAt: &Timestamp{}, 404 URL: Ptr(""), 405 Reactions: &Reactions{}, 406 } 407 want := `github.DiscussionComment{Author:github.User{}, Body:"", BodyHTML:"", BodyVersion:"", CreatedAt:github.Timestamp{0001-01-01 00:00:00 +0000 UTC}, LastEditedAt:github.Timestamp{0001-01-01 00:00:00 +0000 UTC}, DiscussionURL:"", HTMLURL:"", NodeID:"", Number:0, UpdatedAt:github.Timestamp{0001-01-01 00:00:00 +0000 UTC}, URL:"", Reactions:github.Reactions{}}` 408 if got := v.String(); got != want { 409 t.Errorf("DiscussionComment.String = %v, want %v", got, want) 410 } 411 } 412 413 func TestDraftReviewComment_String(t *testing.T) { 414 t.Parallel() 415 v := DraftReviewComment{ 416 Path: Ptr(""), 417 Position: Ptr(0), 418 Body: Ptr(""), 419 StartSide: Ptr(""), 420 Side: Ptr(""), 421 StartLine: Ptr(0), 422 Line: Ptr(0), 423 } 424 want := `github.DraftReviewComment{Path:"", Position:0, Body:"", StartSide:"", Side:"", StartLine:0, Line:0}` 425 if got := v.String(); got != want { 426 t.Errorf("DraftReviewComment.String = %v, want %v", got, want) 427 } 428 } 429 430 func TestEnterprise_String(t *testing.T) { 431 t.Parallel() 432 v := Enterprise{ 433 ID: Ptr(0), 434 Slug: Ptr(""), 435 Name: Ptr(""), 436 NodeID: Ptr(""), 437 AvatarURL: Ptr(""), 438 Description: Ptr(""), 439 WebsiteURL: Ptr(""), 440 HTMLURL: Ptr(""), 441 CreatedAt: &Timestamp{}, 442 UpdatedAt: &Timestamp{}, 443 } 444 want := `github.Enterprise{ID:0, Slug:"", Name:"", NodeID:"", AvatarURL:"", Description:"", WebsiteURL:"", HTMLURL:"", CreatedAt:github.Timestamp{0001-01-01 00:00:00 +0000 UTC}, UpdatedAt:github.Timestamp{0001-01-01 00:00:00 +0000 UTC}}` 445 if got := v.String(); got != want { 446 t.Errorf("Enterprise.String = %v, want %v", got, want) 447 } 448 } 449 450 func TestEvent_String(t *testing.T) { 451 t.Parallel() 452 v := Event{ 453 Type: Ptr(""), 454 Public: Ptr(false), 455 Repo: &Repository{}, 456 Actor: &User{}, 457 Org: &Organization{}, 458 CreatedAt: &Timestamp{}, 459 ID: Ptr(""), 460 } 461 want := `github.Event{Type:"", Public:false, Repo:github.Repository{}, Actor:github.User{}, Org:github.Organization{}, CreatedAt:github.Timestamp{0001-01-01 00:00:00 +0000 UTC}, ID:""}` 462 if got := v.String(); got != want { 463 t.Errorf("Event.String = %v, want %v", got, want) 464 } 465 } 466 467 func TestGPGKey_String(t *testing.T) { 468 t.Parallel() 469 v := GPGKey{ 470 ID: Ptr(int64(0)), 471 PrimaryKeyID: Ptr(int64(0)), 472 KeyID: Ptr(""), 473 RawKey: Ptr(""), 474 PublicKey: Ptr(""), 475 CanSign: Ptr(false), 476 CanEncryptComms: Ptr(false), 477 CanEncryptStorage: Ptr(false), 478 CanCertify: Ptr(false), 479 CreatedAt: &Timestamp{}, 480 ExpiresAt: &Timestamp{}, 481 } 482 want := `github.GPGKey{ID:0, PrimaryKeyID:0, KeyID:"", RawKey:"", PublicKey:"", CanSign:false, CanEncryptComms:false, CanEncryptStorage:false, CanCertify:false, CreatedAt:github.Timestamp{0001-01-01 00:00:00 +0000 UTC}, ExpiresAt:github.Timestamp{0001-01-01 00:00:00 +0000 UTC}}` 483 if got := v.String(); got != want { 484 t.Errorf("GPGKey.String = %v, want %v", got, want) 485 } 486 } 487 488 func TestGist_String(t *testing.T) { 489 t.Parallel() 490 v := Gist{ 491 ID: Ptr(""), 492 Description: Ptr(""), 493 Public: Ptr(false), 494 Owner: &User{}, 495 Comments: Ptr(0), 496 HTMLURL: Ptr(""), 497 GitPullURL: Ptr(""), 498 GitPushURL: Ptr(""), 499 CreatedAt: &Timestamp{}, 500 UpdatedAt: &Timestamp{}, 501 NodeID: Ptr(""), 502 } 503 want := `github.Gist{ID:"", Description:"", Public:false, Owner:github.User{}, Comments:0, HTMLURL:"", GitPullURL:"", GitPushURL:"", CreatedAt:github.Timestamp{0001-01-01 00:00:00 +0000 UTC}, UpdatedAt:github.Timestamp{0001-01-01 00:00:00 +0000 UTC}, NodeID:""}` 504 if got := v.String(); got != want { 505 t.Errorf("Gist.String = %v, want %v", got, want) 506 } 507 } 508 509 func TestGistComment_String(t *testing.T) { 510 t.Parallel() 511 v := GistComment{ 512 ID: Ptr(int64(0)), 513 URL: Ptr(""), 514 Body: Ptr(""), 515 User: &User{}, 516 CreatedAt: &Timestamp{}, 517 } 518 want := `github.GistComment{ID:0, URL:"", Body:"", User:github.User{}, CreatedAt:github.Timestamp{0001-01-01 00:00:00 +0000 UTC}}` 519 if got := v.String(); got != want { 520 t.Errorf("GistComment.String = %v, want %v", got, want) 521 } 522 } 523 524 func TestGistCommit_String(t *testing.T) { 525 t.Parallel() 526 v := GistCommit{ 527 URL: Ptr(""), 528 Version: Ptr(""), 529 User: &User{}, 530 ChangeStatus: &CommitStats{}, 531 CommittedAt: &Timestamp{}, 532 NodeID: Ptr(""), 533 } 534 want := `github.GistCommit{URL:"", Version:"", User:github.User{}, ChangeStatus:github.CommitStats{}, CommittedAt:github.Timestamp{0001-01-01 00:00:00 +0000 UTC}, NodeID:""}` 535 if got := v.String(); got != want { 536 t.Errorf("GistCommit.String = %v, want %v", got, want) 537 } 538 } 539 540 func TestGistFile_String(t *testing.T) { 541 t.Parallel() 542 v := GistFile{ 543 Size: Ptr(0), 544 Filename: Ptr(""), 545 Language: Ptr(""), 546 Type: Ptr(""), 547 RawURL: Ptr(""), 548 Content: Ptr(""), 549 } 550 want := `github.GistFile{Size:0, Filename:"", Language:"", Type:"", RawURL:"", Content:""}` 551 if got := v.String(); got != want { 552 t.Errorf("GistFile.String = %v, want %v", got, want) 553 } 554 } 555 556 func TestGistFork_String(t *testing.T) { 557 t.Parallel() 558 v := GistFork{ 559 URL: Ptr(""), 560 User: &User{}, 561 ID: Ptr(""), 562 CreatedAt: &Timestamp{}, 563 UpdatedAt: &Timestamp{}, 564 NodeID: Ptr(""), 565 } 566 want := `github.GistFork{URL:"", User:github.User{}, ID:"", CreatedAt:github.Timestamp{0001-01-01 00:00:00 +0000 UTC}, UpdatedAt:github.Timestamp{0001-01-01 00:00:00 +0000 UTC}, NodeID:""}` 567 if got := v.String(); got != want { 568 t.Errorf("GistFork.String = %v, want %v", got, want) 569 } 570 } 571 572 func TestGistStats_String(t *testing.T) { 573 t.Parallel() 574 v := GistStats{ 575 TotalGists: Ptr(0), 576 PrivateGists: Ptr(0), 577 PublicGists: Ptr(0), 578 } 579 want := `github.GistStats{TotalGists:0, PrivateGists:0, PublicGists:0}` 580 if got := v.String(); got != want { 581 t.Errorf("GistStats.String = %v, want %v", got, want) 582 } 583 } 584 585 func TestGitObject_String(t *testing.T) { 586 t.Parallel() 587 v := GitObject{ 588 Type: Ptr(""), 589 SHA: Ptr(""), 590 URL: Ptr(""), 591 } 592 want := `github.GitObject{Type:"", SHA:"", URL:""}` 593 if got := v.String(); got != want { 594 t.Errorf("GitObject.String = %v, want %v", got, want) 595 } 596 } 597 598 func TestGitignore_String(t *testing.T) { 599 t.Parallel() 600 v := Gitignore{ 601 Name: Ptr(""), 602 Source: Ptr(""), 603 } 604 want := `github.Gitignore{Name:"", Source:""}` 605 if got := v.String(); got != want { 606 t.Errorf("Gitignore.String = %v, want %v", got, want) 607 } 608 } 609 610 func TestGrant_String(t *testing.T) { 611 t.Parallel() 612 v := Grant{ 613 ID: Ptr(int64(0)), 614 URL: Ptr(""), 615 App: &AuthorizationApp{}, 616 CreatedAt: &Timestamp{}, 617 UpdatedAt: &Timestamp{}, 618 Scopes: []string{""}, 619 } 620 want := `github.Grant{ID:0, URL:"", App:github.AuthorizationApp{}, CreatedAt:github.Timestamp{0001-01-01 00:00:00 +0000 UTC}, UpdatedAt:github.Timestamp{0001-01-01 00:00:00 +0000 UTC}, Scopes:[""]}` 621 if got := v.String(); got != want { 622 t.Errorf("Grant.String = %v, want %v", got, want) 623 } 624 } 625 626 func TestHeadCommit_String(t *testing.T) { 627 t.Parallel() 628 v := HeadCommit{ 629 Message: Ptr(""), 630 Author: &CommitAuthor{}, 631 URL: Ptr(""), 632 Distinct: Ptr(false), 633 SHA: Ptr(""), 634 ID: Ptr(""), 635 TreeID: Ptr(""), 636 Timestamp: &Timestamp{}, 637 Committer: &CommitAuthor{}, 638 Added: []string{""}, 639 Removed: []string{""}, 640 Modified: []string{""}, 641 } 642 want := `github.HeadCommit{Message:"", Author:github.CommitAuthor{}, URL:"", Distinct:false, SHA:"", ID:"", TreeID:"", Timestamp:github.Timestamp{0001-01-01 00:00:00 +0000 UTC}, Committer:github.CommitAuthor{}, Added:[""], Removed:[""], Modified:[""]}` 643 if got := v.String(); got != want { 644 t.Errorf("HeadCommit.String = %v, want %v", got, want) 645 } 646 } 647 648 func TestHook_String(t *testing.T) { 649 t.Parallel() 650 v := Hook{ 651 CreatedAt: &Timestamp{}, 652 UpdatedAt: &Timestamp{}, 653 URL: Ptr(""), 654 ID: Ptr(int64(0)), 655 Type: Ptr(""), 656 Name: Ptr(""), 657 TestURL: Ptr(""), 658 PingURL: Ptr(""), 659 Config: &HookConfig{}, 660 Events: []string{""}, 661 Active: Ptr(false), 662 } 663 want := `github.Hook{CreatedAt:github.Timestamp{0001-01-01 00:00:00 +0000 UTC}, UpdatedAt:github.Timestamp{0001-01-01 00:00:00 +0000 UTC}, URL:"", ID:0, Type:"", Name:"", TestURL:"", PingURL:"", Config:github.HookConfig{}, Events:[""], Active:false}` 664 if got := v.String(); got != want { 665 t.Errorf("Hook.String = %v, want %v", got, want) 666 } 667 } 668 669 func TestHookDelivery_String(t *testing.T) { 670 t.Parallel() 671 v := HookDelivery{ 672 ID: Ptr(int64(0)), 673 GUID: Ptr(""), 674 DeliveredAt: &Timestamp{}, 675 Redelivery: Ptr(false), 676 Duration: Ptr(0.0), 677 Status: Ptr(""), 678 StatusCode: Ptr(0), 679 Event: Ptr(""), 680 Action: Ptr(""), 681 InstallationID: Ptr(int64(0)), 682 RepositoryID: Ptr(int64(0)), 683 Request: &HookRequest{}, 684 Response: &HookResponse{}, 685 } 686 want := `github.HookDelivery{ID:0, GUID:"", DeliveredAt:github.Timestamp{0001-01-01 00:00:00 +0000 UTC}, Redelivery:false, Duration:0, Status:"", StatusCode:0, Event:"", Action:"", InstallationID:0, RepositoryID:0, Request:github.HookRequest{}, Response:github.HookResponse{}}` 687 if got := v.String(); got != want { 688 t.Errorf("HookDelivery.String = %v, want %v", got, want) 689 } 690 } 691 692 func TestHookStats_String(t *testing.T) { 693 t.Parallel() 694 v := HookStats{ 695 TotalHooks: Ptr(0), 696 ActiveHooks: Ptr(0), 697 InactiveHooks: Ptr(0), 698 } 699 want := `github.HookStats{TotalHooks:0, ActiveHooks:0, InactiveHooks:0}` 700 if got := v.String(); got != want { 701 t.Errorf("HookStats.String = %v, want %v", got, want) 702 } 703 } 704 705 func TestImport_String(t *testing.T) { 706 t.Parallel() 707 v := Import{ 708 VCSURL: Ptr(""), 709 VCS: Ptr(""), 710 VCSUsername: Ptr(""), 711 VCSPassword: Ptr(""), 712 TFVCProject: Ptr(""), 713 UseLFS: Ptr(""), 714 HasLargeFiles: Ptr(false), 715 LargeFilesSize: Ptr(0), 716 LargeFilesCount: Ptr(0), 717 Status: Ptr(""), 718 CommitCount: Ptr(0), 719 StatusText: Ptr(""), 720 AuthorsCount: Ptr(0), 721 Percent: Ptr(0), 722 PushPercent: Ptr(0), 723 URL: Ptr(""), 724 HTMLURL: Ptr(""), 725 AuthorsURL: Ptr(""), 726 RepositoryURL: Ptr(""), 727 Message: Ptr(""), 728 FailedStep: Ptr(""), 729 HumanName: Ptr(""), 730 } 731 want := `github.Import{VCSURL:"", VCS:"", VCSUsername:"", VCSPassword:"", TFVCProject:"", UseLFS:"", HasLargeFiles:false, LargeFilesSize:0, LargeFilesCount:0, Status:"", CommitCount:0, StatusText:"", AuthorsCount:0, Percent:0, PushPercent:0, URL:"", HTMLURL:"", AuthorsURL:"", RepositoryURL:"", Message:"", FailedStep:"", HumanName:""}` 732 if got := v.String(); got != want { 733 t.Errorf("Import.String = %v, want %v", got, want) 734 } 735 } 736 737 func TestInstallation_String(t *testing.T) { 738 t.Parallel() 739 v := Installation{ 740 ID: Ptr(int64(0)), 741 NodeID: Ptr(""), 742 AppID: Ptr(int64(0)), 743 AppSlug: Ptr(""), 744 TargetID: Ptr(int64(0)), 745 Account: &User{}, 746 AccessTokensURL: Ptr(""), 747 RepositoriesURL: Ptr(""), 748 HTMLURL: Ptr(""), 749 TargetType: Ptr(""), 750 SingleFileName: Ptr(""), 751 RepositorySelection: Ptr(""), 752 Events: []string{""}, 753 SingleFilePaths: []string{""}, 754 Permissions: &InstallationPermissions{}, 755 CreatedAt: &Timestamp{}, 756 UpdatedAt: &Timestamp{}, 757 HasMultipleSingleFiles: Ptr(false), 758 SuspendedBy: &User{}, 759 SuspendedAt: &Timestamp{}, 760 } 761 want := `github.Installation{ID:0, NodeID:"", AppID:0, AppSlug:"", TargetID:0, Account:github.User{}, AccessTokensURL:"", RepositoriesURL:"", HTMLURL:"", TargetType:"", SingleFileName:"", RepositorySelection:"", Events:[""], SingleFilePaths:[""], Permissions:github.InstallationPermissions{}, CreatedAt:github.Timestamp{0001-01-01 00:00:00 +0000 UTC}, UpdatedAt:github.Timestamp{0001-01-01 00:00:00 +0000 UTC}, HasMultipleSingleFiles:false, SuspendedBy:github.User{}, SuspendedAt:github.Timestamp{0001-01-01 00:00:00 +0000 UTC}}` 762 if got := v.String(); got != want { 763 t.Errorf("Installation.String = %v, want %v", got, want) 764 } 765 } 766 767 func TestInvitation_String(t *testing.T) { 768 t.Parallel() 769 v := Invitation{ 770 ID: Ptr(int64(0)), 771 NodeID: Ptr(""), 772 Login: Ptr(""), 773 Email: Ptr(""), 774 Role: Ptr(""), 775 CreatedAt: &Timestamp{}, 776 Inviter: &User{}, 777 TeamCount: Ptr(0), 778 InvitationTeamURL: Ptr(""), 779 FailedAt: &Timestamp{}, 780 FailedReason: Ptr(""), 781 } 782 want := `github.Invitation{ID:0, NodeID:"", Login:"", Email:"", Role:"", CreatedAt:github.Timestamp{0001-01-01 00:00:00 +0000 UTC}, Inviter:github.User{}, TeamCount:0, InvitationTeamURL:"", FailedAt:github.Timestamp{0001-01-01 00:00:00 +0000 UTC}, FailedReason:""}` 783 if got := v.String(); got != want { 784 t.Errorf("Invitation.String = %v, want %v", got, want) 785 } 786 } 787 788 func TestIssue_String(t *testing.T) { 789 t.Parallel() 790 v := Issue{ 791 ID: Ptr(int64(0)), 792 Number: Ptr(0), 793 State: Ptr(""), 794 StateReason: Ptr(""), 795 Locked: Ptr(false), 796 Title: Ptr(""), 797 Body: Ptr(""), 798 AuthorAssociation: Ptr(""), 799 User: &User{}, 800 Assignee: &User{}, 801 Comments: Ptr(0), 802 ClosedAt: &Timestamp{}, 803 CreatedAt: &Timestamp{}, 804 UpdatedAt: &Timestamp{}, 805 ClosedBy: &User{}, 806 URL: Ptr(""), 807 HTMLURL: Ptr(""), 808 CommentsURL: Ptr(""), 809 EventsURL: Ptr(""), 810 LabelsURL: Ptr(""), 811 RepositoryURL: Ptr(""), 812 Milestone: &Milestone{}, 813 PullRequestLinks: &PullRequestLinks{}, 814 Repository: &Repository{}, 815 Reactions: &Reactions{}, 816 NodeID: Ptr(""), 817 Draft: Ptr(false), 818 Type: &IssueType{}, 819 ActiveLockReason: Ptr(""), 820 } 821 want := `github.Issue{ID:0, Number:0, State:"", StateReason:"", Locked:false, Title:"", Body:"", AuthorAssociation:"", User:github.User{}, Assignee:github.User{}, Comments:0, ClosedAt:github.Timestamp{0001-01-01 00:00:00 +0000 UTC}, CreatedAt:github.Timestamp{0001-01-01 00:00:00 +0000 UTC}, UpdatedAt:github.Timestamp{0001-01-01 00:00:00 +0000 UTC}, ClosedBy:github.User{}, URL:"", HTMLURL:"", CommentsURL:"", EventsURL:"", LabelsURL:"", RepositoryURL:"", Milestone:github.Milestone{}, PullRequestLinks:github.PullRequestLinks{}, Repository:github.Repository{}, Reactions:github.Reactions{}, NodeID:"", Draft:false, Type:github.IssueType{}, ActiveLockReason:""}` 822 if got := v.String(); got != want { 823 t.Errorf("Issue.String = %v, want %v", got, want) 824 } 825 } 826 827 func TestIssueComment_String(t *testing.T) { 828 t.Parallel() 829 v := IssueComment{ 830 ID: Ptr(int64(0)), 831 NodeID: Ptr(""), 832 Body: Ptr(""), 833 User: &User{}, 834 Reactions: &Reactions{}, 835 CreatedAt: &Timestamp{}, 836 UpdatedAt: &Timestamp{}, 837 AuthorAssociation: Ptr(""), 838 URL: Ptr(""), 839 HTMLURL: Ptr(""), 840 IssueURL: Ptr(""), 841 } 842 want := `github.IssueComment{ID:0, NodeID:"", Body:"", User:github.User{}, Reactions:github.Reactions{}, CreatedAt:github.Timestamp{0001-01-01 00:00:00 +0000 UTC}, UpdatedAt:github.Timestamp{0001-01-01 00:00:00 +0000 UTC}, AuthorAssociation:"", URL:"", HTMLURL:"", IssueURL:""}` 843 if got := v.String(); got != want { 844 t.Errorf("IssueComment.String = %v, want %v", got, want) 845 } 846 } 847 848 func TestIssueStats_String(t *testing.T) { 849 t.Parallel() 850 v := IssueStats{ 851 TotalIssues: Ptr(0), 852 OpenIssues: Ptr(0), 853 ClosedIssues: Ptr(0), 854 } 855 want := `github.IssueStats{TotalIssues:0, OpenIssues:0, ClosedIssues:0}` 856 if got := v.String(); got != want { 857 t.Errorf("IssueStats.String = %v, want %v", got, want) 858 } 859 } 860 861 func TestKey_String(t *testing.T) { 862 t.Parallel() 863 v := Key{ 864 ID: Ptr(int64(0)), 865 Key: Ptr(""), 866 URL: Ptr(""), 867 Title: Ptr(""), 868 ReadOnly: Ptr(false), 869 Verified: Ptr(false), 870 CreatedAt: &Timestamp{}, 871 AddedBy: Ptr(""), 872 LastUsed: &Timestamp{}, 873 } 874 want := `github.Key{ID:0, Key:"", URL:"", Title:"", ReadOnly:false, Verified:false, CreatedAt:github.Timestamp{0001-01-01 00:00:00 +0000 UTC}, AddedBy:"", LastUsed:github.Timestamp{0001-01-01 00:00:00 +0000 UTC}}` 875 if got := v.String(); got != want { 876 t.Errorf("Key.String = %v, want %v", got, want) 877 } 878 } 879 880 func TestLabel_String(t *testing.T) { 881 t.Parallel() 882 v := Label{ 883 ID: Ptr(int64(0)), 884 URL: Ptr(""), 885 Name: Ptr(""), 886 Color: Ptr(""), 887 Description: Ptr(""), 888 Default: Ptr(false), 889 NodeID: Ptr(""), 890 } 891 want := `github.Label{ID:0, URL:"", Name:"", Color:"", Description:"", Default:false, NodeID:""}` 892 if got := v.String(); got != want { 893 t.Errorf("Label.String = %v, want %v", got, want) 894 } 895 } 896 897 func TestLabelResult_String(t *testing.T) { 898 t.Parallel() 899 v := LabelResult{ 900 ID: Ptr(int64(0)), 901 URL: Ptr(""), 902 Name: Ptr(""), 903 Color: Ptr(""), 904 Default: Ptr(false), 905 Description: Ptr(""), 906 Score: Ptr(0.0), 907 } 908 want := `github.LabelResult{ID:0, URL:"", Name:"", Color:"", Default:false, Description:"", Score:0}` 909 if got := v.String(); got != want { 910 t.Errorf("LabelResult.String = %v, want %v", got, want) 911 } 912 } 913 914 func TestLargeFile_String(t *testing.T) { 915 t.Parallel() 916 v := LargeFile{ 917 RefName: Ptr(""), 918 Path: Ptr(""), 919 OID: Ptr(""), 920 Size: Ptr(0), 921 } 922 want := `github.LargeFile{RefName:"", Path:"", OID:"", Size:0}` 923 if got := v.String(); got != want { 924 t.Errorf("LargeFile.String = %v, want %v", got, want) 925 } 926 } 927 928 func TestLicense_String(t *testing.T) { 929 t.Parallel() 930 v := License{ 931 Key: Ptr(""), 932 Name: Ptr(""), 933 URL: Ptr(""), 934 SPDXID: Ptr(""), 935 HTMLURL: Ptr(""), 936 Featured: Ptr(false), 937 Description: Ptr(""), 938 Implementation: Ptr(""), 939 Body: Ptr(""), 940 } 941 want := `github.License{Key:"", Name:"", URL:"", SPDXID:"", HTMLURL:"", Featured:false, Description:"", Implementation:"", Body:""}` 942 if got := v.String(); got != want { 943 t.Errorf("License.String = %v, want %v", got, want) 944 } 945 } 946 947 func TestMembership_String(t *testing.T) { 948 t.Parallel() 949 v := Membership{ 950 URL: Ptr(""), 951 State: Ptr(""), 952 Role: Ptr(""), 953 OrganizationURL: Ptr(""), 954 Organization: &Organization{}, 955 User: &User{}, 956 } 957 want := `github.Membership{URL:"", State:"", Role:"", OrganizationURL:"", Organization:github.Organization{}, User:github.User{}}` 958 if got := v.String(); got != want { 959 t.Errorf("Membership.String = %v, want %v", got, want) 960 } 961 } 962 963 func TestMigration_String(t *testing.T) { 964 t.Parallel() 965 v := Migration{ 966 ID: Ptr(int64(0)), 967 GUID: Ptr(""), 968 State: Ptr(""), 969 LockRepositories: Ptr(false), 970 ExcludeAttachments: Ptr(false), 971 URL: Ptr(""), 972 CreatedAt: Ptr(""), 973 UpdatedAt: Ptr(""), 974 } 975 want := `github.Migration{ID:0, GUID:"", State:"", LockRepositories:false, ExcludeAttachments:false, URL:"", CreatedAt:"", UpdatedAt:""}` 976 if got := v.String(); got != want { 977 t.Errorf("Migration.String = %v, want %v", got, want) 978 } 979 } 980 981 func TestMilestone_String(t *testing.T) { 982 t.Parallel() 983 v := Milestone{ 984 URL: Ptr(""), 985 HTMLURL: Ptr(""), 986 LabelsURL: Ptr(""), 987 ID: Ptr(int64(0)), 988 Number: Ptr(0), 989 State: Ptr(""), 990 Title: Ptr(""), 991 Description: Ptr(""), 992 Creator: &User{}, 993 OpenIssues: Ptr(0), 994 ClosedIssues: Ptr(0), 995 CreatedAt: &Timestamp{}, 996 UpdatedAt: &Timestamp{}, 997 ClosedAt: &Timestamp{}, 998 DueOn: &Timestamp{}, 999 NodeID: Ptr(""), 1000 } 1001 want := `github.Milestone{URL:"", HTMLURL:"", LabelsURL:"", ID:0, Number:0, State:"", Title:"", Description:"", Creator:github.User{}, OpenIssues:0, ClosedIssues:0, CreatedAt:github.Timestamp{0001-01-01 00:00:00 +0000 UTC}, UpdatedAt:github.Timestamp{0001-01-01 00:00:00 +0000 UTC}, ClosedAt:github.Timestamp{0001-01-01 00:00:00 +0000 UTC}, DueOn:github.Timestamp{0001-01-01 00:00:00 +0000 UTC}, NodeID:""}` 1002 if got := v.String(); got != want { 1003 t.Errorf("Milestone.String = %v, want %v", got, want) 1004 } 1005 } 1006 1007 func TestMilestoneStats_String(t *testing.T) { 1008 t.Parallel() 1009 v := MilestoneStats{ 1010 TotalMilestones: Ptr(0), 1011 OpenMilestones: Ptr(0), 1012 ClosedMilestones: Ptr(0), 1013 } 1014 want := `github.MilestoneStats{TotalMilestones:0, OpenMilestones:0, ClosedMilestones:0}` 1015 if got := v.String(); got != want { 1016 t.Errorf("MilestoneStats.String = %v, want %v", got, want) 1017 } 1018 } 1019 1020 func TestNewTeam_String(t *testing.T) { 1021 t.Parallel() 1022 v := NewTeam{ 1023 Name: "", 1024 Description: Ptr(""), 1025 Maintainers: []string{""}, 1026 RepoNames: []string{""}, 1027 ParentTeamID: Ptr(int64(0)), 1028 NotificationSetting: Ptr(""), 1029 Permission: Ptr(""), 1030 Privacy: Ptr(""), 1031 LDAPDN: Ptr(""), 1032 } 1033 want := `github.NewTeam{Name:"", Description:"", Maintainers:[""], RepoNames:[""], ParentTeamID:0, NotificationSetting:"", Permission:"", Privacy:"", LDAPDN:""}` 1034 if got := v.String(); got != want { 1035 t.Errorf("NewTeam.String = %v, want %v", got, want) 1036 } 1037 } 1038 1039 func TestOAuthAPP_String(t *testing.T) { 1040 t.Parallel() 1041 v := OAuthAPP{ 1042 URL: Ptr(""), 1043 Name: Ptr(""), 1044 ClientID: Ptr(""), 1045 } 1046 want := `github.OAuthAPP{URL:"", Name:"", ClientID:""}` 1047 if got := v.String(); got != want { 1048 t.Errorf("OAuthAPP.String = %v, want %v", got, want) 1049 } 1050 } 1051 1052 func TestOrgStats_String(t *testing.T) { 1053 t.Parallel() 1054 v := OrgStats{ 1055 TotalOrgs: Ptr(0), 1056 DisabledOrgs: Ptr(0), 1057 TotalTeams: Ptr(0), 1058 TotalTeamMembers: Ptr(0), 1059 } 1060 want := `github.OrgStats{TotalOrgs:0, DisabledOrgs:0, TotalTeams:0, TotalTeamMembers:0}` 1061 if got := v.String(); got != want { 1062 t.Errorf("OrgStats.String = %v, want %v", got, want) 1063 } 1064 } 1065 1066 func TestOrganization_String(t *testing.T) { 1067 t.Parallel() 1068 v := Organization{ 1069 Login: Ptr(""), 1070 ID: Ptr(int64(0)), 1071 NodeID: Ptr(""), 1072 AvatarURL: Ptr(""), 1073 HTMLURL: Ptr(""), 1074 Name: Ptr(""), 1075 Company: Ptr(""), 1076 Blog: Ptr(""), 1077 Location: Ptr(""), 1078 Email: Ptr(""), 1079 TwitterUsername: Ptr(""), 1080 Description: Ptr(""), 1081 PublicRepos: Ptr(0), 1082 PublicGists: Ptr(0), 1083 Followers: Ptr(0), 1084 Following: Ptr(0), 1085 CreatedAt: &Timestamp{}, 1086 UpdatedAt: &Timestamp{}, 1087 TotalPrivateRepos: Ptr(int64(0)), 1088 OwnedPrivateRepos: Ptr(int64(0)), 1089 PrivateGists: Ptr(0), 1090 DiskUsage: Ptr(0), 1091 Collaborators: Ptr(0), 1092 BillingEmail: Ptr(""), 1093 Type: Ptr(""), 1094 Plan: &Plan{}, 1095 TwoFactorRequirementEnabled: Ptr(false), 1096 IsVerified: Ptr(false), 1097 HasOrganizationProjects: Ptr(false), 1098 HasRepositoryProjects: Ptr(false), 1099 DefaultRepoPermission: Ptr(""), 1100 DefaultRepoSettings: Ptr(""), 1101 MembersCanCreateRepos: Ptr(false), 1102 MembersCanCreatePublicRepos: Ptr(false), 1103 MembersCanCreatePrivateRepos: Ptr(false), 1104 MembersCanCreateInternalRepos: Ptr(false), 1105 MembersCanForkPrivateRepos: Ptr(false), 1106 MembersAllowedRepositoryCreationType: Ptr(""), 1107 MembersCanCreatePages: Ptr(false), 1108 MembersCanCreatePublicPages: Ptr(false), 1109 MembersCanCreatePrivatePages: Ptr(false), 1110 WebCommitSignoffRequired: Ptr(false), 1111 AdvancedSecurityEnabledForNewRepos: Ptr(false), 1112 DependabotAlertsEnabledForNewRepos: Ptr(false), 1113 DependabotSecurityUpdatesEnabledForNewRepos: Ptr(false), 1114 DependencyGraphEnabledForNewRepos: Ptr(false), 1115 SecretScanningEnabledForNewRepos: Ptr(false), 1116 SecretScanningPushProtectionEnabledForNewRepos: Ptr(false), 1117 SecretScanningValidityChecksEnabled: Ptr(false), 1118 URL: Ptr(""), 1119 EventsURL: Ptr(""), 1120 HooksURL: Ptr(""), 1121 IssuesURL: Ptr(""), 1122 MembersURL: Ptr(""), 1123 PublicMembersURL: Ptr(""), 1124 ReposURL: Ptr(""), 1125 } 1126 want := `github.Organization{Login:"", ID:0, NodeID:"", AvatarURL:"", HTMLURL:"", Name:"", Company:"", Blog:"", Location:"", Email:"", TwitterUsername:"", Description:"", PublicRepos:0, PublicGists:0, Followers:0, Following:0, CreatedAt:github.Timestamp{0001-01-01 00:00:00 +0000 UTC}, UpdatedAt:github.Timestamp{0001-01-01 00:00:00 +0000 UTC}, TotalPrivateRepos:0, OwnedPrivateRepos:0, PrivateGists:0, DiskUsage:0, Collaborators:0, BillingEmail:"", Type:"", Plan:github.Plan{}, TwoFactorRequirementEnabled:false, IsVerified:false, HasOrganizationProjects:false, HasRepositoryProjects:false, DefaultRepoPermission:"", DefaultRepoSettings:"", MembersCanCreateRepos:false, MembersCanCreatePublicRepos:false, MembersCanCreatePrivateRepos:false, MembersCanCreateInternalRepos:false, MembersCanForkPrivateRepos:false, MembersAllowedRepositoryCreationType:"", MembersCanCreatePages:false, MembersCanCreatePublicPages:false, MembersCanCreatePrivatePages:false, WebCommitSignoffRequired:false, AdvancedSecurityEnabledForNewRepos:false, DependabotAlertsEnabledForNewRepos:false, DependabotSecurityUpdatesEnabledForNewRepos:false, DependencyGraphEnabledForNewRepos:false, SecretScanningEnabledForNewRepos:false, SecretScanningPushProtectionEnabledForNewRepos:false, SecretScanningValidityChecksEnabled:false, URL:"", EventsURL:"", HooksURL:"", IssuesURL:"", MembersURL:"", PublicMembersURL:"", ReposURL:""}` 1127 if got := v.String(); got != want { 1128 t.Errorf("Organization.String = %v, want %v", got, want) 1129 } 1130 } 1131 1132 func TestPackage_String(t *testing.T) { 1133 t.Parallel() 1134 v := Package{ 1135 ID: Ptr(int64(0)), 1136 Name: Ptr(""), 1137 PackageType: Ptr(""), 1138 HTMLURL: Ptr(""), 1139 Visibility: Ptr(""), 1140 Owner: &User{}, 1141 CreatedAt: &Timestamp{}, 1142 UpdatedAt: &Timestamp{}, 1143 Namespace: Ptr(""), 1144 Description: Ptr(""), 1145 Ecosystem: Ptr(""), 1146 PackageVersion: &PackageVersion{}, 1147 Registry: &PackageRegistry{}, 1148 URL: Ptr(""), 1149 VersionCount: Ptr(int64(0)), 1150 } 1151 want := `github.Package{ID:0, Name:"", PackageType:"", HTMLURL:"", Visibility:"", Owner:github.User{}, CreatedAt:github.Timestamp{0001-01-01 00:00:00 +0000 UTC}, UpdatedAt:github.Timestamp{0001-01-01 00:00:00 +0000 UTC}, Namespace:"", Description:"", Ecosystem:"", PackageVersion:github.PackageVersion{}, Registry:github.PackageRegistry{}, URL:"", VersionCount:0}` 1152 if got := v.String(); got != want { 1153 t.Errorf("Package.String = %v, want %v", got, want) 1154 } 1155 } 1156 1157 func TestPackageContainerMetadata_String(t *testing.T) { 1158 t.Parallel() 1159 v := PackageContainerMetadata{ 1160 Tags: []string{""}, 1161 } 1162 want := `github.PackageContainerMetadata{Tags:[""]}` 1163 if got := v.String(); got != want { 1164 t.Errorf("PackageContainerMetadata.String = %v, want %v", got, want) 1165 } 1166 } 1167 1168 func TestPackageEventContainerMetadata_String(t *testing.T) { 1169 t.Parallel() 1170 v := PackageEventContainerMetadata{ 1171 Tag: &PackageEventContainerMetadataTag{}, 1172 } 1173 want := `github.PackageEventContainerMetadata{Tag:github.PackageEventContainerMetadataTag{}}` 1174 if got := v.String(); got != want { 1175 t.Errorf("PackageEventContainerMetadata.String = %v, want %v", got, want) 1176 } 1177 } 1178 1179 func TestPackageEventContainerMetadataTag_String(t *testing.T) { 1180 t.Parallel() 1181 v := PackageEventContainerMetadataTag{ 1182 Name: Ptr(""), 1183 Digest: Ptr(""), 1184 } 1185 want := `github.PackageEventContainerMetadataTag{Name:"", Digest:""}` 1186 if got := v.String(); got != want { 1187 t.Errorf("PackageEventContainerMetadataTag.String = %v, want %v", got, want) 1188 } 1189 } 1190 1191 func TestPackageFile_String(t *testing.T) { 1192 t.Parallel() 1193 v := PackageFile{ 1194 DownloadURL: Ptr(""), 1195 ID: Ptr(int64(0)), 1196 Name: Ptr(""), 1197 SHA256: Ptr(""), 1198 SHA1: Ptr(""), 1199 MD5: Ptr(""), 1200 ContentType: Ptr(""), 1201 State: Ptr(""), 1202 Author: &User{}, 1203 Size: Ptr(int64(0)), 1204 CreatedAt: &Timestamp{}, 1205 UpdatedAt: &Timestamp{}, 1206 } 1207 want := `github.PackageFile{DownloadURL:"", ID:0, Name:"", SHA256:"", SHA1:"", MD5:"", ContentType:"", State:"", Author:github.User{}, Size:0, CreatedAt:github.Timestamp{0001-01-01 00:00:00 +0000 UTC}, UpdatedAt:github.Timestamp{0001-01-01 00:00:00 +0000 UTC}}` 1208 if got := v.String(); got != want { 1209 t.Errorf("PackageFile.String = %v, want %v", got, want) 1210 } 1211 } 1212 1213 func TestPackageMetadata_String(t *testing.T) { 1214 t.Parallel() 1215 v := PackageMetadata{ 1216 PackageType: Ptr(""), 1217 Container: &PackageContainerMetadata{}, 1218 } 1219 want := `github.PackageMetadata{PackageType:"", Container:github.PackageContainerMetadata{}}` 1220 if got := v.String(); got != want { 1221 t.Errorf("PackageMetadata.String = %v, want %v", got, want) 1222 } 1223 } 1224 1225 func TestPackageNPMMetadata_String(t *testing.T) { 1226 t.Parallel() 1227 v := PackageNPMMetadata{ 1228 Name: Ptr(""), 1229 Version: Ptr(""), 1230 NPMUser: Ptr(""), 1231 Description: Ptr(""), 1232 GitHead: Ptr(""), 1233 Homepage: Ptr(""), 1234 License: Ptr(""), 1235 Main: Ptr(""), 1236 ID: Ptr(""), 1237 NodeVersion: Ptr(""), 1238 NPMVersion: Ptr(""), 1239 HasShrinkwrap: Ptr(false), 1240 Keywords: []string{""}, 1241 Files: []string{""}, 1242 OS: []string{""}, 1243 CPU: []string{""}, 1244 Readme: Ptr(""), 1245 InstallationCommand: Ptr(""), 1246 ReleaseID: Ptr(int64(0)), 1247 CommitOID: Ptr(""), 1248 PublishedViaActions: Ptr(false), 1249 DeletedByID: Ptr(int64(0)), 1250 } 1251 want := `github.PackageNPMMetadata{Name:"", Version:"", NPMUser:"", Description:"", GitHead:"", Homepage:"", License:"", Main:"", ID:"", NodeVersion:"", NPMVersion:"", HasShrinkwrap:false, Keywords:[""], Files:[""], OS:[""], CPU:[""], Readme:"", InstallationCommand:"", ReleaseID:0, CommitOID:"", PublishedViaActions:false, DeletedByID:0}` 1252 if got := v.String(); got != want { 1253 t.Errorf("PackageNPMMetadata.String = %v, want %v", got, want) 1254 } 1255 } 1256 1257 func TestPackageNugetMetadata_String(t *testing.T) { 1258 t.Parallel() 1259 v := PackageNugetMetadata{ 1260 Name: Ptr(""), 1261 } 1262 want := `github.PackageNugetMetadata{Name:""}` 1263 if got := v.String(); got != want { 1264 t.Errorf("PackageNugetMetadata.String = %v, want %v", got, want) 1265 } 1266 } 1267 1268 func TestPackageRegistry_String(t *testing.T) { 1269 t.Parallel() 1270 v := PackageRegistry{ 1271 AboutURL: Ptr(""), 1272 Name: Ptr(""), 1273 Type: Ptr(""), 1274 URL: Ptr(""), 1275 Vendor: Ptr(""), 1276 } 1277 want := `github.PackageRegistry{AboutURL:"", Name:"", Type:"", URL:"", Vendor:""}` 1278 if got := v.String(); got != want { 1279 t.Errorf("PackageRegistry.String = %v, want %v", got, want) 1280 } 1281 } 1282 1283 func TestPackageRelease_String(t *testing.T) { 1284 t.Parallel() 1285 v := PackageRelease{ 1286 URL: Ptr(""), 1287 HTMLURL: Ptr(""), 1288 ID: Ptr(int64(0)), 1289 TagName: Ptr(""), 1290 TargetCommitish: Ptr(""), 1291 Name: Ptr(""), 1292 Draft: Ptr(false), 1293 Author: &User{}, 1294 Prerelease: Ptr(false), 1295 CreatedAt: &Timestamp{}, 1296 PublishedAt: &Timestamp{}, 1297 } 1298 want := `github.PackageRelease{URL:"", HTMLURL:"", ID:0, TagName:"", TargetCommitish:"", Name:"", Draft:false, Author:github.User{}, Prerelease:false, CreatedAt:github.Timestamp{0001-01-01 00:00:00 +0000 UTC}, PublishedAt:github.Timestamp{0001-01-01 00:00:00 +0000 UTC}}` 1299 if got := v.String(); got != want { 1300 t.Errorf("PackageRelease.String = %v, want %v", got, want) 1301 } 1302 } 1303 1304 func TestPackageVersion_String(t *testing.T) { 1305 t.Parallel() 1306 v := PackageVersion{ 1307 ID: Ptr(int64(0)), 1308 Name: Ptr(""), 1309 URL: Ptr(""), 1310 PackageHTMLURL: Ptr(""), 1311 License: Ptr(""), 1312 Description: Ptr(""), 1313 CreatedAt: &Timestamp{}, 1314 UpdatedAt: &Timestamp{}, 1315 Version: Ptr(""), 1316 Summary: Ptr(""), 1317 BodyHTML: Ptr(""), 1318 Release: &PackageRelease{}, 1319 Manifest: Ptr(""), 1320 HTMLURL: Ptr(""), 1321 TagName: Ptr(""), 1322 TargetCommitish: Ptr(""), 1323 TargetOID: Ptr(""), 1324 Draft: Ptr(false), 1325 Prerelease: Ptr(false), 1326 ContainerMetadata: &PackageEventContainerMetadata{}, 1327 NPMMetadata: &PackageNPMMetadata{}, 1328 PackageURL: Ptr(""), 1329 Author: &User{}, 1330 SourceURL: Ptr(""), 1331 InstallationCommand: Ptr(""), 1332 DeletedAt: &Timestamp{}, 1333 } 1334 want := `github.PackageVersion{ID:0, Name:"", URL:"", PackageHTMLURL:"", License:"", Description:"", CreatedAt:github.Timestamp{0001-01-01 00:00:00 +0000 UTC}, UpdatedAt:github.Timestamp{0001-01-01 00:00:00 +0000 UTC}, Version:"", Summary:"", BodyHTML:"", Release:github.PackageRelease{}, Manifest:"", HTMLURL:"", TagName:"", TargetCommitish:"", TargetOID:"", Draft:false, Prerelease:false, ContainerMetadata:github.PackageEventContainerMetadata{}, NPMMetadata:github.PackageNPMMetadata{}, PackageURL:"", Author:github.User{}, SourceURL:"", InstallationCommand:"", DeletedAt:github.Timestamp{0001-01-01 00:00:00 +0000 UTC}}` 1335 if got := v.String(); got != want { 1336 t.Errorf("PackageVersion.String = %v, want %v", got, want) 1337 } 1338 } 1339 1340 func TestPackageVersionBody_String(t *testing.T) { 1341 t.Parallel() 1342 v := PackageVersionBody{ 1343 Repo: &Repository{}, 1344 Info: &PackageVersionBodyInfo{}, 1345 } 1346 want := `github.PackageVersionBody{Repo:github.Repository{}, Info:github.PackageVersionBodyInfo{}}` 1347 if got := v.String(); got != want { 1348 t.Errorf("PackageVersionBody.String = %v, want %v", got, want) 1349 } 1350 } 1351 1352 func TestPackageVersionBodyInfo_String(t *testing.T) { 1353 t.Parallel() 1354 v := PackageVersionBodyInfo{ 1355 Type: Ptr(""), 1356 OID: Ptr(""), 1357 Mode: Ptr(int64(0)), 1358 Name: Ptr(""), 1359 Path: Ptr(""), 1360 Size: Ptr(int64(0)), 1361 Collection: Ptr(false), 1362 } 1363 want := `github.PackageVersionBodyInfo{Type:"", OID:"", Mode:0, Name:"", Path:"", Size:0, Collection:false}` 1364 if got := v.String(); got != want { 1365 t.Errorf("PackageVersionBodyInfo.String = %v, want %v", got, want) 1366 } 1367 } 1368 1369 func TestPageStats_String(t *testing.T) { 1370 t.Parallel() 1371 v := PageStats{ 1372 TotalPages: Ptr(0), 1373 } 1374 want := `github.PageStats{TotalPages:0}` 1375 if got := v.String(); got != want { 1376 t.Errorf("PageStats.String = %v, want %v", got, want) 1377 } 1378 } 1379 1380 func TestPlan_String(t *testing.T) { 1381 t.Parallel() 1382 v := Plan{ 1383 Name: Ptr(""), 1384 Space: Ptr(0), 1385 Collaborators: Ptr(0), 1386 PrivateRepos: Ptr(int64(0)), 1387 FilledSeats: Ptr(0), 1388 Seats: Ptr(0), 1389 } 1390 want := `github.Plan{Name:"", Space:0, Collaborators:0, PrivateRepos:0, FilledSeats:0, Seats:0}` 1391 if got := v.String(); got != want { 1392 t.Errorf("Plan.String = %v, want %v", got, want) 1393 } 1394 } 1395 1396 func TestPreReceiveHook_String(t *testing.T) { 1397 t.Parallel() 1398 v := PreReceiveHook{ 1399 ID: Ptr(int64(0)), 1400 Name: Ptr(""), 1401 Enforcement: Ptr(""), 1402 ConfigURL: Ptr(""), 1403 } 1404 want := `github.PreReceiveHook{ID:0, Name:"", Enforcement:"", ConfigURL:""}` 1405 if got := v.String(); got != want { 1406 t.Errorf("PreReceiveHook.String = %v, want %v", got, want) 1407 } 1408 } 1409 1410 func TestPullRequest_String(t *testing.T) { 1411 t.Parallel() 1412 v := PullRequest{ 1413 ID: Ptr(int64(0)), 1414 Number: Ptr(0), 1415 State: Ptr(""), 1416 Locked: Ptr(false), 1417 Title: Ptr(""), 1418 Body: Ptr(""), 1419 CreatedAt: &Timestamp{}, 1420 UpdatedAt: &Timestamp{}, 1421 ClosedAt: &Timestamp{}, 1422 MergedAt: &Timestamp{}, 1423 User: &User{}, 1424 Draft: Ptr(false), 1425 URL: Ptr(""), 1426 HTMLURL: Ptr(""), 1427 IssueURL: Ptr(""), 1428 StatusesURL: Ptr(""), 1429 DiffURL: Ptr(""), 1430 PatchURL: Ptr(""), 1431 CommitsURL: Ptr(""), 1432 CommentsURL: Ptr(""), 1433 ReviewCommentsURL: Ptr(""), 1434 ReviewCommentURL: Ptr(""), 1435 Assignee: &User{}, 1436 Milestone: &Milestone{}, 1437 AuthorAssociation: Ptr(""), 1438 NodeID: Ptr(""), 1439 AutoMerge: &PullRequestAutoMerge{}, 1440 Merged: Ptr(false), 1441 Mergeable: Ptr(false), 1442 MergeableState: Ptr(""), 1443 Rebaseable: Ptr(false), 1444 MergedBy: &User{}, 1445 MergeCommitSHA: Ptr(""), 1446 Comments: Ptr(0), 1447 Commits: Ptr(0), 1448 Additions: Ptr(0), 1449 Deletions: Ptr(0), 1450 ChangedFiles: Ptr(0), 1451 MaintainerCanModify: Ptr(false), 1452 ReviewComments: Ptr(0), 1453 Links: &PRLinks{}, 1454 Head: &PullRequestBranch{}, 1455 Base: &PullRequestBranch{}, 1456 ActiveLockReason: Ptr(""), 1457 } 1458 want := `github.PullRequest{ID:0, Number:0, State:"", Locked:false, Title:"", Body:"", CreatedAt:github.Timestamp{0001-01-01 00:00:00 +0000 UTC}, UpdatedAt:github.Timestamp{0001-01-01 00:00:00 +0000 UTC}, ClosedAt:github.Timestamp{0001-01-01 00:00:00 +0000 UTC}, MergedAt:github.Timestamp{0001-01-01 00:00:00 +0000 UTC}, User:github.User{}, Draft:false, URL:"", HTMLURL:"", IssueURL:"", StatusesURL:"", DiffURL:"", PatchURL:"", CommitsURL:"", CommentsURL:"", ReviewCommentsURL:"", ReviewCommentURL:"", Assignee:github.User{}, Milestone:github.Milestone{}, AuthorAssociation:"", NodeID:"", AutoMerge:github.PullRequestAutoMerge{}, Merged:false, Mergeable:false, MergeableState:"", Rebaseable:false, MergedBy:github.User{}, MergeCommitSHA:"", Comments:0, Commits:0, Additions:0, Deletions:0, ChangedFiles:0, MaintainerCanModify:false, ReviewComments:0, Links:github.PRLinks{}, Head:github.PullRequestBranch{}, Base:github.PullRequestBranch{}, ActiveLockReason:""}` 1459 if got := v.String(); got != want { 1460 t.Errorf("PullRequest.String = %v, want %v", got, want) 1461 } 1462 } 1463 1464 func TestPullRequestComment_String(t *testing.T) { 1465 t.Parallel() 1466 v := PullRequestComment{ 1467 ID: Ptr(int64(0)), 1468 NodeID: Ptr(""), 1469 InReplyTo: Ptr(int64(0)), 1470 Body: Ptr(""), 1471 Path: Ptr(""), 1472 DiffHunk: Ptr(""), 1473 PullRequestReviewID: Ptr(int64(0)), 1474 Position: Ptr(0), 1475 OriginalPosition: Ptr(0), 1476 StartLine: Ptr(0), 1477 Line: Ptr(0), 1478 OriginalLine: Ptr(0), 1479 OriginalStartLine: Ptr(0), 1480 Side: Ptr(""), 1481 StartSide: Ptr(""), 1482 CommitID: Ptr(""), 1483 OriginalCommitID: Ptr(""), 1484 User: &User{}, 1485 Reactions: &Reactions{}, 1486 CreatedAt: &Timestamp{}, 1487 UpdatedAt: &Timestamp{}, 1488 AuthorAssociation: Ptr(""), 1489 URL: Ptr(""), 1490 HTMLURL: Ptr(""), 1491 PullRequestURL: Ptr(""), 1492 SubjectType: Ptr(""), 1493 } 1494 want := `github.PullRequestComment{ID:0, NodeID:"", InReplyTo:0, Body:"", Path:"", DiffHunk:"", PullRequestReviewID:0, Position:0, OriginalPosition:0, StartLine:0, Line:0, OriginalLine:0, OriginalStartLine:0, Side:"", StartSide:"", CommitID:"", OriginalCommitID:"", User:github.User{}, Reactions:github.Reactions{}, CreatedAt:github.Timestamp{0001-01-01 00:00:00 +0000 UTC}, UpdatedAt:github.Timestamp{0001-01-01 00:00:00 +0000 UTC}, AuthorAssociation:"", URL:"", HTMLURL:"", PullRequestURL:"", SubjectType:""}` 1495 if got := v.String(); got != want { 1496 t.Errorf("PullRequestComment.String = %v, want %v", got, want) 1497 } 1498 } 1499 1500 func TestPullRequestReview_String(t *testing.T) { 1501 t.Parallel() 1502 v := PullRequestReview{ 1503 ID: Ptr(int64(0)), 1504 NodeID: Ptr(""), 1505 User: &User{}, 1506 Body: Ptr(""), 1507 SubmittedAt: &Timestamp{}, 1508 CommitID: Ptr(""), 1509 HTMLURL: Ptr(""), 1510 PullRequestURL: Ptr(""), 1511 State: Ptr(""), 1512 AuthorAssociation: Ptr(""), 1513 } 1514 want := `github.PullRequestReview{ID:0, NodeID:"", User:github.User{}, Body:"", SubmittedAt:github.Timestamp{0001-01-01 00:00:00 +0000 UTC}, CommitID:"", HTMLURL:"", PullRequestURL:"", State:"", AuthorAssociation:""}` 1515 if got := v.String(); got != want { 1516 t.Errorf("PullRequestReview.String = %v, want %v", got, want) 1517 } 1518 } 1519 1520 func TestPullRequestReviewDismissalRequest_String(t *testing.T) { 1521 t.Parallel() 1522 v := PullRequestReviewDismissalRequest{ 1523 Message: Ptr(""), 1524 } 1525 want := `github.PullRequestReviewDismissalRequest{Message:""}` 1526 if got := v.String(); got != want { 1527 t.Errorf("PullRequestReviewDismissalRequest.String = %v, want %v", got, want) 1528 } 1529 } 1530 1531 func TestPullRequestReviewRequest_String(t *testing.T) { 1532 t.Parallel() 1533 v := PullRequestReviewRequest{ 1534 NodeID: Ptr(""), 1535 CommitID: Ptr(""), 1536 Body: Ptr(""), 1537 Event: Ptr(""), 1538 } 1539 want := `github.PullRequestReviewRequest{NodeID:"", CommitID:"", Body:"", Event:""}` 1540 if got := v.String(); got != want { 1541 t.Errorf("PullRequestReviewRequest.String = %v, want %v", got, want) 1542 } 1543 } 1544 1545 func TestPullRequestThread_String(t *testing.T) { 1546 t.Parallel() 1547 v := PullRequestThread{ 1548 ID: Ptr(int64(0)), 1549 NodeID: Ptr(""), 1550 } 1551 want := `github.PullRequestThread{ID:0, NodeID:""}` 1552 if got := v.String(); got != want { 1553 t.Errorf("PullRequestThread.String = %v, want %v", got, want) 1554 } 1555 } 1556 1557 func TestPullStats_String(t *testing.T) { 1558 t.Parallel() 1559 v := PullStats{ 1560 TotalPulls: Ptr(0), 1561 MergedPulls: Ptr(0), 1562 MergeablePulls: Ptr(0), 1563 UnmergeablePulls: Ptr(0), 1564 } 1565 want := `github.PullStats{TotalPulls:0, MergedPulls:0, MergeablePulls:0, UnmergeablePulls:0}` 1566 if got := v.String(); got != want { 1567 t.Errorf("PullStats.String = %v, want %v", got, want) 1568 } 1569 } 1570 1571 func TestPushEvent_String(t *testing.T) { 1572 t.Parallel() 1573 v := PushEvent{ 1574 PushID: Ptr(int64(0)), 1575 Head: Ptr(""), 1576 Ref: Ptr(""), 1577 Size: Ptr(0), 1578 Before: Ptr(""), 1579 DistinctSize: Ptr(0), 1580 Action: Ptr(""), 1581 After: Ptr(""), 1582 Created: Ptr(false), 1583 Deleted: Ptr(false), 1584 Forced: Ptr(false), 1585 BaseRef: Ptr(""), 1586 Compare: Ptr(""), 1587 Repo: &PushEventRepository{}, 1588 HeadCommit: &HeadCommit{}, 1589 Pusher: &CommitAuthor{}, 1590 Sender: &User{}, 1591 Installation: &Installation{}, 1592 Organization: &Organization{}, 1593 } 1594 want := `github.PushEvent{PushID:0, Head:"", Ref:"", Size:0, Before:"", DistinctSize:0, Action:"", After:"", Created:false, Deleted:false, Forced:false, BaseRef:"", Compare:"", Repo:github.PushEventRepository{}, HeadCommit:github.HeadCommit{}, Pusher:github.CommitAuthor{}, Sender:github.User{}, Installation:github.Installation{}, Organization:github.Organization{}}` 1595 if got := v.String(); got != want { 1596 t.Errorf("PushEvent.String = %v, want %v", got, want) 1597 } 1598 } 1599 1600 func TestRate_String(t *testing.T) { 1601 t.Parallel() 1602 v := Rate{ 1603 Limit: 0, 1604 Remaining: 0, 1605 Used: 0, 1606 Reset: Timestamp{}, 1607 Resource: "", 1608 } 1609 want := `github.Rate{Limit:0, Remaining:0, Used:0, Reset:github.Timestamp{0001-01-01 00:00:00 +0000 UTC}, Resource:""}` 1610 if got := v.String(); got != want { 1611 t.Errorf("Rate.String = %v, want %v", got, want) 1612 } 1613 } 1614 1615 func TestReaction_String(t *testing.T) { 1616 t.Parallel() 1617 v := Reaction{ 1618 ID: Ptr(int64(0)), 1619 User: &User{}, 1620 NodeID: Ptr(""), 1621 Content: Ptr(""), 1622 CreatedAt: &Timestamp{}, 1623 } 1624 want := `github.Reaction{ID:0, User:github.User{}, NodeID:"", Content:"", CreatedAt:github.Timestamp{0001-01-01 00:00:00 +0000 UTC}}` 1625 if got := v.String(); got != want { 1626 t.Errorf("Reaction.String = %v, want %v", got, want) 1627 } 1628 } 1629 1630 func TestReference_String(t *testing.T) { 1631 t.Parallel() 1632 v := Reference{ 1633 Ref: Ptr(""), 1634 URL: Ptr(""), 1635 Object: &GitObject{}, 1636 NodeID: Ptr(""), 1637 } 1638 want := `github.Reference{Ref:"", URL:"", Object:github.GitObject{}, NodeID:""}` 1639 if got := v.String(); got != want { 1640 t.Errorf("Reference.String = %v, want %v", got, want) 1641 } 1642 } 1643 1644 func TestReleaseAsset_String(t *testing.T) { 1645 t.Parallel() 1646 v := ReleaseAsset{ 1647 ID: Ptr(int64(0)), 1648 URL: Ptr(""), 1649 Name: Ptr(""), 1650 Label: Ptr(""), 1651 State: Ptr(""), 1652 ContentType: Ptr(""), 1653 Size: Ptr(0), 1654 DownloadCount: Ptr(0), 1655 CreatedAt: &Timestamp{}, 1656 UpdatedAt: &Timestamp{}, 1657 BrowserDownloadURL: Ptr(""), 1658 Uploader: &User{}, 1659 NodeID: Ptr(""), 1660 } 1661 want := `github.ReleaseAsset{ID:0, URL:"", Name:"", Label:"", State:"", ContentType:"", Size:0, DownloadCount:0, CreatedAt:github.Timestamp{0001-01-01 00:00:00 +0000 UTC}, UpdatedAt:github.Timestamp{0001-01-01 00:00:00 +0000 UTC}, BrowserDownloadURL:"", Uploader:github.User{}, NodeID:""}` 1662 if got := v.String(); got != want { 1663 t.Errorf("ReleaseAsset.String = %v, want %v", got, want) 1664 } 1665 } 1666 1667 func TestRename_String(t *testing.T) { 1668 t.Parallel() 1669 v := Rename{ 1670 From: Ptr(""), 1671 To: Ptr(""), 1672 } 1673 want := `github.Rename{From:"", To:""}` 1674 if got := v.String(); got != want { 1675 t.Errorf("Rename.String = %v, want %v", got, want) 1676 } 1677 } 1678 1679 func TestRepoStats_String(t *testing.T) { 1680 t.Parallel() 1681 v := RepoStats{ 1682 TotalRepos: Ptr(0), 1683 RootRepos: Ptr(0), 1684 ForkRepos: Ptr(0), 1685 OrgRepos: Ptr(0), 1686 TotalPushes: Ptr(0), 1687 TotalWikis: Ptr(0), 1688 } 1689 want := `github.RepoStats{TotalRepos:0, RootRepos:0, ForkRepos:0, OrgRepos:0, TotalPushes:0, TotalWikis:0}` 1690 if got := v.String(); got != want { 1691 t.Errorf("RepoStats.String = %v, want %v", got, want) 1692 } 1693 } 1694 1695 func TestRepoStatus_String(t *testing.T) { 1696 t.Parallel() 1697 v := RepoStatus{ 1698 ID: Ptr(int64(0)), 1699 NodeID: Ptr(""), 1700 URL: Ptr(""), 1701 State: Ptr(""), 1702 TargetURL: Ptr(""), 1703 Description: Ptr(""), 1704 Context: Ptr(""), 1705 AvatarURL: Ptr(""), 1706 Creator: &User{}, 1707 CreatedAt: &Timestamp{}, 1708 UpdatedAt: &Timestamp{}, 1709 } 1710 want := `github.RepoStatus{ID:0, NodeID:"", URL:"", State:"", TargetURL:"", Description:"", Context:"", AvatarURL:"", Creator:github.User{}, CreatedAt:github.Timestamp{0001-01-01 00:00:00 +0000 UTC}, UpdatedAt:github.Timestamp{0001-01-01 00:00:00 +0000 UTC}}` 1711 if got := v.String(); got != want { 1712 t.Errorf("RepoStatus.String = %v, want %v", got, want) 1713 } 1714 } 1715 1716 func TestRepository_String(t *testing.T) { 1717 t.Parallel() 1718 v := Repository{ 1719 ID: Ptr(int64(0)), 1720 NodeID: Ptr(""), 1721 Owner: &User{}, 1722 Name: Ptr(""), 1723 FullName: Ptr(""), 1724 Description: Ptr(""), 1725 Homepage: Ptr(""), 1726 CodeOfConduct: &CodeOfConduct{}, 1727 DefaultBranch: Ptr(""), 1728 MasterBranch: Ptr(""), 1729 CreatedAt: &Timestamp{}, 1730 PushedAt: &Timestamp{}, 1731 UpdatedAt: &Timestamp{}, 1732 HTMLURL: Ptr(""), 1733 CloneURL: Ptr(""), 1734 GitURL: Ptr(""), 1735 MirrorURL: Ptr(""), 1736 SSHURL: Ptr(""), 1737 SVNURL: Ptr(""), 1738 Language: Ptr(""), 1739 Fork: Ptr(false), 1740 ForksCount: Ptr(0), 1741 NetworkCount: Ptr(0), 1742 OpenIssuesCount: Ptr(0), 1743 OpenIssues: Ptr(0), 1744 StargazersCount: Ptr(0), 1745 SubscribersCount: Ptr(0), 1746 WatchersCount: Ptr(0), 1747 Watchers: Ptr(0), 1748 Size: Ptr(0), 1749 AutoInit: Ptr(false), 1750 Parent: &Repository{}, 1751 Source: &Repository{}, 1752 TemplateRepository: &Repository{}, 1753 Organization: &Organization{}, 1754 AllowRebaseMerge: Ptr(false), 1755 AllowUpdateBranch: Ptr(false), 1756 AllowSquashMerge: Ptr(false), 1757 AllowMergeCommit: Ptr(false), 1758 AllowAutoMerge: Ptr(false), 1759 AllowForking: Ptr(false), 1760 WebCommitSignoffRequired: Ptr(false), 1761 DeleteBranchOnMerge: Ptr(false), 1762 UseSquashPRTitleAsDefault: Ptr(false), 1763 SquashMergeCommitTitle: Ptr(""), 1764 SquashMergeCommitMessage: Ptr(""), 1765 MergeCommitTitle: Ptr(""), 1766 MergeCommitMessage: Ptr(""), 1767 Topics: []string{""}, 1768 Archived: Ptr(false), 1769 Disabled: Ptr(false), 1770 License: &License{}, 1771 Private: Ptr(false), 1772 HasIssues: Ptr(false), 1773 HasWiki: Ptr(false), 1774 HasPages: Ptr(false), 1775 HasProjects: Ptr(false), 1776 HasDownloads: Ptr(false), 1777 HasDiscussions: Ptr(false), 1778 IsTemplate: Ptr(false), 1779 LicenseTemplate: Ptr(""), 1780 GitignoreTemplate: Ptr(""), 1781 SecurityAndAnalysis: &SecurityAndAnalysis{}, 1782 TeamID: Ptr(int64(0)), 1783 URL: Ptr(""), 1784 ArchiveURL: Ptr(""), 1785 AssigneesURL: Ptr(""), 1786 BlobsURL: Ptr(""), 1787 BranchesURL: Ptr(""), 1788 CollaboratorsURL: Ptr(""), 1789 CommentsURL: Ptr(""), 1790 CommitsURL: Ptr(""), 1791 CompareURL: Ptr(""), 1792 ContentsURL: Ptr(""), 1793 ContributorsURL: Ptr(""), 1794 DeploymentsURL: Ptr(""), 1795 DownloadsURL: Ptr(""), 1796 EventsURL: Ptr(""), 1797 ForksURL: Ptr(""), 1798 GitCommitsURL: Ptr(""), 1799 GitRefsURL: Ptr(""), 1800 GitTagsURL: Ptr(""), 1801 HooksURL: Ptr(""), 1802 IssueCommentURL: Ptr(""), 1803 IssueEventsURL: Ptr(""), 1804 IssuesURL: Ptr(""), 1805 KeysURL: Ptr(""), 1806 LabelsURL: Ptr(""), 1807 LanguagesURL: Ptr(""), 1808 MergesURL: Ptr(""), 1809 MilestonesURL: Ptr(""), 1810 NotificationsURL: Ptr(""), 1811 PullsURL: Ptr(""), 1812 ReleasesURL: Ptr(""), 1813 StargazersURL: Ptr(""), 1814 StatusesURL: Ptr(""), 1815 SubscribersURL: Ptr(""), 1816 SubscriptionURL: Ptr(""), 1817 TagsURL: Ptr(""), 1818 TreesURL: Ptr(""), 1819 TeamsURL: Ptr(""), 1820 Visibility: Ptr(""), 1821 RoleName: Ptr(""), 1822 } 1823 want := `github.Repository{ID:0, NodeID:"", Owner:github.User{}, Name:"", FullName:"", Description:"", Homepage:"", CodeOfConduct:github.CodeOfConduct{}, DefaultBranch:"", MasterBranch:"", CreatedAt:github.Timestamp{0001-01-01 00:00:00 +0000 UTC}, PushedAt:github.Timestamp{0001-01-01 00:00:00 +0000 UTC}, UpdatedAt:github.Timestamp{0001-01-01 00:00:00 +0000 UTC}, HTMLURL:"", CloneURL:"", GitURL:"", MirrorURL:"", SSHURL:"", SVNURL:"", Language:"", Fork:false, ForksCount:0, NetworkCount:0, OpenIssuesCount:0, OpenIssues:0, StargazersCount:0, SubscribersCount:0, WatchersCount:0, Watchers:0, Size:0, AutoInit:false, Parent:github.Repository{}, Source:github.Repository{}, TemplateRepository:github.Repository{}, Organization:github.Organization{}, AllowRebaseMerge:false, AllowUpdateBranch:false, AllowSquashMerge:false, AllowMergeCommit:false, AllowAutoMerge:false, AllowForking:false, WebCommitSignoffRequired:false, DeleteBranchOnMerge:false, UseSquashPRTitleAsDefault:false, SquashMergeCommitTitle:"", SquashMergeCommitMessage:"", MergeCommitTitle:"", MergeCommitMessage:"", Topics:[""], Archived:false, Disabled:false, License:github.License{}, Private:false, HasIssues:false, HasWiki:false, HasPages:false, HasProjects:false, HasDownloads:false, HasDiscussions:false, IsTemplate:false, LicenseTemplate:"", GitignoreTemplate:"", SecurityAndAnalysis:github.SecurityAndAnalysis{}, TeamID:0, URL:"", ArchiveURL:"", AssigneesURL:"", BlobsURL:"", BranchesURL:"", CollaboratorsURL:"", CommentsURL:"", CommitsURL:"", CompareURL:"", ContentsURL:"", ContributorsURL:"", DeploymentsURL:"", DownloadsURL:"", EventsURL:"", ForksURL:"", GitCommitsURL:"", GitRefsURL:"", GitTagsURL:"", HooksURL:"", IssueCommentURL:"", IssueEventsURL:"", IssuesURL:"", KeysURL:"", LabelsURL:"", LanguagesURL:"", MergesURL:"", MilestonesURL:"", NotificationsURL:"", PullsURL:"", ReleasesURL:"", StargazersURL:"", StatusesURL:"", SubscribersURL:"", SubscriptionURL:"", TagsURL:"", TreesURL:"", TeamsURL:"", Visibility:"", RoleName:""}` 1824 if got := v.String(); got != want { 1825 t.Errorf("Repository.String = %v, want %v", got, want) 1826 } 1827 } 1828 1829 func TestRepositoryComment_String(t *testing.T) { 1830 t.Parallel() 1831 v := RepositoryComment{ 1832 HTMLURL: Ptr(""), 1833 URL: Ptr(""), 1834 ID: Ptr(int64(0)), 1835 NodeID: Ptr(""), 1836 CommitID: Ptr(""), 1837 User: &User{}, 1838 Reactions: &Reactions{}, 1839 CreatedAt: &Timestamp{}, 1840 UpdatedAt: &Timestamp{}, 1841 Body: Ptr(""), 1842 Path: Ptr(""), 1843 Position: Ptr(0), 1844 } 1845 want := `github.RepositoryComment{HTMLURL:"", URL:"", ID:0, NodeID:"", CommitID:"", User:github.User{}, Reactions:github.Reactions{}, CreatedAt:github.Timestamp{0001-01-01 00:00:00 +0000 UTC}, UpdatedAt:github.Timestamp{0001-01-01 00:00:00 +0000 UTC}, Body:"", Path:"", Position:0}` 1846 if got := v.String(); got != want { 1847 t.Errorf("RepositoryComment.String = %v, want %v", got, want) 1848 } 1849 } 1850 1851 func TestRepositoryCommit_String(t *testing.T) { 1852 t.Parallel() 1853 v := RepositoryCommit{ 1854 NodeID: Ptr(""), 1855 SHA: Ptr(""), 1856 Commit: &Commit{}, 1857 Author: &User{}, 1858 Committer: &User{}, 1859 HTMLURL: Ptr(""), 1860 URL: Ptr(""), 1861 CommentsURL: Ptr(""), 1862 Stats: &CommitStats{}, 1863 } 1864 want := `github.RepositoryCommit{NodeID:"", SHA:"", Commit:github.Commit{}, Author:github.User{}, Committer:github.User{}, HTMLURL:"", URL:"", CommentsURL:"", Stats:github.CommitStats{}}` 1865 if got := v.String(); got != want { 1866 t.Errorf("RepositoryCommit.String = %v, want %v", got, want) 1867 } 1868 } 1869 1870 func TestRepositoryContent_String(t *testing.T) { 1871 t.Parallel() 1872 v := RepositoryContent{ 1873 Type: Ptr(""), 1874 Target: Ptr(""), 1875 Encoding: Ptr(""), 1876 Size: Ptr(0), 1877 Name: Ptr(""), 1878 Path: Ptr(""), 1879 Content: Ptr(""), 1880 SHA: Ptr(""), 1881 URL: Ptr(""), 1882 GitURL: Ptr(""), 1883 HTMLURL: Ptr(""), 1884 DownloadURL: Ptr(""), 1885 SubmoduleGitURL: Ptr(""), 1886 } 1887 want := `github.RepositoryContent{Type:"", Target:"", Encoding:"", Size:0, Name:"", Path:"", Content:"", SHA:"", URL:"", GitURL:"", HTMLURL:"", DownloadURL:"", SubmoduleGitURL:""}` 1888 if got := v.String(); got != want { 1889 t.Errorf("RepositoryContent.String = %v, want %v", got, want) 1890 } 1891 } 1892 1893 func TestRepositoryLicense_String(t *testing.T) { 1894 t.Parallel() 1895 v := RepositoryLicense{ 1896 Name: Ptr(""), 1897 Path: Ptr(""), 1898 SHA: Ptr(""), 1899 Size: Ptr(0), 1900 URL: Ptr(""), 1901 HTMLURL: Ptr(""), 1902 GitURL: Ptr(""), 1903 DownloadURL: Ptr(""), 1904 Type: Ptr(""), 1905 Content: Ptr(""), 1906 Encoding: Ptr(""), 1907 License: &License{}, 1908 } 1909 want := `github.RepositoryLicense{Name:"", Path:"", SHA:"", Size:0, URL:"", HTMLURL:"", GitURL:"", DownloadURL:"", Type:"", Content:"", Encoding:"", License:github.License{}}` 1910 if got := v.String(); got != want { 1911 t.Errorf("RepositoryLicense.String = %v, want %v", got, want) 1912 } 1913 } 1914 1915 func TestRepositoryParticipation_String(t *testing.T) { 1916 t.Parallel() 1917 v := RepositoryParticipation{ 1918 All: []int{0}, 1919 Owner: []int{0}, 1920 } 1921 want := `github.RepositoryParticipation{All:[0], Owner:[0]}` 1922 if got := v.String(); got != want { 1923 t.Errorf("RepositoryParticipation.String = %v, want %v", got, want) 1924 } 1925 } 1926 1927 func TestRepositoryRelease_String(t *testing.T) { 1928 t.Parallel() 1929 v := RepositoryRelease{ 1930 TagName: Ptr(""), 1931 TargetCommitish: Ptr(""), 1932 Name: Ptr(""), 1933 Body: Ptr(""), 1934 Draft: Ptr(false), 1935 Prerelease: Ptr(false), 1936 MakeLatest: Ptr(""), 1937 DiscussionCategoryName: Ptr(""), 1938 GenerateReleaseNotes: Ptr(false), 1939 ID: Ptr(int64(0)), 1940 CreatedAt: &Timestamp{}, 1941 PublishedAt: &Timestamp{}, 1942 URL: Ptr(""), 1943 HTMLURL: Ptr(""), 1944 AssetsURL: Ptr(""), 1945 UploadURL: Ptr(""), 1946 ZipballURL: Ptr(""), 1947 TarballURL: Ptr(""), 1948 Author: &User{}, 1949 NodeID: Ptr(""), 1950 } 1951 want := `github.RepositoryRelease{TagName:"", TargetCommitish:"", Name:"", Body:"", Draft:false, Prerelease:false, MakeLatest:"", DiscussionCategoryName:"", GenerateReleaseNotes:false, ID:0, CreatedAt:github.Timestamp{0001-01-01 00:00:00 +0000 UTC}, PublishedAt:github.Timestamp{0001-01-01 00:00:00 +0000 UTC}, URL:"", HTMLURL:"", AssetsURL:"", UploadURL:"", ZipballURL:"", TarballURL:"", Author:github.User{}, NodeID:""}` 1952 if got := v.String(); got != want { 1953 t.Errorf("RepositoryRelease.String = %v, want %v", got, want) 1954 } 1955 } 1956 1957 func TestSBOM_String(t *testing.T) { 1958 t.Parallel() 1959 v := SBOM{ 1960 SBOM: &SBOMInfo{}, 1961 } 1962 want := `github.SBOM{SBOM:github.SBOMInfo{}}` 1963 if got := v.String(); got != want { 1964 t.Errorf("SBOM.String = %v, want %v", got, want) 1965 } 1966 } 1967 1968 func TestSSHSigningKey_String(t *testing.T) { 1969 t.Parallel() 1970 v := SSHSigningKey{ 1971 ID: Ptr(int64(0)), 1972 Key: Ptr(""), 1973 Title: Ptr(""), 1974 CreatedAt: &Timestamp{}, 1975 } 1976 want := `github.SSHSigningKey{ID:0, Key:"", Title:"", CreatedAt:github.Timestamp{0001-01-01 00:00:00 +0000 UTC}}` 1977 if got := v.String(); got != want { 1978 t.Errorf("SSHSigningKey.String = %v, want %v", got, want) 1979 } 1980 } 1981 1982 func TestSecretScanning_String(t *testing.T) { 1983 t.Parallel() 1984 v := SecretScanning{ 1985 Status: Ptr(""), 1986 } 1987 want := `github.SecretScanning{Status:""}` 1988 if got := v.String(); got != want { 1989 t.Errorf("SecretScanning.String = %v, want %v", got, want) 1990 } 1991 } 1992 1993 func TestSecretScanningPushProtection_String(t *testing.T) { 1994 t.Parallel() 1995 v := SecretScanningPushProtection{ 1996 Status: Ptr(""), 1997 } 1998 want := `github.SecretScanningPushProtection{Status:""}` 1999 if got := v.String(); got != want { 2000 t.Errorf("SecretScanningPushProtection.String = %v, want %v", got, want) 2001 } 2002 } 2003 2004 func TestSecurityAndAnalysis_String(t *testing.T) { 2005 t.Parallel() 2006 v := SecurityAndAnalysis{ 2007 AdvancedSecurity: &AdvancedSecurity{}, 2008 SecretScanning: &SecretScanning{}, 2009 SecretScanningPushProtection: &SecretScanningPushProtection{}, 2010 DependabotSecurityUpdates: &DependabotSecurityUpdates{}, 2011 SecretScanningValidityChecks: &SecretScanningValidityChecks{}, 2012 } 2013 want := `github.SecurityAndAnalysis{AdvancedSecurity:github.AdvancedSecurity{}, SecretScanning:github.SecretScanning{}, SecretScanningPushProtection:github.SecretScanningPushProtection{}, DependabotSecurityUpdates:github.DependabotSecurityUpdates{}, SecretScanningValidityChecks:github.SecretScanningValidityChecks{}}` 2014 if got := v.String(); got != want { 2015 t.Errorf("SecurityAndAnalysis.String = %v, want %v", got, want) 2016 } 2017 } 2018 2019 func TestSourceImportAuthor_String(t *testing.T) { 2020 t.Parallel() 2021 v := SourceImportAuthor{ 2022 ID: Ptr(int64(0)), 2023 RemoteID: Ptr(""), 2024 RemoteName: Ptr(""), 2025 Email: Ptr(""), 2026 Name: Ptr(""), 2027 URL: Ptr(""), 2028 ImportURL: Ptr(""), 2029 } 2030 want := `github.SourceImportAuthor{ID:0, RemoteID:"", RemoteName:"", Email:"", Name:"", URL:"", ImportURL:""}` 2031 if got := v.String(); got != want { 2032 t.Errorf("SourceImportAuthor.String = %v, want %v", got, want) 2033 } 2034 } 2035 2036 func TestTeam_String(t *testing.T) { 2037 t.Parallel() 2038 v := Team{ 2039 ID: Ptr(int64(0)), 2040 NodeID: Ptr(""), 2041 Name: Ptr(""), 2042 Description: Ptr(""), 2043 URL: Ptr(""), 2044 Slug: Ptr(""), 2045 Permission: Ptr(""), 2046 Privacy: Ptr(""), 2047 NotificationSetting: Ptr(""), 2048 MembersCount: Ptr(0), 2049 ReposCount: Ptr(0), 2050 Organization: &Organization{}, 2051 HTMLURL: Ptr(""), 2052 MembersURL: Ptr(""), 2053 RepositoriesURL: Ptr(""), 2054 Parent: &Team{}, 2055 LDAPDN: Ptr(""), 2056 Assignment: Ptr(""), 2057 } 2058 want := `github.Team{ID:0, NodeID:"", Name:"", Description:"", URL:"", Slug:"", Permission:"", Privacy:"", NotificationSetting:"", MembersCount:0, ReposCount:0, Organization:github.Organization{}, HTMLURL:"", MembersURL:"", RepositoriesURL:"", Parent:github.Team{}, LDAPDN:"", Assignment:""}` 2059 if got := v.String(); got != want { 2060 t.Errorf("Team.String = %v, want %v", got, want) 2061 } 2062 } 2063 2064 func TestTeamDiscussion_String(t *testing.T) { 2065 t.Parallel() 2066 v := TeamDiscussion{ 2067 Author: &User{}, 2068 Body: Ptr(""), 2069 BodyHTML: Ptr(""), 2070 BodyVersion: Ptr(""), 2071 CommentsCount: Ptr(0), 2072 CommentsURL: Ptr(""), 2073 CreatedAt: &Timestamp{}, 2074 LastEditedAt: &Timestamp{}, 2075 HTMLURL: Ptr(""), 2076 NodeID: Ptr(""), 2077 Number: Ptr(0), 2078 Pinned: Ptr(false), 2079 Private: Ptr(false), 2080 TeamURL: Ptr(""), 2081 Title: Ptr(""), 2082 UpdatedAt: &Timestamp{}, 2083 URL: Ptr(""), 2084 Reactions: &Reactions{}, 2085 } 2086 want := `github.TeamDiscussion{Author:github.User{}, Body:"", BodyHTML:"", BodyVersion:"", CommentsCount:0, CommentsURL:"", CreatedAt:github.Timestamp{0001-01-01 00:00:00 +0000 UTC}, LastEditedAt:github.Timestamp{0001-01-01 00:00:00 +0000 UTC}, HTMLURL:"", NodeID:"", Number:0, Pinned:false, Private:false, TeamURL:"", Title:"", UpdatedAt:github.Timestamp{0001-01-01 00:00:00 +0000 UTC}, URL:"", Reactions:github.Reactions{}}` 2087 if got := v.String(); got != want { 2088 t.Errorf("TeamDiscussion.String = %v, want %v", got, want) 2089 } 2090 } 2091 2092 func TestTeamLDAPMapping_String(t *testing.T) { 2093 t.Parallel() 2094 v := TeamLDAPMapping{ 2095 ID: Ptr(int64(0)), 2096 LDAPDN: Ptr(""), 2097 URL: Ptr(""), 2098 Name: Ptr(""), 2099 Slug: Ptr(""), 2100 Description: Ptr(""), 2101 Privacy: Ptr(""), 2102 Permission: Ptr(""), 2103 MembersURL: Ptr(""), 2104 RepositoriesURL: Ptr(""), 2105 } 2106 want := `github.TeamLDAPMapping{ID:0, LDAPDN:"", URL:"", Name:"", Slug:"", Description:"", Privacy:"", Permission:"", MembersURL:"", RepositoriesURL:""}` 2107 if got := v.String(); got != want { 2108 t.Errorf("TeamLDAPMapping.String = %v, want %v", got, want) 2109 } 2110 } 2111 2112 func TestTextMatch_String(t *testing.T) { 2113 t.Parallel() 2114 v := TextMatch{ 2115 ObjectURL: Ptr(""), 2116 ObjectType: Ptr(""), 2117 Property: Ptr(""), 2118 Fragment: Ptr(""), 2119 } 2120 want := `github.TextMatch{ObjectURL:"", ObjectType:"", Property:"", Fragment:""}` 2121 if got := v.String(); got != want { 2122 t.Errorf("TextMatch.String = %v, want %v", got, want) 2123 } 2124 } 2125 2126 func TestTree_String(t *testing.T) { 2127 t.Parallel() 2128 v := Tree{ 2129 SHA: Ptr(""), 2130 Truncated: Ptr(false), 2131 } 2132 want := `github.Tree{SHA:"", Truncated:false}` 2133 if got := v.String(); got != want { 2134 t.Errorf("Tree.String = %v, want %v", got, want) 2135 } 2136 } 2137 2138 func TestTreeEntry_String(t *testing.T) { 2139 t.Parallel() 2140 v := TreeEntry{ 2141 SHA: Ptr(""), 2142 Path: Ptr(""), 2143 Mode: Ptr(""), 2144 Type: Ptr(""), 2145 Size: Ptr(0), 2146 Content: Ptr(""), 2147 URL: Ptr(""), 2148 } 2149 want := `github.TreeEntry{SHA:"", Path:"", Mode:"", Type:"", Size:0, Content:"", URL:""}` 2150 if got := v.String(); got != want { 2151 t.Errorf("TreeEntry.String = %v, want %v", got, want) 2152 } 2153 } 2154 2155 func TestUser_String(t *testing.T) { 2156 t.Parallel() 2157 v := User{ 2158 Login: Ptr(""), 2159 ID: Ptr(int64(0)), 2160 NodeID: Ptr(""), 2161 AvatarURL: Ptr(""), 2162 HTMLURL: Ptr(""), 2163 GravatarID: Ptr(""), 2164 Name: Ptr(""), 2165 Company: Ptr(""), 2166 Blog: Ptr(""), 2167 Location: Ptr(""), 2168 Email: Ptr(""), 2169 Hireable: Ptr(false), 2170 Bio: Ptr(""), 2171 TwitterUsername: Ptr(""), 2172 PublicRepos: Ptr(0), 2173 PublicGists: Ptr(0), 2174 Followers: Ptr(0), 2175 Following: Ptr(0), 2176 CreatedAt: &Timestamp{}, 2177 UpdatedAt: &Timestamp{}, 2178 SuspendedAt: &Timestamp{}, 2179 Type: Ptr(""), 2180 SiteAdmin: Ptr(false), 2181 TotalPrivateRepos: Ptr(int64(0)), 2182 OwnedPrivateRepos: Ptr(int64(0)), 2183 PrivateGists: Ptr(0), 2184 DiskUsage: Ptr(0), 2185 Collaborators: Ptr(0), 2186 TwoFactorAuthentication: Ptr(false), 2187 Plan: &Plan{}, 2188 LdapDn: Ptr(""), 2189 URL: Ptr(""), 2190 EventsURL: Ptr(""), 2191 FollowingURL: Ptr(""), 2192 FollowersURL: Ptr(""), 2193 GistsURL: Ptr(""), 2194 OrganizationsURL: Ptr(""), 2195 ReceivedEventsURL: Ptr(""), 2196 ReposURL: Ptr(""), 2197 StarredURL: Ptr(""), 2198 SubscriptionsURL: Ptr(""), 2199 RoleName: Ptr(""), 2200 Assignment: Ptr(""), 2201 } 2202 want := `github.User{Login:"", ID:0, NodeID:"", AvatarURL:"", HTMLURL:"", GravatarID:"", Name:"", Company:"", Blog:"", Location:"", Email:"", Hireable:false, Bio:"", TwitterUsername:"", PublicRepos:0, PublicGists:0, Followers:0, Following:0, CreatedAt:github.Timestamp{0001-01-01 00:00:00 +0000 UTC}, UpdatedAt:github.Timestamp{0001-01-01 00:00:00 +0000 UTC}, SuspendedAt:github.Timestamp{0001-01-01 00:00:00 +0000 UTC}, Type:"", SiteAdmin:false, TotalPrivateRepos:0, OwnedPrivateRepos:0, PrivateGists:0, DiskUsage:0, Collaborators:0, TwoFactorAuthentication:false, Plan:github.Plan{}, LdapDn:"", URL:"", EventsURL:"", FollowingURL:"", FollowersURL:"", GistsURL:"", OrganizationsURL:"", ReceivedEventsURL:"", ReposURL:"", StarredURL:"", SubscriptionsURL:"", RoleName:"", Assignment:""}` 2203 if got := v.String(); got != want { 2204 t.Errorf("User.String = %v, want %v", got, want) 2205 } 2206 } 2207 2208 func TestUserLDAPMapping_String(t *testing.T) { 2209 t.Parallel() 2210 v := UserLDAPMapping{ 2211 ID: Ptr(int64(0)), 2212 LDAPDN: Ptr(""), 2213 Login: Ptr(""), 2214 AvatarURL: Ptr(""), 2215 GravatarID: Ptr(""), 2216 Type: Ptr(""), 2217 SiteAdmin: Ptr(false), 2218 URL: Ptr(""), 2219 EventsURL: Ptr(""), 2220 FollowingURL: Ptr(""), 2221 FollowersURL: Ptr(""), 2222 GistsURL: Ptr(""), 2223 OrganizationsURL: Ptr(""), 2224 ReceivedEventsURL: Ptr(""), 2225 ReposURL: Ptr(""), 2226 StarredURL: Ptr(""), 2227 SubscriptionsURL: Ptr(""), 2228 } 2229 want := `github.UserLDAPMapping{ID:0, LDAPDN:"", Login:"", AvatarURL:"", GravatarID:"", Type:"", SiteAdmin:false, URL:"", EventsURL:"", FollowingURL:"", FollowersURL:"", GistsURL:"", OrganizationsURL:"", ReceivedEventsURL:"", ReposURL:"", StarredURL:"", SubscriptionsURL:""}` 2230 if got := v.String(); got != want { 2231 t.Errorf("UserLDAPMapping.String = %v, want %v", got, want) 2232 } 2233 } 2234 2235 func TestUserMigration_String(t *testing.T) { 2236 t.Parallel() 2237 v := UserMigration{ 2238 ID: Ptr(int64(0)), 2239 GUID: Ptr(""), 2240 State: Ptr(""), 2241 LockRepositories: Ptr(false), 2242 ExcludeAttachments: Ptr(false), 2243 URL: Ptr(""), 2244 CreatedAt: Ptr(""), 2245 UpdatedAt: Ptr(""), 2246 } 2247 want := `github.UserMigration{ID:0, GUID:"", State:"", LockRepositories:false, ExcludeAttachments:false, URL:"", CreatedAt:"", UpdatedAt:""}` 2248 if got := v.String(); got != want { 2249 t.Errorf("UserMigration.String = %v, want %v", got, want) 2250 } 2251 } 2252 2253 func TestUserStats_String(t *testing.T) { 2254 t.Parallel() 2255 v := UserStats{ 2256 TotalUsers: Ptr(0), 2257 AdminUsers: Ptr(0), 2258 SuspendedUsers: Ptr(0), 2259 } 2260 want := `github.UserStats{TotalUsers:0, AdminUsers:0, SuspendedUsers:0}` 2261 if got := v.String(); got != want { 2262 t.Errorf("UserStats.String = %v, want %v", got, want) 2263 } 2264 } 2265 2266 func TestWeeklyCommitActivity_String(t *testing.T) { 2267 t.Parallel() 2268 v := WeeklyCommitActivity{ 2269 Days: []int{0}, 2270 Total: Ptr(0), 2271 Week: &Timestamp{}, 2272 } 2273 want := `github.WeeklyCommitActivity{Days:[0], Total:0, Week:github.Timestamp{0001-01-01 00:00:00 +0000 UTC}}` 2274 if got := v.String(); got != want { 2275 t.Errorf("WeeklyCommitActivity.String = %v, want %v", got, want) 2276 } 2277 } 2278 2279 func TestWeeklyStats_String(t *testing.T) { 2280 t.Parallel() 2281 v := WeeklyStats{ 2282 Week: &Timestamp{}, 2283 Additions: Ptr(0), 2284 Deletions: Ptr(0), 2285 Commits: Ptr(0), 2286 } 2287 want := `github.WeeklyStats{Week:github.Timestamp{0001-01-01 00:00:00 +0000 UTC}, Additions:0, Deletions:0, Commits:0}` 2288 if got := v.String(); got != want { 2289 t.Errorf("WeeklyStats.String = %v, want %v", got, want) 2290 } 2291 }