Skip to content
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

Fix chart core tests #685

Closed
wimjongman opened this issue Nov 2, 2021 · 1 comment · Fixed by #686 or #763
Closed

Fix chart core tests #685

wimjongman opened this issue Nov 2, 2021 · 1 comment · Fixed by #686 or #763
Assignees
Milestone

Comments

@wimjongman
Copy link
Contributor

wimjongman commented Nov 2, 2021

The chart core tests require some magic to happen. See PR.

@wimjongman wimjongman self-assigned this Nov 2, 2021
@wimjongman wimjongman added this to the 4.9 milestone Nov 2, 2021
wimjongman added a commit that referenced this issue Nov 2, 2021
Added fragment to provide dependency [1]
Fixed some Locale dependent tests


[1]
The chart core tests were failing due to an incompatible
java/osgi construct in org.apache.batik.transcoder.

The transcoder "bundle" is doing a Class.forname(String)
on a class that is not listed as a dependency.

This happens in class
org.apache.batik.transcoder.image.PNGTranscoder#getWriteAdapter
which is looking for
"org.apache.batik.ext.awt.image.codec.png.PNGTranscoderInternalCodecWriteAdapter"

To fool this "bundle", a fragment bundle is introduced with
o.a.b.transcoder as the master plugin that depends on the
"org.apache.batik.codec" bundle and in this way provides the dependency.
@wimjongman wimjongman linked a pull request Nov 2, 2021 that will close this issue
wimjongman added a commit that referenced this issue Nov 2, 2021
Added fragment to provide dependency [1]
Fixed some Locale dependent tests


[1]
The chart core tests were failing due to an incompatible
java/osgi construct in org.apache.batik.transcoder.

The transcoder "bundle" is doing a Class.forname(String)
on a class that is not listed as a dependency.

This happens in class
org.apache.batik.transcoder.image.PNGTranscoder#getWriteAdapter
which is looking for
"org.apache.batik.ext.awt.image.codec.png.PNGTranscoderInternalCodecWriteAdapter"

To fool this "bundle", a fragment bundle is introduced with
o.a.b.transcoder as the master plugin that depends on the
"org.apache.batik.codec" bundle and in this way provides the dependency.
wimjongman added a commit that referenced this issue Nov 2, 2021
Added fragment to provide dependency [1]
Fixed some Locale dependent tests


[1]
The chart core tests were failing due to an incompatible
java/osgi construct in org.apache.batik.transcoder.

The transcoder "bundle" is doing a Class.forname(String)
on a class that is not listed as a dependency.

This happens in class
org.apache.batik.transcoder.image.PNGTranscoder#getWriteAdapter
which is looking for
"org.apache.batik.ext.awt.image.codec.png.PNGTranscoderInternalCodecWriteAdapter"

To fool this "bundle", a fragment bundle is introduced with
o.a.b.transcoder as the master plugin that depends on the
"org.apache.batik.codec" bundle and in this way provides the dependency.

Also added batik.w3c.dom as pkg dependency to the same
wimjongman added a commit that referenced this issue Nov 2, 2021
Added fragment to provide dependency [1]
Fixed some Locale dependent tests


[1]
The chart core tests were failing due to an incompatible
java/osgi construct in org.apache.batik.transcoder.

The transcoder "bundle" is doing a Class.forname(String)
on a class that is not listed as a dependency.

This happens in class
org.apache.batik.transcoder.image.PNGTranscoder#getWriteAdapter
which is looking for
"org.apache.batik.ext.awt.image.codec.png.PNGTranscoderInternalCodecWriteAdapter"

To fool this "bundle", a fragment bundle is introduced with
o.a.b.transcoder as the master plugin that depends on the
"org.apache.batik.codec" bundle and in this way provides the dependency.

An identical trick was pulled adding batik.w3c.dom as pkg dependency
to org.apache.batik.dom
wimjongman added a commit that referenced this issue Nov 11, 2021
Added fragment to provide dependency [1]
Fixed some Locale dependent tests


[1]
The chart core tests were failing due to an incompatible
java/osgi construct in org.apache.batik.transcoder.

The transcoder "bundle" is doing a Class.forname(String)
on a class that is not listed as a dependency.

This happens in class
org.apache.batik.transcoder.image.PNGTranscoder#getWriteAdapter
which is looking for
"org.apache.batik.ext.awt.image.codec.png.PNGTranscoderInternalCodecWriteAdapter"

To fool this "bundle", a fragment bundle is introduced with
o.a.b.transcoder as the master plugin that depends on the
"org.apache.batik.codec" bundle and in this way provides the dependency.
wimjongman added a commit that referenced this issue Nov 11, 2021
Added fragment to provide dependency [1]
Fixed some Locale dependent tests


[1]
The chart core tests were failing due to an incompatible
java/osgi construct in org.apache.batik.transcoder.

The transcoder "bundle" is doing a Class.forname(String)
on a class that is not listed as a dependency.

This happens in class
org.apache.batik.transcoder.image.PNGTranscoder#getWriteAdapter
which is looking for
"org.apache.batik.ext.awt.image.codec.png.PNGTranscoderInternalCodecWriteAdapter"

To fool this "bundle", a fragment bundle is introduced with
o.a.b.transcoder as the master plugin that depends on the
"org.apache.batik.codec" bundle and in this way provides the dependency.
wimjongman added a commit that referenced this issue Nov 11, 2021
Added fragment to provide dependency [1]
Fixed some Locale dependent tests


[1]
The chart core tests were failing due to an incompatible
java/osgi construct in org.apache.batik.transcoder.

The transcoder "bundle" is doing a Class.forname(String)
on a class that is not listed as a dependency.

This happens in class
org.apache.batik.transcoder.image.PNGTranscoder#getWriteAdapter
which is looking for
"org.apache.batik.ext.awt.image.codec.png.PNGTranscoderInternalCodecWriteAdapter"

To fool this "bundle", a fragment bundle is introduced with
o.a.b.transcoder as the master plugin that depends on the
"org.apache.batik.codec" bundle and in this way provides the dependency.

Also added batik.w3c.dom as pkg dependency to the same
wimjongman added a commit that referenced this issue Nov 11, 2021
Added fragment to provide dependency [1]
Fixed some Locale dependent tests


[1]
The chart core tests were failing due to an incompatible
java/osgi construct in org.apache.batik.transcoder.

The transcoder "bundle" is doing a Class.forname(String)
on a class that is not listed as a dependency.

This happens in class
org.apache.batik.transcoder.image.PNGTranscoder#getWriteAdapter
which is looking for
"org.apache.batik.ext.awt.image.codec.png.PNGTranscoderInternalCodecWriteAdapter"

To fool this "bundle", a fragment bundle is introduced with
o.a.b.transcoder as the master plugin that depends on the
"org.apache.batik.codec" bundle and in this way provides the dependency.

An identical trick was pulled adding batik.w3c.dom as pkg dependency
to org.apache.batik.dom
wimjongman added a commit that referenced this issue Nov 11, 2021
Added o.a.batik.dom.birt.ext to birt feature

This is a fragment extending batik.dom so that
it can see org.apache.batik.w3c.dom

It solves the following dependency issue:

java.lang.NoClassDefFoundError:
org/apache/batik/w3c/dom/ElementTraversal
	at org.eclipse.birt.chart.tests.device.render.ImageOutputBaseTest.runTest(ImageOutputBaseTest.java:100)
Caused by: java.lang.ClassNotFoundException:
org.apache.batik.w3c.dom.ElementTraversal cannot be found by
org.apache.batik.dom_1.14.0.v20210324-0332
	at org.eclipse.birt.chart.tests.device.render.ImageOutputBaseTest.runTest(ImageOutputBaseTest.java:100)
wimjongman added a commit that referenced this issue Nov 11, 2021
Added o.a.batik.dom.birt.ext to birt feature

Added batik.ext 1.14 to target

This is a fragment extending batik.dom so that
it can see org.apache.batik.w3c.dom

It solves the following dependency issue:

java.lang.NoClassDefFoundError:
org/apache/batik/w3c/dom/ElementTraversal
	at org.eclipse.birt.chart.tests.device.render.ImageOutputBaseTest.runTest(ImageOutputBaseTest.java:100)
Caused by: java.lang.ClassNotFoundException:
org.apache.batik.w3c.dom.ElementTraversal cannot be found by
org.apache.batik.dom_1.14.0.v20210324-0332
	at org.eclipse.birt.chart.tests.device.render.ImageOutputBaseTest.runTest(ImageOutputBaseTest.java:100)
wimjongman added a commit that referenced this issue Nov 11, 2021
Added o.a.batik.dom.birt.ext to birt feature

Added batik.ext 1.14 to target

This is a fragment extending batik.dom so that
it can see org.apache.batik.w3c.dom

It solves the following dependency issue:

java.lang.NoClassDefFoundError:
org/apache/batik/w3c/dom/ElementTraversal
	at org.eclipse.birt.chart.tests.device.render.ImageOutputBaseTest.runTest(ImageOutputBaseTest.java:100)
Caused by: java.lang.ClassNotFoundException:
org.apache.batik.w3c.dom.ElementTraversal cannot be found by
org.apache.batik.dom_1.14.0.v20210324-0332
	at org.eclipse.birt.chart.tests.device.render.ImageOutputBaseTest.runTest(ImageOutputBaseTest.java:100)
wimjongman added a commit that referenced this issue Nov 11, 2021
Added o.a.batik.dom.birt.ext to birt feature

Added batik.ext 1.14 to target

This is a fragment extending batik.dom so that
it can see org.apache.batik.w3c.dom

It solves the following dependency issue:

java.lang.NoClassDefFoundError:
org/apache/batik/w3c/dom/ElementTraversal
	at org.eclipse.birt.chart.tests.device.render.ImageOutputBaseTest.runTest(ImageOutputBaseTest.java:100)
Caused by: java.lang.ClassNotFoundException:
org.apache.batik.w3c.dom.ElementTraversal cannot be found by
org.apache.batik.dom_1.14.0.v20210324-0332
	at org.eclipse.birt.chart.tests.device.render.ImageOutputBaseTest.runTest(ImageOutputBaseTest.java:100)
wimjongman added a commit that referenced this issue Nov 12, 2021
Added o.a.batik.dom.birt.ext to birt feature

Added batik.ext 1.14 to target

This is a fragment extending batik.dom so that
it can see org.apache.batik.w3c.dom

It solves the following dependency issue:

java.lang.NoClassDefFoundError:
org/apache/batik/w3c/dom/ElementTraversal
	at org.eclipse.birt.chart.tests.device.render.ImageOutputBaseTest.runTest(ImageOutputBaseTest.java:100)
Caused by: java.lang.ClassNotFoundException:
org.apache.batik.w3c.dom.ElementTraversal cannot be found by
org.apache.batik.dom_1.14.0.v20210324-0332
	at org.eclipse.birt.chart.tests.device.render.ImageOutputBaseTest.runTest(ImageOutputBaseTest.java:100)
wimjongman added a commit that referenced this issue Nov 12, 2021
Added o.a.batik.dom.birt.ext to birt feature

Added batik.ext 1.14 to target

Disable the test so that it can at least run locally.

This is a fragment extending batik.dom so that
it can see org.apache.batik.w3c.dom

It solves the following dependency issue:

java.lang.NoClassDefFoundError:
org/apache/batik/w3c/dom/ElementTraversal
	at org.eclipse.birt.chart.tests.device.render.ImageOutputBaseTest.runTest(ImageOutputBaseTest.java:100)
Caused by: java.lang.ClassNotFoundException:
org.apache.batik.w3c.dom.ElementTraversal cannot be found by
org.apache.batik.dom_1.14.0.v20210324-0332
	at org.eclipse.birt.chart.tests.device.render.ImageOutputBaseTest.runTest(ImageOutputBaseTest.java:100)
@wimjongman
Copy link
Contributor Author

I can't get this to work in CI but the tests are running locally. For now, I have disabled the test in the workflow.

I suggest taking the code as it is and trying to fix it for CI later.

wimjongman added a commit that referenced this issue Nov 12, 2021
Added o.a.batik.dom.birt.ext to birt feature

Added batik.ext 1.14 to target

Disable the test so that it can at least run locally.

This is a fragment extending batik.dom so that
it can see org.apache.batik.w3c.dom

It solves the following dependency issue:

java.lang.NoClassDefFoundError:
org/apache/batik/w3c/dom/ElementTraversal
	at org.eclipse.birt.chart.tests.device.render.ImageOutputBaseTest.runTest(ImageOutputBaseTest.java:100)
Caused by: java.lang.ClassNotFoundException:
org.apache.batik.w3c.dom.ElementTraversal cannot be found by
org.apache.batik.dom_1.14.0.v20210324-0332
	at org.eclipse.birt.chart.tests.device.render.ImageOutputBaseTest.runTest(ImageOutputBaseTest.java:100)
wimjongman added a commit that referenced this issue Nov 13, 2021
The chart core tests were failing due to an incompatible
java/osgi construct in org.apache.batik.transcoder.

The transcoder "bundle" is doing a Class.forname(String)
on a class that is not listed as a dependency.

This happens in class
org.apache.batik.transcoder.image.PNGTranscoder#getWriteAdapter
which is looking for
"org.apache.batik.ext.awt.image.codec.png.PNGTranscoderInternalCodecWriteAdapter"

To fool this "bundle", a fragment bundle is introduced with
o.a.b.transcoder as the master plugin that depends on the
"org.apache.batik.codec" bundle and in this way provides the dependency.
@wimjongman wimjongman linked a pull request Dec 2, 2021 that will close this issue
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 a pull request may close this issue.

1 participant