From 87390cdd99b3afbe07daeef9abe96f57d03cb352 Mon Sep 17 00:00:00 2001 From: xuri Date: Thu, 24 Oct 2019 23:18:02 +0800 Subject: Resolve #511, allow empty columns in the pivot table --- pivotTable_test.go | 6 ++++++ 1 file changed, 6 insertions(+) (limited to 'pivotTable_test.go') diff --git a/pivotTable_test.go b/pivotTable_test.go index 27e5914..9bf08e8 100644 --- a/pivotTable_test.go +++ b/pivotTable_test.go @@ -54,6 +54,12 @@ func TestAddPivotTable(t *testing.T) { Columns: []string{"Region", "Year"}, Data: []string{"Sales"}, })) + assert.NoError(t, f.AddPivotTable(&PivotTableOption{ + DataRange: "Sheet1!$A$1:$E$31", + PivotTableRange: "Sheet1!$AE$2:$AG$33", + Rows: []string{"Month", "Year"}, + Data: []string{"Sales"}, + })) f.NewSheet("Sheet2") assert.NoError(t, f.AddPivotTable(&PivotTableOption{ DataRange: "Sheet1!$A$1:$E$31", -- cgit v1.2.1