MCPcopy
hub / github.com/spf13/cobra / checkStringContains

Function checkStringContains

command_test.go:74–78  ·  view source on GitHub ↗
(t *testing.T, got, expected string)

Source from the content-addressed store, hash-verified

72}
73
74func checkStringContains(t *testing.T, got, expected string) {
75 if !strings.Contains(got, expected) {
76 t.Errorf("Expected to contain: \n %v\nGot:\n %v\n", expected, got)
77 }
78}
79
80func checkStringOmits(t *testing.T, got, expected string) {
81 if strings.Contains(got, expected) {

Callers 15

TestPluginFunction · 0.70
TestFlagInvalidInputFunction · 0.70
TestHelpCommandExecutedFunction · 0.70
TestHelpFlagExecutedFunction · 0.70
TestHelpFlagInHelpFunction · 0.70
TestFlagsInUsageFunction · 0.70
TestSetUsageTemplateFunction · 0.70

Calls

no outgoing calls

Tested by

no test coverage detected