New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

CommentLessSource throws Exception with >= XSLT 2.0 engine (As Saxon 9.8) #99

Closed
stoussaint opened this Issue Aug 25, 2017 · 7 comments

Comments

Projects
None yet
2 participants
@stoussaint

stoussaint commented Aug 25, 2017

Due to stylesheet explicitly targets version="1.0", using an engine that discontinued support of this version end up with an Exception.

So for instance we can't use matcher with ignoreComments() with Saxon >= 9.8. As a workaround we rely on DiffBuilder, providing a specific (fixed) Content wrapper.

Not sure it's easy to deal with the correct version as TransformerFactory don't provide such information.

Maybe XmlUnit could for that particular case, embrace version 2.0 for matcher convenience and provide a CommentLessSourceV1Compatibility to be use with DiffBuilder for old version. After all, 2.0 is released since 2007.

@bodewig bodewig added this to the 2.5.0 milestone Aug 26, 2017

bodewig added a commit that referenced this issue Aug 26, 2017

@bodewig

This comment has been minimized.

Show comment
Hide comment
@bodewig

bodewig Aug 26, 2017

Member

I've just pushed to a branch to see whether the build breaks for openjdk6 in Travis (I haven't got a JDK6 around myself anymore).

In either case it would probably be cleaner to make the version configurable, if the build passes for OpenJDK6 (and a similar change for XMLUnit.NET would pass as well), I'd be willing to make 2.0 the new default.

Member

bodewig commented Aug 26, 2017

I've just pushed to a branch to see whether the build breaks for openjdk6 in Travis (I haven't got a JDK6 around myself anymore).

In either case it would probably be cleaner to make the version configurable, if the build passes for OpenJDK6 (and a similar change for XMLUnit.NET would pass as well), I'd be willing to make 2.0 the new default.

@bodewig

This comment has been minimized.

Show comment
Hide comment
@bodewig

bodewig Aug 26, 2017

Member

all builds passed, so I'll make 2.0 the default

Member

bodewig commented Aug 26, 2017

all builds passed, so I'll make 2.0 the default

bodewig added a commit that referenced this issue Aug 26, 2017

bodewig added a commit to xmlunit/xmlunit.net that referenced this issue Aug 26, 2017

@bodewig bodewig closed this in 8c3871e Aug 26, 2017

@bodewig

This comment has been minimized.

Show comment
Hide comment
@bodewig

bodewig Aug 26, 2017

Member

I've published SNAPSHOTs for 2.5.0, it would be good if you could give them a try.

Member

bodewig commented Aug 26, 2017

I've published SNAPSHOTs for 2.5.0, it would be good if you could give them a try.

@bodewig bodewig added the matchers label Aug 26, 2017

bodewig added a commit to xmlunit/xmlunit.net that referenced this issue Aug 26, 2017

@stoussaint

This comment has been minimized.

Show comment
Hide comment
@stoussaint

stoussaint Aug 26, 2017

I just give a try, and it works well with full Matcher usage ! Greatly appreciate how this issue as been fixed, nice job !

stoussaint commented Aug 26, 2017

I just give a try, and it works well with full Matcher usage ! Greatly appreciate how this issue as been fixed, nice job !

@bodewig

This comment has been minimized.

Show comment
Hide comment
@bodewig

bodewig Aug 26, 2017

Member

Many thanks for testing, and for bringing it up in the first place.

Member

bodewig commented Aug 26, 2017

Many thanks for testing, and for bringing it up in the first place.

@bodewig

This comment has been minimized.

Show comment
Hide comment
@bodewig

bodewig Sep 3, 2017

Member

I've just release XMLUnit for Java 2.5.0, it should show up in Maven Central within the next few hours.

Member

bodewig commented Sep 3, 2017

I've just release XMLUnit for Java 2.5.0, it should show up in Maven Central within the next few hours.

@stoussaint

This comment has been minimized.

Show comment
Hide comment
@stoussaint

stoussaint Sep 5, 2017

Just switch to the release. Many thanks

stoussaint commented Sep 5, 2017

Just switch to the release. Many thanks

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