You are viewing a plain text version of this content. The canonical link for it is here.
Posted to dev@myfaces.apache.org by "Simon Kitching (JIRA)" <de...@myfaces.apache.org> on 2005/11/08 23:02:20 UTC
[jira] Created: (MYFACES-799) Minor tweak to AddResource to make writing unit tests easier
Minor tweak to AddResource to make writing unit tests easier
------------------------------------------------------------
Key: MYFACES-799
URL: http://issues.apache.org/jira/browse/MYFACES-799
Project: MyFaces
Type: Improvement
Reporter: Simon Kitching
Priority: Minor
Currently the AddResource.writeWithFullHeader method takes an ExtensionResponseWrapper object as a parameter.
This makes calling this method from places other than the ExtensionsFilter difficult. In particular, it makes it difficult
to call this method from a unit test.
As the only thing done with this parameter is to convert it to a string, the attached patch changes this API to take a
plain string parameter instead (and changes ExtensionsFilter to match).
This also makes the writeWithFullHeader method less coupled to the ExtensionsFilter class, and generally simpler
to understand.
I hope you find this patch useful.
Regards, Simon
--
This message is automatically generated by JIRA.
-
If you think it was sent incorrectly contact one of the administrators:
http://issues.apache.org/jira/secure/Administrators.jspa
-
For more information on JIRA, see:
http://www.atlassian.com/software/jira
[jira] Closed: (MYFACES-799) Minor tweak to AddResource to make writing unit tests easier
Posted by "Martin Marinschek (JIRA)" <de...@myfaces.apache.org>.
[ http://issues.apache.org/jira/browse/MYFACES-799?page=all ]
Martin Marinschek closed MYFACES-799:
-------------------------------------
Fix Version: Nightly
Resolution: Fixed
Assign To: Martin Marinschek
Thanks to Simon Kitching.
> Minor tweak to AddResource to make writing unit tests easier
> ------------------------------------------------------------
>
> Key: MYFACES-799
> URL: http://issues.apache.org/jira/browse/MYFACES-799
> Project: MyFaces
> Type: Improvement
> Reporter: Simon Kitching
> Assignee: Martin Marinschek
> Priority: Minor
> Fix For: Nightly
> Attachments: AddResource.java.patch.txt, ExtensionsFilter.java.patch.txt
>
> Currently the AddResource.writeWithFullHeader method takes an ExtensionResponseWrapper object as a parameter.
> This makes calling this method from places other than the ExtensionsFilter difficult. In particular, it makes it difficult
> to call this method from a unit test.
> As the only thing done with this parameter is to convert it to a string, the attached patch changes this API to take a
> plain string parameter instead (and changes ExtensionsFilter to match).
> This also makes the writeWithFullHeader method less coupled to the ExtensionsFilter class, and generally simpler
> to understand.
> I hope you find this patch useful.
> Regards, Simon
--
This message is automatically generated by JIRA.
-
If you think it was sent incorrectly contact one of the administrators:
http://issues.apache.org/jira/secure/Administrators.jspa
-
For more information on JIRA, see:
http://www.atlassian.com/software/jira
[jira] Updated: (MYFACES-799) Minor tweak to AddResource to make writing unit tests easier
Posted by "Simon Kitching (JIRA)" <de...@myfaces.apache.org>.
[ http://issues.apache.org/jira/browse/MYFACES-799?page=all ]
Simon Kitching updated MYFACES-799:
-----------------------------------
Attachment: AddResource.java.patch.txt
ExtensionsFilter.java.patch.txt
Change to AddResource.writeWithFullHeader method. Note that this *is* a binary-incompatible change. However it is very unlikely that code
outside the MyFaces library is calling this method.
Also change ExtensionsFilter to match new API.
> Minor tweak to AddResource to make writing unit tests easier
> ------------------------------------------------------------
>
> Key: MYFACES-799
> URL: http://issues.apache.org/jira/browse/MYFACES-799
> Project: MyFaces
> Type: Improvement
> Reporter: Simon Kitching
> Priority: Minor
> Attachments: AddResource.java.patch.txt, ExtensionsFilter.java.patch.txt
>
> Currently the AddResource.writeWithFullHeader method takes an ExtensionResponseWrapper object as a parameter.
> This makes calling this method from places other than the ExtensionsFilter difficult. In particular, it makes it difficult
> to call this method from a unit test.
> As the only thing done with this parameter is to convert it to a string, the attached patch changes this API to take a
> plain string parameter instead (and changes ExtensionsFilter to match).
> This also makes the writeWithFullHeader method less coupled to the ExtensionsFilter class, and generally simpler
> to understand.
> I hope you find this patch useful.
> Regards, Simon
--
This message is automatically generated by JIRA.
-
If you think it was sent incorrectly contact one of the administrators:
http://issues.apache.org/jira/secure/Administrators.jspa
-
For more information on JIRA, see:
http://www.atlassian.com/software/jira