cucumber-groovy
Used in:
components
- OverviewOverview
- VersionsVersions
- DependentsDependents
- DependenciesDependencies
<dependency>
<groupId>io.cucumber</groupId>
<artifactId>cucumber-groovy</artifactId>
<version>6.10.4</version>
</dependency><project xmlns="http://maven.apache.org/POM/4.0.0" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:schemaLocation="http://maven.apache.org/POM/4.0.0 http://maven.apache.org/xsd/maven-4.0.0.xsd">
<modelVersion>4.0.0</modelVersion>
<parent>
<groupId>io.cucumber</groupId>
<artifactId>cucumber-jvm-groovy</artifactId>
<version>6.10.4</version>
</parent>
<artifactId>cucumber-groovy</artifactId>
<packaging>jar</packaging>
<name>Cucumber Groovy</name>
<properties>
<gmaven.runtime>1.8</gmaven.runtime>
<jackson.version>2.10.0</jackson.version>
<junit-jupiter.version>5.6.0</junit-jupiter.version>
</properties>
<dependencies>
<dependency>
<groupId>io.cucumber</groupId>
<artifactId>cucumber-core</artifactId>
</dependency>
<dependency>
<groupId>org.codehaus.groovy</groupId>
<artifactId>groovy-all</artifactId>
<scope>provided</scope>
</dependency>
<dependency>
<groupId>com.fasterxml.jackson.datatype</groupId>
<artifactId>jackson-datatype-jsr310</artifactId>
<version>${jackson.version}</version>
<scope>test</scope>
</dependency>
<dependency>
<groupId>com.fasterxml.jackson.core</groupId>
<artifactId>jackson-databind</artifactId>
<version>${jackson.version}</version>
<scope>test</scope>
</dependency>
<dependency>
<groupId>io.cucumber</groupId>
<artifactId>cucumber-junit</artifactId>
<scope>test</scope>
</dependency>
<dependency>
<groupId>org.junit.jupiter</groupId>
<artifactId>junit-jupiter</artifactId>
<version>${junit-jupiter.version}</version>
<scope>test</scope>
</dependency>
<dependency>
<groupId>org.mockito</groupId>
<artifactId>mockito-core</artifactId>
<scope>test</scope>
</dependency>
<dependency>
<groupId>com.google.auto.service</groupId>
<artifactId>auto-service</artifactId>
<version>1.0-rc6</version>
</dependency>
</dependencies>
<build>
<plugins>
<plugin>
<groupId>org.codehaus.gmavenplus</groupId>
<artifactId>gmavenplus-plugin</artifactId>
<version>1.9.0</version>
<executions>
<execution>
<goals>
<goal>generateStubs</goal>
<goal>compile</goal>
<goal>generateTestStubs</goal>
<goal>compileTests</goal>
</goals>
</execution>
</executions>
<configuration>
<sources>
<source>
<directory>${project.basedir}/*</directory>
<includes>
<include>**/*.groovy</include>
</includes>
<excludes>
<exclude>**/generate-keywords.groovy</exclude>
</excludes>
</source>
</sources>
</configuration>
</plugin>
<plugin>
<groupId>org.apache.maven.plugins</groupId>
<artifactId>maven-clean-plugin</artifactId>
<configuration>
<filesets>
<fileset>
<directory>bin</directory>
<includes>
<include>*.jar</include>
</includes>
</fileset>
</filesets>
</configuration>
</plugin>
<plugin>
<groupId>org.apache.maven.plugins</groupId>
<artifactId>maven-shade-plugin</artifactId>
<executions>
<execution>
<phase>package</phase>
<goals>
<goal>shade</goal>
</goals>
<configuration>
<shadedArtifactAttached>true</shadedArtifactAttached>
</configuration>
</execution>
</executions>
</plugin>
<plugin>
<groupId>org.apache.maven.plugins</groupId>
<artifactId>maven-antrun-plugin</artifactId>
<executions>
<execution>
<id>generate-i18n-sources</id>
<goals>
<goal>run</goal>
</goals>
<phase>generate-sources</phase>
<configuration>
<target>
<taskdef name="groovy" classname="org.codehaus.groovy.ant.Groovy" classpathref="maven.plugin.classpath" />
<groovy src="src/main/groovy/generate-keywords.groovy" />
</target>
</configuration>
</execution>
<execution>
<id>copy-full-jar</id>
<phase>package</phase>
<configuration>
<target>
<copy file="${project.build.directory}/${project.build.finalName}-shaded.jar" tofile="${basedir}/bin/cucumber-groovy-shaded.jar" />
</target>
</configuration>
<goals>
<goal>run</goal>
</goals>
</execution>
<execution>
<id>groovy-cli-test</id>
<phase>integration-test</phase>
<goals>
<goal>run</goal>
</goals>
<configuration>
<target>
<!--
Also run the CLI test to ensure that stuff works via the CLI as well.
This isn't exactly the same as running `groovy bin/cucumber-jvm.groovy`
without cucumber-groovy-full.jar on the classpath, but that will work too.
-->
<echo message="Running groovy tests via the CLI..." />
<java classname="groovy.ui.GroovyMain" fork="true" failonerror="true" newenvironment="true" maxmemory="512m" classpathref="maven.test.classpath">
<classpath>
<pathelement location="${maven.dependency.org.codehaus.groovy.groovy-all.jar.path}" />
<pathelement location="${maven.dependency.junit.junit.jar.path}" />
<pathelement location="${basedir}/bin/cucumber-groovy-shaded.jar" />
<pathelement location="target/test-classes" />
</classpath>
<arg value="bin/cucumber-jvm.groovy" />
<arg value="--strict" />
<!--
target/test-classes/cucumber/runtime/groovy contains:
* compiled groovy stepdefs (compiled_stepdefs$_run_closure1.class etc)
* source groovy stepdefs (interpreted_stepdefs.groovy etc)
* feature filkes (a_feature.feature etc)
-->
<arg value="--glue" />
<arg value="classpath:io/cucumber/groovy" />
<arg value="classpath:io/cucumber/groovy" />
</java>
</target>
</configuration>
</execution>
</executions>
</plugin>
<plugin>
<groupId>org.codehaus.mojo</groupId>
<artifactId>build-helper-maven-plugin</artifactId>
<executions>
<execution>
<id>add-source</id>
<phase>generate-sources</phase>
<goals>
<goal>add-source</goal>
</goals>
<configuration>
<sources>
<source>${basedir}/target/generated-sources/i18n/java</source>
</sources>
</configuration>
</execution>
</executions>
</plugin>
<plugin>
<groupId>org.eluder.coveralls</groupId>
<artifactId>coveralls-maven-plugin</artifactId>
<configuration>
<sourceDirectories>
<sourceDirectory>${project.build
.outputDirectory}/generated-sources/i18n/java
/io/cucumber/groovy</sourceDirectory>
</sourceDirectories>
</configuration>
</plugin>
<plugin>
<groupId>org.apache.maven.plugins</groupId>
<artifactId>maven-surefire-plugin</artifactId>
<configuration>
<includes>
<include>**/*.java</include>
</includes>
</configuration>
</plugin>
</plugins>
</build>
</project>