Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

#70: Add support for OFT's command line option --wanted-tags #71

Merged
merged 10 commits into from
Nov 13, 2024
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 0 additions & 2 deletions .github/workflows/codeql-analysis.yml
Original file line number Diff line number Diff line change
Expand Up @@ -5,8 +5,6 @@ on:
branches: [ main ]
pull_request:
branches: [ main ]
schedule:
- cron: '0 4 * * 3'
kaklakariada marked this conversation as resolved.
Show resolved Hide resolved

jobs:
analyze:
Expand Down
2 changes: 1 addition & 1 deletion .settings/org.eclipse.jdt.core.prefs
Original file line number Diff line number Diff line change
Expand Up @@ -106,7 +106,7 @@ org.eclipse.jdt.core.compiler.problem.unusedPrivateMember=warning
org.eclipse.jdt.core.compiler.problem.unusedTypeParameter=warning
org.eclipse.jdt.core.compiler.problem.unusedWarningToken=warning
org.eclipse.jdt.core.compiler.problem.varargsArgumentNeedCast=warning
org.eclipse.jdt.core.compiler.processAnnotations=enabled
org.eclipse.jdt.core.compiler.processAnnotations=disabled
org.eclipse.jdt.core.compiler.release=disabled
org.eclipse.jdt.core.compiler.source=17
org.eclipse.jdt.core.formatter.align_assignment_statements_on_columns=false
Expand Down
4 changes: 4 additions & 0 deletions CHANGELOG.md
Original file line number Diff line number Diff line change
Expand Up @@ -4,6 +4,10 @@ All notable changes to this project will be documented in this file.
The format is based on [Keep a Changelog](https://keepachangelog.com/en/1.0.0/),
and this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0.html).

## [2.3.0] - 2024-11-13

- [#70](https://github.com/itsallcode/openfasttrace-maven-plugin/issues/70) Add support for OFT's command line option `--wanted-tags`

## [2.2.0] - 2024-08-21

- [PR #66](https://github.com/itsallcode/openfasttrace-maven-plugin/issues/66) Add filter for artifact types.
Expand Down
29 changes: 26 additions & 3 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -50,6 +50,7 @@ Add the openfasttrace-maven-plugin to your `pom.xml`:
<reportShowOrigin>true</reportShowOrigin>
<detailsSectionDisplay>COLLAPSE</detailsSectionDisplay>
<artifactTypes>feat,req</artifactTypes>
<tags>prototype,mvp</tags>
</configuration>
</plugin>
```
Expand All @@ -62,7 +63,7 @@ See [src/test/resources/empty-project](src/test/resources/simple-project/) for a

### OpenFastTrace Plugins

You can use OpenFastTrace plugins to import and export requirements in additional formats. Include plugins by adding them as a dependency to the `openfasttrace-maven-plugin`, see [project-with-plugins](src/test/resources/project-with-plugins) as an example.
You can use OpenFastTrace plugins to import and export requirements in additional formats. Include plugins by adding them as a dependency to the `openfasttrace-maven-plugin`, see [project-with-plugins](./src/test/resources/project-with-plugins) as an example.

```xml
<plugin>
Expand Down Expand Up @@ -153,11 +154,15 @@ You can add additional resource directories using the [Maven Resources Plugin](h
</build>
```

#### Selecting the Imported ArtifactTypes
#### Selecting the Imported Specification Items

Sometimes you don't want to trace the whole requirement chain. Instead, you are interested in the consistency of a subset. For instance, if you need to deliver a system requirement specification to another team, your job is to assure that the document is consistent in itself.

For those cases you can add an include list to the configuration that explicitly lists all artifact types to be imported. Note that this also affects which required coverage is imported — which is exactly what you want in this situation.
For those cases you can add an include list to the configuration that explicitly lists all artifact types or tags to be imported. Note that this also affects which required coverage is imported — which is exactly what you want in this situation.

See the [OFT user guide on import options](https://github.com/itsallcode/openfasttrace/blob/main/doc/user_guide.md#import-options) for details.

##### Select Artifact Types

The following example configuration limits import to artifact types `feat` and `req`.

Expand All @@ -167,6 +172,24 @@ The following example configuration limits import to artifact types `feat` and `
</configuration>
```

This works similar to OFT's command line argument `--wanted-artifact-types`.
tomuben marked this conversation as resolved.
Show resolved Hide resolved

##### Select Tags

The following example configuration limits import to tags `prototype` and `mvp`.

```xml
<configuration>
<tags>prototype,mvp</tags>
</configuration>
```

This works similar to OFT's command line argument `--wanted-tags`.

You can specify the underscore `_` to import specification items without tags.

You can also specify the tags to import using CLI option `-Dtags=prototype,mvp`.

#### Report

##### Report Format
Expand Down
40 changes: 23 additions & 17 deletions pom.xml
Original file line number Diff line number Diff line change
Expand Up @@ -18,7 +18,7 @@
<oft.version>4.1.0</oft.version>
<maven.core.version>3.8.7</maven.core.version>
<skipSigningArtifacts>true</skipSigningArtifacts>
<junit.version>5.11.0</junit.version>
<junit.version>5.11.3</junit.version>
<jacoco.version>0.8.12</jacoco.version>
<sonar.organization>itsallcode</sonar.organization>
<sonar.host.url>https://sonarcloud.io</sonar.host.url>
Expand Down Expand Up @@ -98,7 +98,7 @@
<dependency>
<groupId>org.apache.maven.plugin-tools</groupId>
<artifactId>maven-plugin-annotations</artifactId>
<version>3.13.1</version>
<version>3.15.1</version>
<scope>provided</scope>
</dependency>
<dependency>
Expand All @@ -118,7 +118,7 @@
<!-- Fix CVE-2021-29425 in transitive dependency of maven-plugin-testing-harness -->
<groupId>commons-io</groupId>
<artifactId>commons-io</artifactId>
<version>2.16.1</version>
<version>2.17.0</version>
<scope>test</scope>
</dependency>
<dependency>
Expand Down Expand Up @@ -171,6 +171,18 @@
<version>${junit.version}</version>
<scope>test</scope>
</dependency>
<dependency>
<groupId>org.mockito</groupId>
<artifactId>mockito-junit-jupiter</artifactId>
<version>5.14.2</version>
<scope>test</scope>
</dependency>
<dependency>
<groupId>org.itsallcode</groupId>
<artifactId>hamcrest-auto-matcher</artifactId>
<version>0.8.2</version>
<scope>test</scope>
</dependency>
<dependency>
<groupId>org.jacoco</groupId>
<artifactId>org.jacoco.agent</artifactId>
Expand Down Expand Up @@ -199,7 +211,7 @@
<plugin>
<groupId>org.apache.maven.plugins</groupId>
<artifactId>maven-gpg-plugin</artifactId>
<version>3.2.5</version>
<version>3.2.7</version>
<executions>
<execution>
<id>sign-artifacts</id>
Expand Down Expand Up @@ -322,7 +334,7 @@
<plugin>
<groupId>org.apache.maven.plugins</groupId>
<artifactId>maven-plugin-plugin</artifactId>
<version>3.14.0</version>
<version>3.15.1</version>
<configuration>
<goalPrefix>openfasttrace</goalPrefix>
<skipErrorNoDescriptorsFound>false</skipErrorNoDescriptorsFound>
Expand Down Expand Up @@ -365,7 +377,7 @@
<plugin>
<groupId>org.apache.maven.plugins</groupId>
<artifactId>maven-javadoc-plugin</artifactId>
<version>3.8.0</version>
<version>3.11.1</version>
<executions>
<execution>
<id>attach-javadocs</id>
Expand All @@ -379,7 +391,7 @@
<doclint></doclint>
<serialwarn>true</serialwarn>
<failOnError>true</failOnError>
<!-- Generated class HelpMojo causes warning: use of default constructor, which does not provide a comment -->
<!-- Generated class HelpMojo causes warning with Java 21: use of default constructor, which does not provide a comment -->
<failOnWarnings>false</failOnWarnings>
</configuration>
</plugin>
Expand Down Expand Up @@ -433,7 +445,7 @@
<plugin>
<groupId>org.apache.maven.plugins</groupId>
<artifactId>maven-dependency-plugin</artifactId>
<version>3.7.1</version>
<version>3.8.1</version>
<executions>
<execution>
<id>copy-jacoco</id>
Expand All @@ -453,11 +465,8 @@
<plugin>
<groupId>org.apache.maven.plugins</groupId>
<artifactId>maven-surefire-plugin</artifactId>
<version>3.4.0</version>
<version>3.5.2</version>
<configuration>
<excludes>
<exclude>**VerifierTest.java</exclude>
</excludes>
<systemPropertyVariables>
<java.util.logging.config.file>src/test/resources/logging.properties</java.util.logging.config.file>
</systemPropertyVariables>
Expand All @@ -466,11 +475,8 @@
<plugin>
<groupId>org.apache.maven.plugins</groupId>
<artifactId>maven-failsafe-plugin</artifactId>
<version>3.4.0</version>
<version>3.5.2</version>
<configuration>
<includes>
<include>**VerifierTest.java</include>
</includes>
<systemPropertyVariables>
<test.coverage>true</test.coverage>
<java.util.logging.config.file>src/test/resources/logging.properties</java.util.logging.config.file>
Expand Down Expand Up @@ -553,7 +559,7 @@
<plugin>
<groupId>org.apache.maven.plugins</groupId>
<artifactId>maven-artifact-plugin</artifactId>
<version>3.5.1</version>
<version>3.5.3</version>
<executions>
<execution>
<id>verify-reproducible-build</id>
Expand Down
Loading