gorilla/feeds

Test failure on go tip

dchest opened this issue · 6 comments

https://travis-ci.org/gorilla/feeds/jobs/55587220

Diffs between "got" and "expected":

diff --git a/1.txt b/2.txt
index 4894da0..1f6f674 100644
--- a/1.txt
+++ b/2.txt
@@ -1,4 +1,4 @@
-               <?xml version="1.0" encoding="UTF-8"?><feed>
+               <?xml version="1.0" encoding="UTF-8"?><feed xmlns="http://www.w3.org/2005/Atom">
                  <title>jmoiron.net blog</title>
                  <id>http://jmoiron.net/blog</id>
                  <updated>2013-01-16T21:52:35-05:00</updated>

Do you think it's a bug in feeds, tests, or Go? I suspect these changes has something to do with it:

Sorry for taking so long to get to this, I've kind of neglected the feeds package....

This is because Go 1.5 / tip now supports the xmlns attribute.

Not sure of the best way to fix it, short of doing a proper XML diff and ignoring that element, or writing different tests for 1.5. Or not testing on 1.4 and earlier (which seems like a bit premature...)

I think just going for separate tests (via runtime.Version() or using
build flags) will probably do. Pre 1.4 builds are likely to be around for a
while in most current Linux distros (Ubuntu 15.04 is 1.3.1) so we should
try to keep it around. I'll take a look at updating the test shortly.

On Fri, Aug 7, 2015 at 1:33 PM Kamil Kisiel notifications@github.com
wrote:

Not sure of the best way to fix it, short of doing a proper XML diff and
ignoring that element, or writing different tests for 1.5. Or not testing
on 1.4 and earlier (which seems like a bit premature...)


Reply to this email directly or view it on GitHub
#16 (comment).

The weird thing is tests seem to be passing now with the go1.5 Rc...

That'd be due to this: golang/go@c0d6d33 (they reverted the changes)

Hence you can probably close it until we see a update to golang/go#11841 (I've subscribed to the issue on that)

Ah I see, makes sense. I haven't been following the XML story in encoding/xml since I've mostly been using https://github.com/beevik/etree

Good to know they're going to take a serious look at it though.