MCPcopy Index your code
hub / github.com/google/go-github / TestCommit_String

Function TestCommit_String

github/github-stringify_test.go:399–417  ·  view source on GitHub ↗
(t *testing.T)

Source from the content-addressed store, hash-verified

397}
398
399func TestCommit_String(t *testing.T) {
400 t.Parallel()
401 v := Commit{
402 SHA: Ptr(""),
403 Author: &CommitAuthor{},
404 Committer: &CommitAuthor{},
405 Message: Ptr(""),
406 Tree: &Tree{},
407 HTMLURL: Ptr(""),
408 URL: Ptr(""),
409 Verification: &SignatureVerification{},
410 NodeID: Ptr(""),
411 CommentCount: Ptr(0),
412 }
413 want := `github.Commit{SHA:"", Author:github.CommitAuthor{}, Committer:github.CommitAuthor{}, Message:"", Tree:github.Tree{}, HTMLURL:"", URL:"", Verification:github.SignatureVerification{}, NodeID:"", CommentCount:0}`
414 if got := v.String(); got != want {
415 t.Errorf("Commit.String = %v, want %v", got, want)
416 }
417}
418
419func TestCommitAuthor_String(t *testing.T) {
420 t.Parallel()

Callers

nothing calls this directly

Calls 2

StringMethod · 0.95
PtrFunction · 0.70

Tested by

no test coverage detected

Used in the wild real call sites across dependent graphs

searching dependent graphs…