diff options
author | xuri <xuri.me@gmail.com> | 2021-07-05 00:03:56 +0800 |
---|---|---|
committer | xuri <xuri.me@gmail.com> | 2021-07-05 00:03:56 +0800 |
commit | 544ef18a8cb9949fcb8833c6d2816783c90f3318 (patch) | |
tree | 88bb3eaa9d92522d3b5c4eeb052210c26bc4c99f /sheetpr_test.go | |
parent | 0e02329bedf6648259fd219642bb907bdb07fd21 (diff) |
- Support concurrency iterate rows and columns
- Rename exported field `File.XLSX` to `File.Pkg`
- Exported error message
Diffstat (limited to 'sheetpr_test.go')
-rw-r--r-- | sheetpr_test.go | 8 |
1 files changed, 6 insertions, 2 deletions
diff --git a/sheetpr_test.go b/sheetpr_test.go index 42e2e0d..53532e9 100644 --- a/sheetpr_test.go +++ b/sheetpr_test.go @@ -443,7 +443,9 @@ func TestSheetFormatPrOptions(t *testing.T) { func TestSetSheetFormatPr(t *testing.T) { f := NewFile() assert.NoError(t, f.GetSheetFormatPr("Sheet1")) - f.Sheet["xl/worksheets/sheet1.xml"].SheetFormatPr = nil + ws, ok := f.Sheet.Load("xl/worksheets/sheet1.xml") + assert.True(t, ok) + ws.(*xlsxWorksheet).SheetFormatPr = nil assert.NoError(t, f.SetSheetFormatPr("Sheet1", BaseColWidth(1.0))) // Test set formatting properties on not exists worksheet. assert.EqualError(t, f.SetSheetFormatPr("SheetN"), "sheet SheetN is not exist") @@ -452,7 +454,9 @@ func TestSetSheetFormatPr(t *testing.T) { func TestGetSheetFormatPr(t *testing.T) { f := NewFile() assert.NoError(t, f.GetSheetFormatPr("Sheet1")) - f.Sheet["xl/worksheets/sheet1.xml"].SheetFormatPr = nil + ws, ok := f.Sheet.Load("xl/worksheets/sheet1.xml") + assert.True(t, ok) + ws.(*xlsxWorksheet).SheetFormatPr = nil var ( baseColWidth BaseColWidth defaultColWidth DefaultColWidth |