Skip to content

Return buffered XML write errors - #139

Open
bensynapse wants to merge 1 commit into
antchfx:masterfrom
bensynapse:fix-buffered-write-errors
Open

bensynapse wants to merge 1 commit into
antchfx:masterfrom
bensynapse:fix-buffered-write-errors

Conversation

@bensynapse

Copy link
Copy Markdown

I run Live Tennis API.

Write and WriteWithOptions return nil when a short XML write fails during the final buffer flush. Return that error and preserve earlier serialization errors.

The tests cover document and element output, indentation, partial writes and successful writes. All 56 cases pass. On the original source, 21 cases for short output fail.

go test . -v -cover passes on Go 1.23 and 1.24, with 89.1% coverage. go vet ./... and go build ./... pass.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant