Skip to content

Commit

Permalink
feature/178: Moved jacoco dependency to test scope (#179)
Browse files Browse the repository at this point in the history
* feature/178: Moved jacoco dependency to test scope
  • Loading branch information
jakobbraun authored Sep 15, 2021
1 parent 56b48a7 commit 379e732
Show file tree
Hide file tree
Showing 5 changed files with 19 additions and 11 deletions.
11 changes: 3 additions & 8 deletions dependencies.md
Original file line number Diff line number Diff line change
Expand Up @@ -30,14 +30,9 @@
| [org.xmlunit:xmlunit-matchers][13] | [The Apache Software License, Version 2.0][5] |
| [SLF4J JDK14 Binding][36] | [MIT License][21] |
| [mockito-core][38] | [The MIT License][39] |
| [JaCoCo :: Agent][40] | [Eclipse Public License 2.0][41] |
| [JaCoCo :: Core][40] | [Eclipse Public License 2.0][41] |
| [Maven Plugin Integration Testing][42] | [MIT][16] |

## Runtime Dependencies

| Dependency | License |
| --------------------- | -------------------------------- |
| [JaCoCo :: Agent][40] | [Eclipse Public License 2.0][41] |
| [Maven Plugin Integration Testing][44] | [MIT][16] |

## Plugin Dependencies

Expand Down Expand Up @@ -118,7 +113,7 @@
[88]: http://maven.apache.org/plugins/maven-install-plugin/
[56]: https://sonatype.github.io/ossindex-maven/maven-plugin/
[17]: https://www.eclipse.org/jgit/
[42]: https://github.com/exasol/maven-plugin-integration-testing
[44]: https://github.com/exasol/maven-plugin-integration-testing
[72]: http://maven.apache.org/plugins/maven-deploy-plugin/
[90]: http://maven.apache.org/plugins/maven-site-plugin/
[60]: https://maven.apache.org/plugins/maven-javadoc-plugin/
Expand Down
9 changes: 9 additions & 0 deletions doc/changes/changes_1.2.0.md
Original file line number Diff line number Diff line change
Expand Up @@ -9,9 +9,18 @@ In this release we added a property that allows users to skip the execution of p
## Features

* #176: Added skip property
* #178: Moved jacoco dependency to test scope

## Dependency Updates

### Runtime Dependency Updates

* Removed `org.jacoco:org.jacoco.agent:0.8.7`

### Test Dependency Updates

* Added `org.jacoco:org.jacoco.agent:0.8.7`

### Plugin Dependency Updates

* Updated `com.exasol:project-keeper-maven-plugin:1.1.0` to `1.2.0`
2 changes: 1 addition & 1 deletion pom.xml
Original file line number Diff line number Diff line change
Expand Up @@ -176,7 +176,7 @@
<artifactId>org.jacoco.agent</artifactId>
<version>${jacoco.version}</version>
<classifier>runtime</classifier>
<scope>runtime</scope>
<scope>test</scope>
</dependency>
<dependency>
<groupId>org.jacoco</groupId>
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -16,7 +16,7 @@ public class JacocoAgentDependencyValidator extends AbstractDependencyValidator
* Create a new instance of {@link JacocoAgentDependencyValidator}.
*/
public JacocoAgentDependencyValidator() {
super("org.jacoco", "org.jacoco.agent", "0.8.5", Scope.RUNTIME);
super("org.jacoco", "org.jacoco.agent", "0.8.5", Scope.TEST);
}

@Override
Expand Down
6 changes: 5 additions & 1 deletion src/test/java/com/exasol/projectkeeper/ProjectKeeperIT.java
Original file line number Diff line number Diff line change
Expand Up @@ -228,7 +228,11 @@ private void commitAndMakeTag(final Git git, final String releaseTag) throws Git

@Test
void testJacocoAgentIsExtracted() throws VerificationException, IOException {
writePomWithAllProjectKeeperPlugins();
final var pom = new TestMavenModel();
pom.addProjectKeeperPlugin(
new ProjectKeeperPluginDeclaration(CURRENT_VERSION).withEnabledModules(INTEGRATION_TESTS, UDF_COVERAGE)
.withExcludedPlugins("com.exasol:error-code-crawler-maven-plugin"));
pom.writeAsPomToProject(this.projectDir);
final Verifier verifier = getVerifier();
verifier.executeGoal("project-keeper:fix");
verifier.executeGoal("package");
Expand Down

0 comments on commit 379e732

Please sign in to comment.