(t *testing.T)
| 288 | } |
| 289 | |
| 290 | func TestGetRootElement(t *testing.T) { |
| 291 | assert.Len(t, getRootElement(xml.NewDecoder(strings.NewReader(""))), 0) |
| 292 | // Test get workbook root element which all workbook XML namespace has prefix |
| 293 | f := NewFile() |
| 294 | d := f.xmlNewDecoder(bytes.NewReader([]byte(`<x:workbook xmlns:r="http://schemas.openxmlformats.org/officeDocument/2006/relationships" xmlns:x="http://schemas.openxmlformats.org/spreadsheetml/2006/main"></x:workbook>`))) |
| 295 | assert.Len(t, getRootElement(d), 3) |
| 296 | } |
| 297 | |
| 298 | func TestSetIgnorableNameSpace(t *testing.T) { |
| 299 | f := NewFile() |
nothing calls this directly
no test coverage detected