All Projects → arquillian → arquillian-gradle-plugin

arquillian / arquillian-gradle-plugin

Licence: Apache-2.0 license
Gradle Plugin for handling Container control and deployment lifecycle

Programming Languages

groovy
2714 projects

Gradle Arquillian plugin

Arquillian Logo

Gradle plugin for handling container control and deployment lifecycle.

Usage

To use the plugin, include in your build script:

buildscript {
    repositories {
        jcenter()
    }

    dependencies {
        classpath 'org.jboss.arquillian.gradle:arquillian-gradle-plugin:0.1'
    }
}

apply plugin: 'arquillian'

Tasks

The plugin defines the following tasks:

Task name Depends on Type Description

arquillianStart<ContainerName>

-

ArquillianStart

Starts a container.

arquillianStop<ContainerName>

-

ArquillianStop

Stops a running container.

arquillianDeploy<ContainerName>

assemble

ArquillianDeploy

Deploys an archive to a container.

arquillianUndeploy<ContainerName>

assemble

ArquillianUndeploy

Undeploys an archive from a container.

arquillianRun<ContainerName>

assemble

ArquillianRun

Starts the container, deploys an archive to it and waits until the user presses CTRL + C to stop.

Extension properties

The plugin defines the following extension properties in the arquillian closure:

Property name Type Default value Description

debug

Boolean

false

Configures the Arquillian container to run in debug mode.

deployable

File

WAR, EAR or JAR file depending on applied plugins

The deployable artifact. This can be a WAR, EAR or JAR file.

containers

NamedDomainObjectContainer<ArquillianContainer>

default container

The containers to be used.

If no container is specified using the containers property, an embedded Jetty container is used.

Example

arquillian {
    debug = true
    deployable = file('my/path/arbitraryWebApp.war')

    containers {
        jetty {
            version = '8'
            type = 'embedded'
            config = ['bindHttpPort': 8085, 'bindAddress': '127.0.0.1', 'jettyPlus': false]

            dependencies {
                adapter 'org.jboss.arquillian.container:arquillian-jetty-embedded-7:1.0.0.CR2'
                container 'org.eclipse.jetty:jetty-webapp:8.1.11.v20130520'
                container group: 'org.eclipse.jetty', name: 'jetty-plus', version: '8.1.11.v20130520'
            }
        }

        glassfish {
            version = '3'
            type = 'embedded'
        }
    }
}
Note that the project description data, including the texts, logos, images, and/or trademarks, for each open source project belongs to its rightful owner. If you wish to add or remove any projects, please contact us at [email protected].