From c49e7aab306437f0e721620af4a24364edf4d601 Mon Sep 17 00:00:00 2001 From: xuri Date: Mon, 9 Aug 2021 22:22:43 +0800 Subject: Reduce cyclomatic complexities for the formula calculate function and update documentation for the API: `MergeCell` and `GetCellValue` --- lib_test.go | 4 ++++ 1 file changed, 4 insertions(+) (limited to 'lib_test.go') diff --git a/lib_test.go b/lib_test.go index 2e0e506..025bc85 100644 --- a/lib_test.go +++ b/lib_test.go @@ -237,6 +237,10 @@ func TestBytesReplace(t *testing.T) { assert.EqualValues(t, s, bytesReplace(s, []byte{}, []byte{}, 0)) } +func TestGetRootElement(t *testing.T) { + assert.Equal(t, 0, len(getRootElement(xml.NewDecoder(strings.NewReader(""))))) +} + func TestSetIgnorableNameSpace(t *testing.T) { f := NewFile() f.xmlAttr["xml_path"] = []xml.Attr{{}} -- cgit v1.2.1