[ 
https://issues.apache.org/jira/browse/WW-3711?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=13166869#comment-13166869
 ] 

Rene Gielen commented on WW-3711:
---------------------------------

Don't get me wrong, I see integration testing as highly desirable.

Having Spring support in Struts tests is in the domain of the Spring plugin. 
Spring is a core glue framework below your S2 app, so for real integration 
testing you want to use it in your tests as well.

Your persistence choice is something different IMO - it exceeds the domain of 
both S2 and S2-Spring plugin. If we started to include more specific utilities 
like the one you're suggesting, we would end up having to offer any permutation 
of technologies around - StrutsSpringHibernate, StrutsSpringJPA, 
StrutsSpringMyBatis, StrutsGuiceHibernate, ..., StrutsCDIHibernate, ... etc.

So again, while I see this is a really useful utility to you and maybe others, 
I think it is beyond the scope of what Struts 2 would want to provide out of 
the box. So I don't think we would want to include it into the S2 distribution.
                
> StrutsSpringTransactionalTestCase - adding transactional behaviour to 
> StrutsSpringTestCase
> ------------------------------------------------------------------------------------------
>
>                 Key: WW-3711
>                 URL: https://issues.apache.org/jira/browse/WW-3711
>             Project: Struts 2
>          Issue Type: New Feature
>          Components: Unit Tests
>    Affects Versions: 2.2.3.1
>            Reporter: Miguel Almeida
>            Priority: Minor
>              Labels: spring, struts2, test-patch
>             Fix For: 2.5
>
>         Attachments: StrutsSpringTransactionalAbstractTest.java
>
>
> From the mailing list thread:
> I'm using StrutsSpringTestCase for some under-the-skin tests.
> However, I felt the need to set up my database for a test. My tests that need 
> the database extend from AbstractTransactionalJUnit4SpringContextTests, which 
> makes them transactional.
> I therefore created a StrutsSpringTransactionalTestCase that merges the 
> behaviour of both StrutsSpringTestCase and 
> AbstractTransactionalJUnit4SpringContextTests. I currently just copy-pasted 
> the relevant information from AbstractTransactionalJUnit4SpringContextTests.
> I'd like you to take a look at it and comment on whether it makes sense to 
> include this in Struts. If so, feel free to use my contribution.

--
This message is automatically generated by JIRA.
If you think it was sent incorrectly, please contact your JIRA administrators: 
https://issues.apache.org/jira/secure/ContactAdministrators!default.jspa
For more information on JIRA, see: http://www.atlassian.com/software/jira

        

Reply via email to