MCPcopy Create free account
hub / github.com/LegacyCodeHQ/clarity-cli / TestGetCommitRangeLabel_InvalidFromCommit

Function TestGetCommitRangeLabel_InvalidFromCommit

vcs/git/git_test.go:496–507  ·  view source on GitHub ↗
(t *testing.T)

Source from the content-addressed store, hash-verified

494}
495
496func TestGetCommitRangeLabel_InvalidFromCommit(t *testing.T) {
497 tmpDir := t.TempDir()
498 setupGitRepo(t, tmpDir)
499
500 createFile(t, tmpDir, "test.txt", "content")
501 gitAdd(t, tmpDir, "test.txt")
502 commit := gitCommitAndGetSHA(t, tmpDir, "Commit")
503
504 _, err := GetCommitRangeLabel(tmpDir, "invalid-sha", commit)
505
506 assert.Error(t, err)
507}
508
509func TestGetCommitRangeLabel_InvalidToCommit(t *testing.T) {
510 tmpDir := t.TempDir()

Callers

nothing calls this directly

Calls 5

setupGitRepoFunction · 0.85
createFileFunction · 0.85
gitAddFunction · 0.85
gitCommitAndGetSHAFunction · 0.85
GetCommitRangeLabelFunction · 0.85

Tested by

no test coverage detected