diff options
author | Michael <mike.harris@cerner.com> | 2019-10-24 09:14:33 -0500 |
---|---|---|
committer | xuri <xuri.me@gmail.com> | 2019-10-24 22:14:33 +0800 |
commit | 9fe267ffcfa06545223160cdb8c35cd91163730e (patch) | |
tree | 4ddcf2eddd0c2b6b3533c17b99f7a9fff6db4bad /excelize_test.go | |
parent | e7581ebf3e14f096b6e2d56ed34d381b4af6d310 (diff) |
Pre-allocate some memory when reading files (#510)
Diffstat (limited to 'excelize_test.go')
-rw-r--r-- | excelize_test.go | 6 |
1 files changed, 6 insertions, 0 deletions
diff --git a/excelize_test.go b/excelize_test.go index 7b6b674..8d7e7f7 100644 --- a/excelize_test.go +++ b/excelize_test.go @@ -1278,3 +1278,9 @@ func fillCells(f *File, sheet string, colCount, rowCount int) { } } } + +func BenchmarkOpenFile(b *testing.B) { + for i := 0; i < b.N; i++ { + OpenFile(filepath.Join("test", "Book1.xlsx")) + } +} |