You are viewing a plain text version of this content. The canonical link for it is here.
Posted to dev@sling.apache.org by "Antonio Sanso (JIRA)" <ji...@apache.org> on 2014/07/09 10:28:05 UTC

[jira] [Resolved] (SLING-3751) Create a JUnit rule to inject a service reference into a test

     [ https://issues.apache.org/jira/browse/SLING-3751?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ]

Antonio Sanso resolved SLING-3751.
----------------------------------

       Resolution: Fixed
    Fix Version/s: JUnit Core 1.0.10

> Create a JUnit rule to inject a service reference into a test
> -------------------------------------------------------------
>
>                 Key: SLING-3751
>                 URL: https://issues.apache.org/jira/browse/SLING-3751
>             Project: Sling
>          Issue Type: Improvement
>          Components: Testing
>            Reporter: Francesco Mari
>            Assignee: Antonio Sanso
>            Priority: Minor
>             Fix For: JUnit Core 1.0.10
>
>
> I have implemented a JUnit rule to inject a reference to a service into a test class. For the JUnit rule to work, the test must be executed inside a running instance of Sling.
> The rule is implemented in [this commit|https://github.com/mtarantino/sling/commit/200a2a0b766cced3a9c71e1d35cf349557800db8] in [this fork|https://github.com/mtarantino/sling/tree/asanso] on GitHub.
> An example of its use can be found in [this commit|https://github.com/mtarantino/sling/commit/3a7ec91b0a75f578581ed3fd111600387ad29bd9] in the same fork.



--
This message was sent by Atlassian JIRA
(v6.2#6252)