[zanata-devel] Changes to Maven profiles for integration tests
Sean Flanigan
sflaniga at redhat.com
Thu Feb 5 03:49:21 UTC 2015
Update: Alex found a bug in the profile activation.
Until https://github.com/zanata/zanata-server/pull/684 goes in you will
still need to add -Dfunctional-test if you want functional tests to
work, because I forgot to change the profile activation in
zanata-test-war. Everything else still applies.
On 2015-02-05 12:09, Sean Flanigan wrote:
> Hi all,
>
> I have been trying to rationalise the profiles and properties we use
> when running integration tests, both Arquillian and Selenium. Both
> types of tests now use Cargo to download and install the appserver, with
> a choice of WildFly or EAP 6 (*not* zanata-server.zip).
>
> Overall, I think it is simpler to use, but you will probably need to
> change the profiles and properties you use when building and testing
> Zanata via Maven.
>
> By default, our Maven build will now run integration tests (all
> Arquillian tests and the Selenium smoke tests, ie BATs) when you run
> `mvn verify` or `mvn install`. (Previously functional tests only ran if
> you set `-Dfunctional-test`.)
>
> However, due to limitations in Maven 3.0's profile activation, it
> doesn't reliably default to WildFly 8 as it should. (So, you have to
> use `mvn verify -Dappserver=wildfly8`, not just `mvn verify`.)
>
>
> Short version:
>
> For wildfly (recommended for development):
>
> mvn verify -Dappserver=wildfly8 # DO NOT specify cargo.installation or
> # cargo.basename (unless experimenting)
>
> For EAP (recommended for production, and release testing):
>
> mvn verify -Dappserver=jbosseap6 # you must also specify
> # cargo.installation URL
> # and matching cargo.basename
>
> For neither (skip all integration tests):
>
> mvn verify -DskipArqTests -DskipFuncTests
>
> If you don't need to build the jars/wars, you can still just use:
>
> mvn test # compile and run unit tests only
>
>
> You should remove these options from your Maven commands:
>
> -Dinclude.test.patterns (still works, but use -DallFuncTests if you want
> to run all tests)
> -Dcargo.installation (unless using jbosseap6)
> -Darquillian.jboss.home (obsolete; cargo downloads everything now)
> -Dfunctional-test (obsolete; use -DskipFuncTests to disable functional
> tests now)
> -DnewCompiler (obsolete)
>
>
> I have added this information to
> https://github.com/zanata/zanata-server/wiki/Working-With-Maven
>
> Please let me know if I've missed anything!
>
> Regards
>
--
Sean Flanigan
Senior Software Engineer
Engineering - Internationalisation
Red Hat
-------------- next part --------------
A non-text attachment was scrubbed...
Name: signature.asc
Type: application/pgp-signature
Size: 213 bytes
Desc: OpenPGP digital signature
URL: <http://listman.redhat.com/archives/zanata-devel/attachments/20150205/e4ba7793/attachment.sig>
More information about the zanata-devel
mailing list