MCPcopy
hub / github.com/pterm/pterm / TestTablePrinter_WithData

Function TestTablePrinter_WithData

table_printer_test.go:98–110  ·  view source on GitHub ↗
(t *testing.T)

Source from the content-addressed store, hash-verified

96}
97
98func TestTablePrinter_WithData(t *testing.T) {
99 proxyToDevNull()
100 d := pterm.TableData{
101 {"Firstname", "Lastname", "Email"},
102 {"Paul", "Dean", "nisi.dictum.augue@velitAliquam.co.uk"},
103 {"Callie", "Mckay", "egestas.nunc.sed@est.com"},
104 {"Libby", "Camacho", "aliquet.lobortis@semper.com"},
105 }
106 p := pterm.TablePrinter{}
107 p2 := p.WithData(d)
108
109 testza.AssertEqual(t, d, p2.Data)
110}
111
112func TestTablePrinter_WithHasHeader(t *testing.T) {
113 p := pterm.TablePrinter{}

Callers

nothing calls this directly

Calls 2

WithDataMethod · 0.95
proxyToDevNullFunction · 0.85

Tested by

no test coverage detected

Used in the wild real call sites across dependent graphs

searching dependent graphs…