Skip to content

Commit

Permalink
Merge pull request #5 from TurquoiseSpace/TurquoiseSpace
Browse files Browse the repository at this point in the history
merge TurquoiseSpace into master
  • Loading branch information
matcdac authored Nov 26, 2023
2 parents 3e09762 + 1dc4098 commit aac108d
Show file tree
Hide file tree
Showing 4 changed files with 103 additions and 115 deletions.
4 changes: 2 additions & 2 deletions .github/workflows/ci.yml
Original file line number Diff line number Diff line change
Expand Up @@ -39,7 +39,7 @@ jobs:
cache: 'maven'

- name: Build with Maven
run: mvn clean install
run: mvn clean install -Dgpg.skip=true

- name: Publish test coverage data to Coveralls
if: matrix.java == '17'
Expand Down Expand Up @@ -74,7 +74,7 @@ jobs:
JOB_DATETIME: ${{ steps.date.outputs.date }}
run: |
if [[ -n $GITHUB_TOKEN && -n $SONAR_TOKEN ]]; then
mvn verify sonar:sonar -Dsonar.token=${SONAR_TOKEN} -Dsonar.branch.name=${GITHUB_BRANCH} -Dsonar.analysis.buildNumber=${GITHUB_BRANCH}_${JOB_DATETIME} -Pcoverage
mvn verify sonar:sonar -Dsonar.token=${SONAR_TOKEN} -Dsonar.branch.name=${GITHUB_BRANCH} -Dsonar.analysis.buildNumber=${GITHUB_BRANCH}_${JOB_DATETIME} -Dgpg.skip=true -Pcoverage
else
echo No GITHUB_TOKEN and/or SONAR_TOKEN, the publishing to SonarCloud is skipped;
fi;
6 changes: 2 additions & 4 deletions README.md
Original file line number Diff line number Diff line change
@@ -1,17 +1,16 @@
JBehave JUnit Integration
=========================

![Visit Count](https://profile-counter.glitch.me/TurquoiseSpace_jbehave-junit-runner/count.svg)

[![jbehave-junit-runner CI](https://github.com/TurquoiseSpace/jbehave-junit-runner/actions/workflows/ci.yml/badge.svg)](https://github.com/TurquoiseSpace/jbehave-junit-runner/actions/workflows/ci.yml)

[![Coverage Status](https://coveralls.io/repos/github/TurquoiseSpace/jbehave-junit-runner/badge.svg?branch=master)](https://coveralls.io/github/TurquoiseSpace/jbehave-junit-runner?branch=master)

[![Quality Gate](https://sonarcloud.io/api/project_badges/measure?project=TurquoiseSpace_jbehave-junit-runner&metric=alert_status)](https://sonarcloud.io/summary/new_code?id=TurquoiseSpace_jbehave-junit-runner)

[![Codacy Badge](https://app.codacy.com/project/badge/Grade/d81f58136aa245668240b7d851a54d50)](https://www.codacy.com/gh/TurquoiseSpace/jbehave-junit-runner/dashboard?utm_source=github.com&utm_medium=referral&utm_content=TurquoiseSpace/jbehave-junit-runner&utm_campaign=Badge_Grade)

[![Maven Central](https://img.shields.io/maven-central/v/com.github.TurquoiseSpace/jbehave-junit-runner.svg)](https://central.sonatype.com/search?q=jbehave-junit-runner&namespace=com.github.TurquoiseSpace)
[![Javadocs](http://www.javadoc.io/badge/com.github.TurquoiseSpace/jbehave-junit-runner.svg)](http://www.javadoc.io/doc/com.github.TurquoiseSpace/jbehave-junit-runner)

[![Known Vulnerabilities](https://snyk.io/test/github/TurquoiseSpace/jbehave-junit-runner/badge.svg?targetFile=pom.xml)](https://snyk.io/test/github/TurquoiseSpace/jbehave-junit-runner?targetFile=pom.xml)

[![MIT licensed](https://img.shields.io/badge/license-MIT-blue.svg)](https://raw.githubusercontent.com/TurquoiseSpace/jbehave-junit-runner/master/LICENSE)
Expand Down Expand Up @@ -196,5 +195,4 @@ MIT License
[![MIT licensed](https://img.shields.io/badge/license-MIT-blue.svg)](https://raw.githubusercontent.com/TurquoiseSpace/jbehave-junit-runner/master/LICENSE)
[![FOSSA Status](https://app.fossa.io/api/projects/git%2Bgithub.com%2FTurquoiseSpace%2Fjbehave-junit-runner.svg?type=shield)](https://app.fossa.io/projects/git%2Bgithub.com%2FTurquoiseSpace%2Fjbehave-junit-runner?ref=badge_shield)

[![FOSSA Status](https://app.fossa.io/api/projects/git%2Bgithub.com%2FTurquoiseSpace%2Fjbehave-junit-runner.svg?type=large)](https://app.fossa.io/projects/git%2Bgithub.com%2FTurquoiseSpace%2Fjbehave-junit-runner?ref=badge_large)
[![FOSSA Status](https://app.fossa.com/api/projects/git%2Bgithub.com%2FTurquoiseSpace%2Fjbehave-junit-runner.svg?type=large&issueType=license)](https://app.fossa.com/projects/git%2Bgithub.com%2FTurquoiseSpace%2Fjbehave-junit-runner?ref=badge_large&issueType=license)
207 changes: 99 additions & 108 deletions pom.xml
Original file line number Diff line number Diff line change
Expand Up @@ -23,6 +23,14 @@
<developer>
<name>Prakhar Makhija</name>
<email>matcdac@gmail.com</email>
<organization>Turquoise Space</organization>
<organizationUrl>https://github.com/TurquoiseSpace</organizationUrl>
</developer>
<developer>
<name>Prakhar Makhija</name>
<email>prakhar.makhija@ge.com</email>
<organization>General Electric</organization>
<organizationUrl>https://www.ge.com/</organizationUrl>
</developer>
</developers>

Expand Down Expand Up @@ -56,12 +64,12 @@

<distributionManagement>
<snapshotRepository>
<id>sonatype-nexus-snapshots</id>
<id>ossrh</id>
<name>Sonatype Nexus Snapshots</name>
<url>https://oss.sonatype.org/content/repositories/snapshots/</url>
</snapshotRepository>
<repository>
<id>sonatype-nexus-staging</id>
<id>ossrh</id>
<name>Nexus Release Repository</name>
<url>https://oss.sonatype.org/service/local/staging/deploy/maven2/</url>
</repository>
Expand All @@ -76,6 +84,7 @@
<apache.maven-compiler-plugin.version>3.11.0</apache.maven-compiler-plugin.version>
<apache.maven-source-plugin.version>3.3.0</apache.maven-source-plugin.version>
<apache.maven-javadoc-plugin.version>3.6.2</apache.maven-javadoc-plugin.version>
<sonatype.plugins.nexus-staging-maven-plugin.version>1.6.13</sonatype.plugins.nexus-staging-maven-plugin.version>
<apache.maven-release-plugin.version>3.0.1</apache.maven-release-plugin.version>
<apache.maven-surefire-plugin.version>3.2.2</apache.maven-surefire-plugin.version>
<apache.maven-gpg-plugin.version>3.1.0</apache.maven-gpg-plugin.version>
Expand All @@ -89,7 +98,6 @@
<sonar.organization>turquoise-space</sonar.organization>
<sonar.projectKey>TurquoiseSpace_jbehave-junit-runner</sonar.projectKey>
<sonar.java.coveragePlugin>jacoco</sonar.java.coveragePlugin>
<sonar.jacoco.reportPath>${project.basedir}/target/jacoco.exec</sonar.jacoco.reportPath>
<sonar.coverage.jacoco.xmlReportPaths>target/site/jacoco/jacoco.xml</sonar.coverage.jacoco.xmlReportPaths>
<sonar.sources>src/main</sonar.sources>
<sonar.tests>src/test</sonar.tests>
Expand Down Expand Up @@ -121,7 +129,21 @@
<execution>
<id>attach-sources</id>
<goals>
<goal>jar</goal>
<goal>jar-no-fork</goal>
</goals>
</execution>
</executions>
</plugin>
<plugin>
<groupId>org.apache.maven.plugins</groupId>
<artifactId>maven-gpg-plugin</artifactId>
<version>${apache.maven-gpg-plugin.version}</version>
<executions>
<execution>
<id>sign-artifacts</id>
<phase>verify</phase>
<goals>
<goal>sign</goal>
</goals>
</execution>
</executions>
Expand All @@ -139,13 +161,28 @@
</execution>
</executions>
</plugin>
<plugin>
<groupId>org.sonatype.plugins</groupId>
<artifactId>nexus-staging-maven-plugin</artifactId>
<version>${sonatype.plugins.nexus-staging-maven-plugin.version}</version>
<extensions>true</extensions>
<configuration>
<serverId>ossrh</serverId>
<nexusUrl>https://oss.sonatype.org/</nexusUrl>
<autoReleaseAfterClose>true</autoReleaseAfterClose>
</configuration>
</plugin>
<plugin>
<groupId>org.apache.maven.plugins</groupId>
<artifactId>maven-release-plugin</artifactId>
<version>${apache.maven-release-plugin.version}</version>
<configuration>
<localCheckout>true</localCheckout>
<pushChanges>false</pushChanges>
<autoVersionSubmodules>true</autoVersionSubmodules>
<useReleaseProfile>false</useReleaseProfile>
<releaseProfiles>release</releaseProfiles>
<goals>deploy</goals>
</configuration>
</plugin>
<plugin>
Expand Down Expand Up @@ -199,6 +236,64 @@
<artifactId>sonar-maven-plugin</artifactId>
<version>${sonarsource.scanner.maven.sonar-maven-plugin.version}</version>
</plugin>
<plugin>
<groupId>org.jacoco</groupId>
<artifactId>jacoco-maven-plugin</artifactId>
<version>${jacoco.jacoco-maven-plugin.version}</version>
<executions>
<!-- Prepares the property pointing to the JaCoCo
runtime agent which is passed as VM argument when Maven the Surefire plugin
is executed. pre-unit-test -->
<execution>
<id>prepare-agent</id>
<phase>test-compile</phase>
<goals>
<goal>prepare-agent</goal>
</goals>
</execution>
<!-- Ensures that the code coverage report for
unit tests is created after unit tests have been run. post-unit-test -->
<execution>
<id>report</id>
<phase>test</phase>
<goals>
<goal>report</goal>
</goals>
<configuration>
<formats>
<format>XML</format>
</formats>
</configuration>
</execution>
</executions>
<configuration>
<skip>${maven.test.skip}</skip>
<destFile>${project.basedir}/target/coverage-reports/jacoco-unit.exec</destFile>
<dataFile>${project.basedir}/target/coverage-reports/jacoco-unit.exec</dataFile>
<output>file</output>
<append>true</append>
<excludes>
<exclude>${sonar.exclusions}</exclude>
</excludes>
</configuration>
</plugin>
<plugin>
<groupId>org.eluder.coveralls</groupId>
<artifactId>coveralls-maven-plugin</artifactId>
<version>${eluder.coveralls-maven-plugin.version}</version>
<dependencies>
<dependency>
<groupId>javax.xml.bind</groupId>
<artifactId>jaxb-api</artifactId>
<version>${javax.xml.bind.jaxb-api.version}</version>
</dependency>
<dependency>
<groupId>jakarta.xml.bind</groupId>
<artifactId>jakarta.xml.bind-api</artifactId>
<version>${jakarta.xml.bind-api.version}</version>
</dependency>
</dependencies>
</plugin>
</plugins>
</build>

Expand Down Expand Up @@ -230,46 +325,6 @@
<profiles>
<profile>
<id>coverage</id>
<build>
<plugins>
<plugin>
<groupId>org.jacoco</groupId>
<artifactId>jacoco-maven-plugin</artifactId>
<version>${jacoco.jacoco-maven-plugin.version}</version>
<executions>
<execution>
<id>prepare-agent</id>
<phase>test-compile</phase>
<goals>
<goal>prepare-agent</goal>
</goals>
</execution>
<execution>
<id>report</id>
<phase>verify</phase>
<goals>
<goal>report</goal>
</goals>
<configuration>
<formats>
<format>XML</format>
</formats>
</configuration>
</execution>
</executions>
<configuration>
<skip>${maven.test.skip}</skip>
<destFile>${project.basedir}/target/coverage-reports/jacoco-unit.exec</destFile>
<dataFile>${project.basedir}/target/coverage-reports/jacoco-unit.exec</dataFile>
<output>file</output>
<append>true</append>
<excludes>
<exclude>${sonar.exclusions}</exclude>
</excludes>
</configuration>
</plugin>
</plugins>
</build>
</profile>
<profile>
<id>sonar</id>
Expand All @@ -282,24 +337,6 @@
<activation>
<activeByDefault>false</activeByDefault>
</activation>
<build>
<plugins>
<plugin>
<groupId>org.apache.maven.plugins</groupId>
<artifactId>maven-gpg-plugin</artifactId>
<version>${apache.maven-gpg-plugin.version}</version>
<executions>
<execution>
<id>sign-artifacts</id>
<phase>verify</phase>
<goals>
<goal>sign</goal>
</goals>
</execution>
</executions>
</plugin>
</plugins>
</build>
</profile>
<profile>
<id>ci</id>
Expand All @@ -309,52 +346,6 @@
<value>true</value>
</property>
</activation>
<build>
<plugins>
<plugin>
<groupId>org.jacoco</groupId>
<artifactId>jacoco-maven-plugin</artifactId>
<version>${jacoco.jacoco-maven-plugin.version}</version>
<executions>
<!-- Prepares the property pointing to the JaCoCo
runtime agent which is passed as VM argument when Maven the Surefire plugin
is executed. -->
<execution>
<id>pre-unit-test</id>
<goals>
<goal>prepare-agent</goal>
</goals>
</execution>
<!-- Ensures that the code coverage report for
unit tests is created after unit tests have been run. -->
<execution>
<id>post-unit-test</id>
<phase>test</phase>
<goals>
<goal>report</goal>
</goals>
</execution>
</executions>
</plugin>
<plugin>
<groupId>org.eluder.coveralls</groupId>
<artifactId>coveralls-maven-plugin</artifactId>
<version>${eluder.coveralls-maven-plugin.version}</version>
<dependencies>
<dependency>
<groupId>javax.xml.bind</groupId>
<artifactId>jaxb-api</artifactId>
<version>${javax.xml.bind.jaxb-api.version}</version>
</dependency>
<dependency>
<groupId>jakarta.xml.bind</groupId>
<artifactId>jakarta.xml.bind-api</artifactId>
<version>${jakarta.xml.bind-api.version}</version>
</dependency>
</dependencies>
</plugin>
</plugins>
</build>
</profile>
</profiles>

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,6 @@
import java.util.List;

import org.jbehave.core.ConfigurableEmbedder;
import org.jbehave.core.condition.StepConditionMatcher;
import org.jbehave.core.configuration.Configuration;
import org.jbehave.core.embedder.AllStepCandidates;
import org.jbehave.core.embedder.Embedder;
Expand Down

0 comments on commit aac108d

Please sign in to comment.