MCPcopy
hub / github.com/qax-os/excelize / TestAddDrawingChart

Function TestAddDrawingChart

chart_test.go:100–107  ·  view source on GitHub ↗
(t *testing.T)

Source from the content-addressed store, hash-verified

98}
99
100func TestAddDrawingChart(t *testing.T) {
101 f := NewFile()
102 assert.EqualError(t, f.addDrawingChart("SheetN", "", "", 0, 0, 0, nil), newCellNameToCoordinatesError("", newInvalidCellNameError("")).Error())
103
104 path := "xl/drawings/drawing1.xml"
105 f.Pkg.Store(path, MacintoshCyrillicCharset)
106 assert.EqualError(t, f.addDrawingChart("Sheet1", path, "A1", 0, 0, 0, &GraphicOptions{PrintObject: boolPtr(true), Locked: boolPtr(false)}), "XML syntax error on line 1: invalid UTF-8")
107}
108
109func TestAddSheetDrawingChart(t *testing.T) {
110 f := NewFile()

Callers

nothing calls this directly

Calls 6

addDrawingChartMethod · 0.95
NewFileFunction · 0.85
newInvalidCellNameErrorFunction · 0.85
boolPtrFunction · 0.85
ErrorMethod · 0.45

Tested by

no test coverage detected