MCPcopy Index your code
hub / github.com/cli/cli / TestClientLastCommit

Function TestClientLastCommit

git/client_test.go:710–718  ·  view source on GitHub ↗
(t *testing.T)

Source from the content-addressed store, hash-verified

708}
709
710func TestClientLastCommit(t *testing.T) {
711 client := Client{
712 RepoDir: "./fixtures/simple.git",
713 }
714 c, err := client.LastCommit(context.Background())
715 assert.NoError(t, err)
716 assert.Equal(t, "6f1a2405cace1633d89a79c74c65f22fe78f9659", c.Sha)
717 assert.Equal(t, "Second commit", c.Title)
718}
719
720func TestClientCommitBody(t *testing.T) {
721 client := Client{

Callers

nothing calls this directly

Calls 2

LastCommitMethod · 0.95
EqualMethod · 0.80

Tested by

no test coverage detected