MCPcopy
hub / github.com/perkeep/perkeep / testQueryTypes

Function testQueryTypes

pkg/search/query_test.go:105–113  ·  view source on GitHub ↗
(t testing.TB, types []indexType, fn func(*queryTest))

Source from the content-addressed store, hash-verified

103}
104
105func testQueryTypes(t testing.TB, types []indexType, fn func(*queryTest)) {
106 defer test.TLog(t)()
107 for _, it := range types {
108 if *queryType == "" || *queryType == it.String() {
109 t.Logf("Testing: --querytype=%s ...", it)
110 testQueryType(t, fn, it)
111 }
112 }
113}
114
115func testQueryType(t testing.TB, fn func(*queryTest), itype indexType) {
116 defer index.SetVerboseCorpusLogging(true)

Calls 4

TLogFunction · 0.92
testQueryTypeFunction · 0.85
LogfMethod · 0.80
StringMethod · 0.45

Tested by

no test coverage detected