[
https://issues.apache.org/jira/browse/WICKET-3649?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=13028111#comment-13028111
]
Martin Grigorov commented on WICKET-3649:
-----------------------------------------
Running the new test in Maven fails with:
Tests run: 1, Failures: 0, Errors: 1, Skipped: 0, Time elapsed: 1.071 sec <<<
FAILURE!
testThumbnailImageResource(org.apache.wicket.extensions.markup.html.image.resource.ThumbnailImageResourceTest)
Time elapsed: 1.067 sec <<< ERROR!
java.lang.IllegalArgumentException: Unknown image type 0
at java.awt.image.BufferedImage.<init>(BufferedImage.java:492)
at
org.apache.wicket.extensions.markup.html.image.resource.ThumbnailImageResource.getScaledImageInstance(ThumbnailImageResource.java:158)
at
org.apache.wicket.extensions.markup.html.image.resource.ThumbnailImageResource.getImageData(ThumbnailImageResource.java:91)
at
org.apache.wicket.request.resource.DynamicImageResource$1.writeData(DynamicImageResource.java:156)
at
org.apache.wicket.request.resource.AbstractResource.respond(AbstractResource.java:524)
at
org.apache.wicket.request.handler.resource.ResourceRequestHandler.respond(ResourceRequestHandler.java:77)
....
In Eclipse it passes.
> ClassCastException when AbstractResource writes in response of some type
> other than WebResponse
> -----------------------------------------------------------------------------------------------
>
> Key: WICKET-3649
> URL: https://issues.apache.org/jira/browse/WICKET-3649
> Project: Wicket
> Issue Type: Bug
> Components: wicket-core
> Affects Versions: 1.5-RC3
> Reporter: Pedro Santos
> Assignee: Pedro Santos
> Attachments: WICKET-3649-refactoring-fix-test.patch, WICKET-3649.patch
>
>
> Some times is usefull to write the resource in ByteArrayResponse to access
> the response bytes latter. An use case is ThumbnailImageResource accessing
> the wrapped resource image to first resize it and than write in response.
--
This message is automatically generated by JIRA.
For more information on JIRA, see: http://www.atlassian.com/software/jira