You are viewing a plain text version of this content. The canonical link for it is here.
Posted to dev@sling.apache.org by "Dan Klco (JIRA)" <ji...@apache.org> on 2012/10/01 14:57:07 UTC
[jira] [Created] (SLING-2611) MockResource Properties
Dan Klco created SLING-2611:
-------------------------------
Summary: MockResource Properties
Key: SLING-2611
URL: https://issues.apache.org/jira/browse/SLING-2611
Project: Sling
Issue Type: Improvement
Components: Testing
Affects Versions: Commons Testing 2.0.10
Reporter: Dan Klco
Priority: Minor
A useful feature for the MockResource testing class would be the ability to specify additional properties and return them when the MockResource is adapted into a ValueMap.
I use this on nearly every project I've been on to test services. I've attached a patch file which adds two methods:
addProperty - add a single key, value set
getProperties - returns the map of properties which can be modified
And then in the adaptTo method I just added all of the properties in the map into the returned ValueMap.
--
This message is automatically generated by JIRA.
If you think it was sent incorrectly, please contact your JIRA administrators
For more information on JIRA, see: http://www.atlassian.com/software/jira
[jira] [Updated] (SLING-2611) MockResource Properties
Posted by "Dan Klco (JIRA)" <ji...@apache.org>.
[ https://issues.apache.org/jira/browse/SLING-2611?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ]
Dan Klco updated SLING-2611:
----------------------------
Attachment: MockResource-Properties.diff
Attaching patch file
> MockResource Properties
> -----------------------
>
> Key: SLING-2611
> URL: https://issues.apache.org/jira/browse/SLING-2611
> Project: Sling
> Issue Type: Improvement
> Components: Testing
> Affects Versions: Commons Testing 2.0.10
> Reporter: Dan Klco
> Priority: Minor
> Labels: newbie, patch, test
> Attachments: MockResource-Properties.diff
>
>
> A useful feature for the MockResource testing class would be the ability to specify additional properties and return them when the MockResource is adapted into a ValueMap.
> I use this on nearly every project I've been on to test services. I've attached a patch file which adds two methods:
> addProperty - add a single key, value set
> getProperties - returns the map of properties which can be modified
> And then in the adaptTo method I just added all of the properties in the map into the returned ValueMap.
--
This message is automatically generated by JIRA.
If you think it was sent incorrectly, please contact your JIRA administrators
For more information on JIRA, see: http://www.atlassian.com/software/jira
[jira] [Commented] (SLING-2611) MockResource Properties
Posted by "Bertrand Delacretaz (JIRA)" <ji...@apache.org>.
[ https://issues.apache.org/jira/browse/SLING-2611?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=13466833#comment-13466833 ]
Bertrand Delacretaz commented on SLING-2611:
--------------------------------------------
>From your comments it looks like you have a patch for this, could you attach it here?
> MockResource Properties
> -----------------------
>
> Key: SLING-2611
> URL: https://issues.apache.org/jira/browse/SLING-2611
> Project: Sling
> Issue Type: Improvement
> Components: Testing
> Affects Versions: Commons Testing 2.0.10
> Reporter: Dan Klco
> Priority: Minor
> Labels: newbie, patch, test
>
> A useful feature for the MockResource testing class would be the ability to specify additional properties and return them when the MockResource is adapted into a ValueMap.
> I use this on nearly every project I've been on to test services. I've attached a patch file which adds two methods:
> addProperty - add a single key, value set
> getProperties - returns the map of properties which can be modified
> And then in the adaptTo method I just added all of the properties in the map into the returned ValueMap.
--
This message is automatically generated by JIRA.
If you think it was sent incorrectly, please contact your JIRA administrators
For more information on JIRA, see: http://www.atlassian.com/software/jira
[jira] [Resolved] (SLING-2611) MockResource Properties
Posted by "Bertrand Delacretaz (JIRA)" <ji...@apache.org>.
[ https://issues.apache.org/jira/browse/SLING-2611?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ]
Bertrand Delacretaz resolved SLING-2611.
----------------------------------------
Resolution: Fixed
Assignee: Bertrand Delacretaz
Committed your patch in revision 1392367, with additional unit tests. Thanks for your contribution!
> MockResource Properties
> -----------------------
>
> Key: SLING-2611
> URL: https://issues.apache.org/jira/browse/SLING-2611
> Project: Sling
> Issue Type: Improvement
> Components: Testing
> Affects Versions: Commons Testing 2.0.10
> Reporter: Dan Klco
> Assignee: Bertrand Delacretaz
> Priority: Minor
> Labels: newbie, patch, test
> Attachments: MockResource-Properties.diff
>
>
> A useful feature for the MockResource testing class would be the ability to specify additional properties and return them when the MockResource is adapted into a ValueMap.
> I use this on nearly every project I've been on to test services. I've attached a patch file which adds two methods:
> addProperty - add a single key, value set
> getProperties - returns the map of properties which can be modified
> And then in the adaptTo method I just added all of the properties in the map into the returned ValueMap.
--
This message is automatically generated by JIRA.
If you think it was sent incorrectly, please contact your JIRA administrators
For more information on JIRA, see: http://www.atlassian.com/software/jira