diff options
Diffstat (limited to 'src/encoding/xml/xml_test.go')
| -rw-r--r-- | src/encoding/xml/xml_test.go | 2 |
1 files changed, 2 insertions, 0 deletions
diff --git a/src/encoding/xml/xml_test.go b/src/encoding/xml/xml_test.go index 4bec4e7f1e..2c985f7c70 100644 --- a/src/encoding/xml/xml_test.go +++ b/src/encoding/xml/xml_test.go @@ -1350,10 +1350,12 @@ func TestParseErrors(t *testing.T) { // Header-related errors. {`<?xml version="1.1" encoding="UTF-8"?>`, `unsupported version "1.1"; only version 1.0 is supported`}, + {`<foo><?xml version="1.0"?>`, `XML declaration after start of document`}, // Cases below are for "no errors". {withDefaultHeader(`<?ok?>`), ``}, {withDefaultHeader(`<?ok version="ok"?>`), ``}, + {` <?xml version="1.0"?>`, ``}, } for _, test := range tests { |
