mirror of
https://github.com/fumiama/go-docx.git
synced 2026-06-07 08:40:25 +08:00
feat: pack use io.Copy
This commit is contained in:
@@ -575,10 +575,13 @@ func TestMarshalDrawingStructure(t *testing.T) {
|
||||
nextPara := w.AddParagraph()
|
||||
nextPara.AddLink("google", `http://google.com`)
|
||||
|
||||
doc, err := marshal(w.Document)
|
||||
f, err := os.Create("test.xml")
|
||||
if err != nil {
|
||||
t.Fatal(err)
|
||||
}
|
||||
_, err = marshaller{data: w.Document}.WriteTo(f)
|
||||
if err != nil {
|
||||
t.Fatal(err)
|
||||
}
|
||||
os.WriteFile("test.xml", doc, 0644)
|
||||
t.Fail()
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user