[arquillian-issues] [JBoss JIRA] (ARQ-1779) Tests are not executed using combinations of @ApplyScriptBefore / @ApplyScriptAfter

Thomas Küstermann (JIRA) issues at jboss.org
Wed Jun 25 16:07:24 EDT 2014


    [ https://issues.jboss.org/browse/ARQ-1779?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=12979408#comment-12979408 ] 

Thomas Küstermann commented on ARQ-1779:
----------------------------------------

I just read the release announcement of Arquillian 1.1.5.Final

{quote}
Fixed false positives with JUnit from 1.1.4.Final

Arquillian Core 1.1.4.Final had a nasty bug where it would ‘erase’ some special exception cases that could happen In Container, that gave the Client side the wrong result.
This has now been fixed. Expected exceptions, Assumption and Injection errors should now be reported correctly(Both when using the @Rule and the @Test.expected variants).
{quote}

After upgrading to the new version, the false positive described here is gone. This issue can be closed as duplicate of ARQ-1758 I think.

> Tests are not executed using combinations of @ApplyScriptBefore / @ApplyScriptAfter
> -----------------------------------------------------------------------------------
>
>                 Key: ARQ-1779
>                 URL: https://issues.jboss.org/browse/ARQ-1779
>             Project: Arquillian
>          Issue Type: Bug
>      Security Level: Public(Everyone can see) 
>          Components: Extension - Persistence
>    Affects Versions: persistence_1.0.0.Alpha7
>            Reporter: Thomas Küstermann
>            Assignee: Bartosz Majsak
>             Fix For: persistence_1.0.0.next
>
>
> Forum reference: https://community.jboss.org/message/874117
> The following test case succeeds (green bar) although it should fail:
> {code:java}
> @RunWith(Arquillian.class)  
> @DataSource("java:oracleDS")  
> @Cleanup(phase=TestExecutionPhase.NONE)  
> @ApplyScriptBefore("deploy-db-functionality.sql")  
> @ApplyScriptAfter("undeploy-db-functionality.sql")  
> public class PersistenceIT {  
>    // @Deployment ...  
>   
>    @Test  
>    @ApplyScriptBefore("trigger-db-functionality.sql")  
>    public void shouldFail() {  
>        Assert.fail("should fail, but doesn't");  
>    }  
> }
> {code}
> Removing class level annotations does not work either:
> {code:java}
> @Test  
> @ApplyScriptBefore({ "deploy-db-functionality.sql", "trigger-db-functionality.sql" })  
> @ApplyScriptAfter("undeploy-db-functionality.sql")  
> public void shouldFail() { ... }  
> {code}
> What actually works is to use only one ApplyScriptBefore / ApplyScriptAfter annotation per test, each with only one script to execute.



--
This message was sent by Atlassian JIRA
(v6.2.6#6264)



More information about the arquillian-issues mailing list