MCPcopy Index your code
hub / github.com/coder/coder / requireResultHasPath

Function requireResultHasPath

agent/filefinder/engine_test.go:26–34  ·  view source on GitHub ↗
(t *testing.T, results []filefinder.Result, path string)

Source from the content-addressed store, hash-verified

24}
25
26func requireResultHasPath(t *testing.T, results []filefinder.Result, path string) {
27 t.Helper()
28 for _, r := range results {
29 if r.Path == path {
30 return
31 }
32 }
33 t.Errorf("expected %q in results, got %v", path, resultPaths(results))
34}
35
36func TestEngine_SearchFindsKnownFile(t *testing.T) {
37 t.Parallel()

Callers

nothing calls this directly

Calls 3

resultPathsFunction · 0.85
HelperMethod · 0.65
ErrorfMethod · 0.45

Tested by

no test coverage detected