MCPcopy
hub / github.com/spf13/pflag / setUpTime

Function setUpTime

text_test.go:10–14  ·  view source on GitHub ↗
(t *time.Time)

Source from the content-addressed store, hash-verified

8)
9
10func setUpTime(t *time.Time) *FlagSet {
11 f := NewFlagSet("test", ContinueOnError)
12 f.TextVar(t, "time", time.Now(), "time stamp")
13 return f
14}
15
16func TestText(t *testing.T) {
17 testCases := []struct {

Callers 1

TestTextFunction · 0.85

Calls 2

TextVarMethod · 0.95
NewFlagSetFunction · 0.85

Tested by

no test coverage detected