[lxml-dev] running the tests on the trunk
Hi there, I have trouble running the tests on the current trunk of lxml: Ran 556 tests in 2.333s FAILED (failures=1, errors=7) A lot of this seems to have to do with this attribute error while running the tests: AttributeError: 'module' object has no attribute 'iterparse' What's going on? Regards, Martijn
Martijn Faassen wrote:
Hi there,
I have trouble running the tests on the current trunk of lxml:
Ran 556 tests in 2.333s
FAILED (failures=1, errors=7)
A lot of this seems to have to do with this attribute error while running the tests:
AttributeError: 'module' object has no attribute 'iterparse'
What's going on?
I think I figured it out: I need to upgrade my version of *ElementTree*. Regards, Martijn
Martijn Faassen wrote:
Martijn Faassen wrote:
What's going on?
I think I figured it out: I need to upgrade my version of *ElementTree*.
Yup, that eliminated most problems, except for this failure in the doctests: File "/home/faassen/working/lxml-trunk/src/lxml/tests/../../../doc/resolvers.txt", line 153, in resolvers.txt ---------------------------------------------------------------------- File "/home/faassen/working/lxml-trunk/src/lxml/tests/../../../doc/resolvers.txt", line 153, in resolvers.txt Failed example: result = transform(honk_doc) Expected: Resolving url hoi:test as prefix honk ... failed Resolving url hoi:test as prefix hoi ... done Got: Resolving url hoi:test as prefix hoi ... done ---------------------------------------------------------------------- File "/home/faassen/working/lxml-trunk/src/lxml/tests/../../../doc/resolvers.txt", line 165, in resolvers.txt Failed example: result = transform(normal_doc) Expected: Resolving url hoi:test as prefix honk ... failed Resolving url hoi:test as prefix hoi ... done Got: Resolving url hoi:test as prefix hoi ... done ---------------------------------------------------------------------- File "/home/faassen/working/lxml-trunk/src/lxml/tests/../../../doc/resolvers.txt", line 192, in resolvers.txt Failed example: transform = etree.XSLT(honk_doc) Expected: Resolving url honk:test as prefix honk ... done Got: Resolving url honk:test as prefix hoi ... failed Resolving url honk:test as prefix honk ... done ---------------------------------------------------------------------- File "/home/faassen/working/lxml-trunk/src/lxml/tests/../../../doc/resolvers.txt", line 194, in resolvers.txt Failed example: result = transform(normal_doc) Expected: Resolving url hoi:test as prefix honk ... failed Resolving url hoi:test as prefix hoi ... done Got: Resolving url hoi:test as prefix hoi ... done ---------------------------------------------------------------------- File "/home/faassen/working/lxml-trunk/src/lxml/tests/../../../doc/resolvers.txt", line 199, in resolvers.txt Failed example: transform = etree.XSLT(honk_doc, access_control=ac) Expected: Resolving url honk:test as prefix honk ... done Got: Resolving url honk:test as prefix hoi ... failed Resolving url honk:test as prefix honk ... done
Martijn Faassen wrote:
that eliminated most problems, except for this failure in the doctests:
File "/home/faassen/working/lxml-trunk/src/lxml/tests/../../../doc/resolvers.txt", line 153, in resolvers.txt
---------------------------------------------------------------------- File "/home/faassen/working/lxml-trunk/src/lxml/tests/../../../doc/resolvers.txt", line 153, in resolvers.txt Failed example: result = transform(honk_doc) Expected: Resolving url hoi:test as prefix honk ... failed Resolving url hoi:test as prefix hoi ... done Got: Resolving url hoi:test as prefix hoi ... done ---------------------------------------------------------------------- [snip]
Ah, right. It's the tests that are broken here. I forgot that the resolvers are stored in a set and thus tested in arbitrary order (interesting that no one ever reported that for 1.0). So here they seem to use a different order that leads to different output. Guess I'll have to fix the tests here. Maybe the best way is to only let the resolver speak that succeeds, not the failed one(s) that were also tested. Stefan
participants (2)
-
Martijn Faassen
-
Stefan Behnel