summaryrefslogtreecommitdiff
path: root/stream_test.go
diff options
context:
space:
mode:
authorxuri <xuri.me@gmail.com>2022-10-13 00:02:53 +0800
committerxuri <xuri.me@gmail.com>2022-10-13 00:13:36 +0800
commit7363c1e3337c5f0d9c70cc8af7504b3f8c092ab4 (patch)
treeafe4236975d8144d0ffdd55fef7723b2a0295495 /stream_test.go
parent0e657c887bf505d62ce3bf685c518cd0ed7bc558 (diff)
Go 1.16 and later required, migration of deprecation package `ioutil`
- Improving performance for stream writer `SetRow` function, reduces memory usage over and speedup about 19% - Update dependencies module - Update GitHub workflow
Diffstat (limited to 'stream_test.go')
-rw-r--r--stream_test.go3
1 files changed, 1 insertions, 2 deletions
diff --git a/stream_test.go b/stream_test.go
index 91aa580..c399d63 100644
--- a/stream_test.go
+++ b/stream_test.go
@@ -3,7 +3,6 @@ package excelize
import (
"encoding/xml"
"fmt"
- "io/ioutil"
"math/rand"
"os"
"path/filepath"
@@ -95,7 +94,7 @@ func TestStreamWriter(t *testing.T) {
assert.NoError(t, streamWriter.rawData.Close())
assert.Error(t, streamWriter.Flush())
- streamWriter.rawData.tmp, err = ioutil.TempFile(os.TempDir(), "excelize-")
+ streamWriter.rawData.tmp, err = os.CreateTemp(os.TempDir(), "excelize-")
assert.NoError(t, err)
_, err = streamWriter.rawData.Reader()
assert.NoError(t, err)