diff options
author | xuri <xuri.me@gmail.com> | 2021-09-18 23:20:24 +0800 |
---|---|---|
committer | xuri <xuri.me@gmail.com> | 2021-09-19 11:06:54 +0800 |
commit | 790c363cceaaa09e91ad579e2d25cb13c1582bba (patch) | |
tree | b5747f30edeac96a7fdadec574f1a5b1d332ca18 /cell_test.go | |
parent | 2add938798cdd1456616869298319528b0c76913 (diff) |
This closes #833, closes #845, and closes #1022, breaking changes
- Close spreadsheet and row's iterator required
- New options `WorksheetUnzipMemLimit` have been added
- Improve streaming reading performance, memory usage decrease about 93.7%
Diffstat (limited to 'cell_test.go')
-rw-r--r-- | cell_test.go | 4 |
1 files changed, 4 insertions, 0 deletions
diff --git a/cell_test.go b/cell_test.go index 5467e43..35eaa96 100644 --- a/cell_test.go +++ b/cell_test.go @@ -72,6 +72,7 @@ func TestConcurrency(t *testing.T) { } assert.Equal(t, "1", val) assert.NoError(t, f.SaveAs(filepath.Join("test", "TestConcurrency.xlsx"))) + assert.NoError(t, f.Close()) } func TestCheckCellInArea(t *testing.T) { @@ -325,6 +326,7 @@ func TestOverflowNumericCell(t *testing.T) { assert.NoError(t, err) // GOARCH=amd64 - all ok; GOARCH=386 - actual: "-2147483648" assert.Equal(t, "8595602512225", val, "A1 should be 8595602512225") + assert.NoError(t, f.Close()) } func TestSetCellFormula(t *testing.T) { @@ -340,6 +342,7 @@ func TestSetCellFormula(t *testing.T) { assert.EqualError(t, f.SetCellFormula("Sheet1", "C", "SUM(Sheet2!D2,Sheet2!D9)"), `cannot convert cell "C" to coordinates: invalid cell name "C"`) assert.NoError(t, f.SaveAs(filepath.Join("test", "TestSetCellFormula1.xlsx"))) + assert.NoError(t, f.Close()) f, err = OpenFile(filepath.Join("test", "CalcChain.xlsx")) if !assert.NoError(t, err) { @@ -351,6 +354,7 @@ func TestSetCellFormula(t *testing.T) { // Test remove all cell formula. assert.NoError(t, f.SetCellFormula("Sheet1", "B1", "")) assert.NoError(t, f.SaveAs(filepath.Join("test", "TestSetCellFormula3.xlsx"))) + assert.NoError(t, f.Close()) // Test set shared formula for the cells. f = NewFile() |