MCPcopy
hub / github.com/kopia/kopia / mustGetLineContaining

Function mustGetLineContaining

cli/command_cache_set_test.go:51–63  ·  view source on GitHub ↗
(t *testing.T, lines []string, containing string)

Source from the content-addressed store, hash-verified

49}
50
51func mustGetLineContaining(t *testing.T, lines []string, containing string) string {
52 t.Helper()
53
54 for _, l := range lines {
55 if strings.Contains(l, containing) {
56 return l
57 }
58 }
59
60 t.Fatalf("no line containing %q found in %v", containing, lines)
61
62 return ""
63}

Callers 3

TestCacheSetFunction · 0.85
TestContentVerifyMethod · 0.85
TestCacheClearSyncFunction · 0.85

Calls 3

HelperMethod · 0.80
FatalfMethod · 0.80
ContainsMethod · 0.45

Tested by

no test coverage detected