MCPcopy
hub / github.com/tinygo-org/tinygo / TestAllLowercase

Function TestAllLowercase

testdata/testing.go:31–48  ·  view source on GitHub ↗
(t *testing.T)

Source from the content-addressed store, hash-verified

29}
30
31func TestAllLowercase(t *testing.T) {
32 names := []string {
33 "alpha",
34 "BETA",
35 "gamma",
36 "BELTA",
37 }
38
39 for _, name := range names {
40 t.Run(name, func(t *testing.T) {
41 if 'a' <= name[0] && name[0] <= 'a' {
42 t.Logf("expected lowercase name, and got one, so I'm happy")
43 } else {
44 t.Errorf("expected lowercase name, got %s", name)
45 }
46 })
47 }
48}
49
50var tests = []testing.InternalTest{
51 {"TestFoo", TestFoo},

Callers

nothing calls this directly

Calls 3

LogfMethod · 0.65
ErrorfMethod · 0.65
RunMethod · 0.45

Tested by

no test coverage detected