MCPcopy Create free account
hub / github.com/cogentcore/core / TestSlicePlotEditor

Function TestSlicePlotEditor

plot/plotcore/ploteditor_test.go:37–52  ·  view source on GitHub ↗
(t *testing.T)

Source from the content-addressed store, hash-verified

35}
36
37func TestSlicePlotEditor(t *testing.T) {
38 data := []Data{
39 {"Davis", 62000, 500},
40 {"Boulder", 85000, 800},
41 }
42
43 b := core.NewBody()
44
45 pl := NewPlotEditor(b)
46 pl.Options.Title = "Slice Data"
47 pl.Options.Points = true
48 pl.SetSlice(data)
49 b.AddAppBar(pl.MakeToolbar)
50
51 b.AssertRender(t, "slice")
52}

Callers

nothing calls this directly

Calls 5

SetSliceMethod · 0.95
AddAppBarMethod · 0.95
AssertRenderMethod · 0.95
NewBodyFunction · 0.92
NewPlotEditorFunction · 0.85

Tested by

no test coverage detected