You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@maven.apache.org by kh...@apache.org on 2019/12/09 19:08:48 UTC

[maven] branch MODELTESTS_IMPROVEMENT updated (20455b2 -> 4cdd4fa)

This is an automated email from the ASF dual-hosted git repository.

khmarbaise pushed a change to branch MODELTESTS_IMPROVEMENT
in repository https://gitbox.apache.org/repos/asf/maven.git.


 discard 20455b2  Removing code redundancy Using assertj, JUnit Jupiter
     add b810f59  [MNG-6811] - Remove unnecessary filtering configuration
     add f7ca74d  [MNG-6812] - Remove unused files from maven-embedder
     add 2c8f927  Added label apache-maven
     add 25ced83  [MNG-6813] - Remove Maven 1 leftover
     add 610e623  [MNG-6814] - Remove useless exclusion in maven-plugin-api
     add 13c80d5  [MNG-6815] - Upgrade guice 4.2.2
     add 7284bd6  Updated README.md
     add 5750857  [MNG-6817] - Upgrade mockito to 3.2.0
     new 4cdd4fa  Removing code redundancy Using assertj, JUnit Jupiter

This update added new revisions after undoing existing revisions.
That is to say, some revisions that were in the old version of the
branch are not in the new version.  This situation occurs
when a user --force pushes a change and generates a repository
containing something like this:

 * -- * -- B -- O -- O -- O   (20455b2)
            \
             N -- N -- N   refs/heads/MODELTESTS_IMPROVEMENT (4cdd4fa)

You should already have received notification emails for all of the O
revisions, and so the following emails describe only the N revisions
from the common base, B.

Any revisions marked "omit" are not gone; other references still
refer to them.  Any revisions marked "discard" are gone forever.

The 1 revisions listed above as "new" are entirely new to this
repository and will be described in separate emails.  The revisions
listed as "add" were already present in the repository and have only
been added to this reference.


Summary of changes:
 .asf.yaml                                          |   3 +-
 README.md                                          |   4 +-
 maven-embedder/pom.xml                             |  88 ++---
 .../src/test/embedder-test-project/pom.xml         |  48 ---
 .../src/main/java/org/apache/maven/App.java        |  13 -
 .../src/test/java/org/apache/maven/AppTest.java    |  38 --
 .../aggregate-mojo-failure/plugin/pom.xml          |  49 ---
 .../src/main/java/org/plugin/TestPlugin.java       |  36 --
 .../aggregate-mojo-failure/project/pom.xml         |  25 --
 .../bad-build-plan/plugin/pom.xml                  |  49 ---
 .../src/main/java/org/plugin/TestPlugin.java       |  35 --
 .../bad-build-plan/project/pom.xml                 |  25 --
 .../bad-dep-version/pom.xml                        |  33 --
 .../test-maven-ext/1/test-maven-ext-1.pom          |  34 --
 .../bad-ext-direct-deps/project/pom.xml            |  35 --
 .../1/bad-ext-plugin-dep-ver-maven-plugin-1.jar    | Bin 3166 -> 0 bytes
 .../1/bad-ext-plugin-dep-ver-maven-plugin-1.pom    |  55 ---
 .../bad-ext-plugin-dep-ver/plugin/pom.xml          |  57 ---
 .../src/main/java/org/plugin/TestPlugin.java       |  33 --
 .../bad-ext-plugin-dep-ver/project/pom.xml         |  37 --
 .../1/bad-ext-plugin-maven-ver-maven-plugin-1.jar  | Bin 3166 -> 0 bytes
 .../1/bad-ext-plugin-maven-ver-maven-plugin-1.pom  |  54 ---
 .../maven-metadata-local.xml                       |  12 -
 .../bad-ext-plugin-maven-ver/plugin/pom.xml        |  57 ---
 .../src/main/java/org/plugin/TestPlugin.java       |  33 --
 .../bad-ext-plugin-maven-ver/project/pom.xml       |  37 --
 .../bad-maven-version/pom.xml                      |  11 -
 .../bad-mg-dep-version/pom.xml                     |  35 --
 .../bad-non-dep-version/pom.xml                    |  35 --
 .../bad-profile-repo/pom.xml                       |   7 -
 .../bad-profile-repo/profiles.xml                  |  18 -
 .../config-rdonly-mojo-param/plugin/pom.xml        |  49 ---
 .../src/main/java/org/plugin/TestPlugin.java       |  39 --
 .../config-rdonly-mojo-param/project/pom.xml       |  47 ---
 .../deploy-repo-creation-err/pom.xml               |  41 ---
 .../duplicated-attachments/plugin/pom.xml          |  54 ---
 .../src/main/java/org/plugin/TestPlugin.java       |  50 ---
 .../duplicated-attachments/project/pom.xml         |  25 --
 .../1/err-loading-plugin-maven-plugin-1.jar        | Bin 3166 -> 0 bytes
 .../1/err-loading-plugin-maven-plugin-1.pom        |  55 ---
 .../err-loading-plugin/project/pom.xml             |  45 ---
 .../org/apache/maven/errortest/dep/1/dep-1.pom     |  16 -
 .../1/err-resolving-ext-plugin-maven-plugin-1.jar  | Bin 3166 -> 0 bytes
 .../1/err-resolving-ext-plugin-maven-plugin-1.pom  |  60 ----
 .../err-resolving-ext-plugin/project/pom.xml       |  18 -
 .../org/apache/maven/errortest/dep/1/dep-1.pom     |  16 -
 .../err-resolving-project-dep/project/pom.xml      |  27 --
 .../apache/maven/test/error/mojoFailure/App.java   |  13 -
 .../maven/test/error/mojoFailure/AppTest.java      |  38 --
 .../test-maven-ext-dep/1/test-maven-ext-dep-1.pom  |  26 --
 .../test-maven-ext/1/test-maven-ext-1.pom          |  34 --
 .../ext-deps-resolve-err/project/pom.xml           |  35 --
 .../ext-plugin-artifact-missing-maven-plugin-1.pom |  55 ---
 .../ext-plugin-artifact-missing/project/pom.xml    |  37 --
 .../ext-plugin-realm-error/plugin/pom.xml          |  49 ---
 .../src/main/java/org/plugin/ComponentOne.java     |   8 -
 .../src/main/java/org/plugin/ComponentTwo.java     |   8 -
 .../src/main/java/org/plugin/TestPlugin.java       |  39 --
 .../main/resources/META-INF/plexus/components.xml  |  25 --
 .../ext-plugin-realm-error/project/pom.xml         |  36 --
 .../1/ext-plugin-version-err-maven-plugin-1.jar    | Bin 3166 -> 0 bytes
 .../1/ext-plugin-version-err-maven-plugin-1.pom    |  50 ---
 .../maven-metadata-local.xml                       |  10 -
 .../ext-plugin-version-err/plugin/pom.xml          |  57 ---
 .../src/main/java/org/plugin/TestPlugin.java       |  33 --
 .../ext-plugin-version-err/project/pom.xml         |  36 --
 .../ext-realm-error/ext/pom.xml                    |  38 --
 .../ext/src/main/java/org/ext/App.java             |  13 -
 .../main/resources/META-INF/plexus/components.xml  |   1 -
 .../ext-realm-error/project/pom.xml                |  35 --
 .../interp-from-model/pom.xml                      |   7 -
 .../local-repo/org/test/bad-pom/1/bad-pom-1.pom    |   9 -
 .../interp-from-project/project/pom.xml            |  22 --
 .../load-extern-profiles-ioex/pom.xml              |   7 -
 .../load-extern-profiles-xex/pom.xml               |   7 -
 .../load-extern-profiles-xex/profiles.xml          |   4 -
 .../missing-direct-invoke-mojo/plugin/pom.xml      |  49 ---
 .../src/main/java/org/plugin/TestPlugin.java       |  36 --
 .../missing-module-pom/child1/pom.xml              |  19 -
 .../child1/src/main/java/org/test/App.java         |  13 -
 .../child1/src/test/java/org/test/AppTest.java     |  38 --
 .../missing-module-pom/pom.xml                     |  13 -
 .../missing-parent-pom/pom.xml                     |  11 -
 .../missing-req-mojo-param/plugin/pom.xml          |  49 ---
 .../src/main/java/org/plugin/TestPlugin.java       |  38 --
 .../missing-req-mojo-param/project/pom.xml         |  25 --
 .../mojo-config-error/plugin/pom.xml               |  49 ---
 .../src/main/java/org/plugin/TestPlugin.java       |  33 --
 .../src/main/resources/META-INF/maven/plugin.xml   |  38 --
 .../mojo-config-error/project/pom.xml              |  45 ---
 .../mojo-exec-err/plugin/pom.xml                   |  49 ---
 .../src/main/java/org/plugin/TestPlugin.java       |  33 --
 .../mojo-exec-err/project/pom.xml                  |  26 --
 .../mojo-lookup-err/plugin/pom.xml                 |  54 ---
 .../src/main/java/org/plugin/TestPlugin.java       |  42 ---
 .../mojo-lookup-err/project/pom.xml                |  25 --
 .../parent-parse-ioex/child/pom.xml                |  10 -
 .../parent-parse-ioex/pom.xml                      |   0
 .../parent-parse-xex/child/pom.xml                 |  10 -
 .../parent-parse-xex/pom.xml                       |   7 -
 .../profile-activator-err/pom.xml                  |  39 --
 .../profile-activator-lookup-err/ext/pom.xml       |  38 --
 .../ext/src/main/java/org/ext/App.java             |  13 -
 .../main/resources/META-INF/plexus/components.xml  |  16 -
 .../profile-activator-lookup-err/project/pom.xml   |  46 ---
 .../project-collision/mod1/pom.xml                 |   7 -
 .../project-collision/mod2/pom.xml                 |   7 -
 .../project-collision/pom.xml                      |  12 -
 .../project-cycle/dep/pom.xml                      |  12 -
 .../error-reporting-projects/project-cycle/pom.xml |  19 -
 .../project-dep-missing/pom.xml                    |  22 --
 .../apache/maven/test/error/mojoFailure/App.java   |  13 -
 .../maven/test/error/mojoFailure/AppTest.java      |  38 --
 .../project-mojo-failure/pom.xml                   |  17 -
 .../apache/maven/test/error/mojoFailure/App.java   |  14 -
 .../maven/test/error/mojoFailure/AppTest.java      |  38 --
 .../project-parse-xex/pom.xml                      |  25 --
 .../project-validation/pom.xml                     |  13 -
 .../repo-creation-err/pom.xml                      |  41 ---
 .../test/eventing-projects/read-with-deps/pom.xml  |  15 -
 .../read-with-deps/repo/tests/dep/1/dep-1.pom      |   6 -
 .../eventing-projects/simple-read-project/pom.xml  |   6 -
 .../test/extensions/META-INF/plexus/components.xml |  28 --
 .../src/test/plugin-version-references/jar-pom.xml |  32 --
 .../plugin-version-references/maven-plugin-pom.xml |  36 --
 .../bad-module-non-recursive/badmodule/pom.xml     |  14 -
 .../bad-module-non-recursive/goodmodule/pom.xml    |  14 -
 .../test/projects/bad-module-non-recursive/pom.xml |  14 -
 .../src/test/projects/invalid-goal/pom.xml         |  49 ---
 .../project/pom.xml                                |  13 -
 .../src/main/java/org/codehaus/m2eclipse/App.java  |  13 -
 .../test/java/org/codehaus/m2eclipse/AppTest.java  |  38 --
 .../parent/1.0-SNAPSHOT/maven-metadata-company.xml |  11 -
 .../parent/1.0-SNAPSHOT/parent-1.0-SNAPSHOT.pom    |  18 -
 .../m2eclipse/parent/maven-metadata-local.xml      |  11 -
 .../settings.xml                                   |  23 --
 .../src/test/projects/optional-dep/pom.xml         |  20 --
 .../readProject-missingModuleIgnored/pom.xml       |  13 -
 .../modules/child1/pom.xml                         |  13 -
 .../readProject-withScmInheritance/pom.xml         |  19 -
 .../org.apache.maven/maven-core/pom.properties     |  18 -
 .../resources/pom-with-distribution-status.xml     |  30 --
 .../test/resources/pom-without-dependencies.xml    |  30 --
 maven-embedder/src/test/resources/pom.xml          |  34 --
 maven-embedder/src/test/resources/pom2.xml         |  48 ---
 .../test/resources/settings/invalid-settings.xml   |  24 --
 .../src/test/resources/settings/valid-settings.xml |  27 --
 maven-model-builder/src/main/mdo/profiles.mdo      | 399 ---------------------
 maven-model/pom.xml                                |  11 -
 maven-plugin-api/pom.xml                           |   6 -
 pom.xml                                            |   4 +-
 151 files changed, 41 insertions(+), 4408 deletions(-)
 delete mode 100644 maven-embedder/src/test/embedder-test-project/pom.xml
 delete mode 100644 maven-embedder/src/test/embedder-test-project/src/main/java/org/apache/maven/App.java
 delete mode 100644 maven-embedder/src/test/embedder-test-project/src/test/java/org/apache/maven/AppTest.java
 delete mode 100644 maven-embedder/src/test/error-reporting-projects/aggregate-mojo-failure/plugin/pom.xml
 delete mode 100644 maven-embedder/src/test/error-reporting-projects/aggregate-mojo-failure/plugin/src/main/java/org/plugin/TestPlugin.java
 delete mode 100644 maven-embedder/src/test/error-reporting-projects/aggregate-mojo-failure/project/pom.xml
 delete mode 100644 maven-embedder/src/test/error-reporting-projects/bad-build-plan/plugin/pom.xml
 delete mode 100644 maven-embedder/src/test/error-reporting-projects/bad-build-plan/plugin/src/main/java/org/plugin/TestPlugin.java
 delete mode 100644 maven-embedder/src/test/error-reporting-projects/bad-build-plan/project/pom.xml
 delete mode 100644 maven-embedder/src/test/error-reporting-projects/bad-dep-version/pom.xml
 delete mode 100644 maven-embedder/src/test/error-reporting-projects/bad-ext-direct-deps/local-repo/org/apache/maven/errortest/test-maven-ext/1/test-maven-ext-1.pom
 delete mode 100644 maven-embedder/src/test/error-reporting-projects/bad-ext-direct-deps/project/pom.xml
 delete mode 100644 maven-embedder/src/test/error-reporting-projects/bad-ext-plugin-dep-ver/local-repo/org/apache/maven/errortest/bad-ext-plugin-dep-ver-maven-plugin/1/bad-ext-plugin-dep-ver-maven-plugin-1.jar
 delete mode 100644 maven-embedder/src/test/error-reporting-projects/bad-ext-plugin-dep-ver/local-repo/org/apache/maven/errortest/bad-ext-plugin-dep-ver-maven-plugin/1/bad-ext-plugin-dep-ver-maven-plugin-1.pom
 delete mode 100644 maven-embedder/src/test/error-reporting-projects/bad-ext-plugin-dep-ver/plugin/pom.xml
 delete mode 100644 maven-embedder/src/test/error-reporting-projects/bad-ext-plugin-dep-ver/plugin/src/main/java/org/plugin/TestPlugin.java
 delete mode 100644 maven-embedder/src/test/error-reporting-projects/bad-ext-plugin-dep-ver/project/pom.xml
 delete mode 100644 maven-embedder/src/test/error-reporting-projects/bad-ext-plugin-maven-ver/local-repo/org/apache/maven/errortest/bad-ext-plugin-maven-ver-maven-plugin/1/bad-ext-plugin-maven-ver-maven-plugin-1.jar
 delete mode 100644 maven-embedder/src/test/error-reporting-projects/bad-ext-plugin-maven-ver/local-repo/org/apache/maven/errortest/bad-ext-plugin-maven-ver-maven-plugin/1/bad-ext-plugin-maven-ver-maven-plugin-1.pom
 delete mode 100644 maven-embedder/src/test/error-reporting-projects/bad-ext-plugin-maven-ver/local-repo/org/apache/maven/errortest/bad-ext-plugin-maven-ver-maven-plugin/maven-metadata-local.xml
 delete mode 100644 maven-embedder/src/test/error-reporting-projects/bad-ext-plugin-maven-ver/plugin/pom.xml
 delete mode 100644 maven-embedder/src/test/error-reporting-projects/bad-ext-plugin-maven-ver/plugin/src/main/java/org/plugin/TestPlugin.java
 delete mode 100644 maven-embedder/src/test/error-reporting-projects/bad-ext-plugin-maven-ver/project/pom.xml
 delete mode 100644 maven-embedder/src/test/error-reporting-projects/bad-maven-version/pom.xml
 delete mode 100644 maven-embedder/src/test/error-reporting-projects/bad-mg-dep-version/pom.xml
 delete mode 100644 maven-embedder/src/test/error-reporting-projects/bad-non-dep-version/pom.xml
 delete mode 100644 maven-embedder/src/test/error-reporting-projects/bad-profile-repo/pom.xml
 delete mode 100644 maven-embedder/src/test/error-reporting-projects/bad-profile-repo/profiles.xml
 delete mode 100644 maven-embedder/src/test/error-reporting-projects/config-rdonly-mojo-param/plugin/pom.xml
 delete mode 100644 maven-embedder/src/test/error-reporting-projects/config-rdonly-mojo-param/plugin/src/main/java/org/plugin/TestPlugin.java
 delete mode 100644 maven-embedder/src/test/error-reporting-projects/config-rdonly-mojo-param/project/pom.xml
 delete mode 100644 maven-embedder/src/test/error-reporting-projects/deploy-repo-creation-err/pom.xml
 delete mode 100644 maven-embedder/src/test/error-reporting-projects/duplicated-attachments/plugin/pom.xml
 delete mode 100644 maven-embedder/src/test/error-reporting-projects/duplicated-attachments/plugin/src/main/java/org/plugin/TestPlugin.java
 delete mode 100644 maven-embedder/src/test/error-reporting-projects/duplicated-attachments/project/pom.xml
 delete mode 100644 maven-embedder/src/test/error-reporting-projects/err-loading-plugin/local-repo/org/apache/maven/errortest/err-loading-plugin-maven-plugin/1/err-loading-plugin-maven-plugin-1.jar
 delete mode 100644 maven-embedder/src/test/error-reporting-projects/err-loading-plugin/local-repo/org/apache/maven/errortest/err-loading-plugin-maven-plugin/1/err-loading-plugin-maven-plugin-1.pom
 delete mode 100644 maven-embedder/src/test/error-reporting-projects/err-loading-plugin/project/pom.xml
 delete mode 100644 maven-embedder/src/test/error-reporting-projects/err-resolving-ext-plugin/local-repo/org/apache/maven/errortest/dep/1/dep-1.pom
 delete mode 100644 maven-embedder/src/test/error-reporting-projects/err-resolving-ext-plugin/local-repo/org/apache/maven/errortest/err-resolving-ext-plugin-maven-plugin/1/err-resolving-ext-plugin-maven-plugin-1.jar
 delete mode 100644 maven-embedder/src/test/error-reporting-projects/err-resolving-ext-plugin/local-repo/org/apache/maven/errortest/err-resolving-ext-plugin-maven-plugin/1/err-resolving-ext-plugin-maven-plugin-1.pom
 delete mode 100644 maven-embedder/src/test/error-reporting-projects/err-resolving-ext-plugin/project/pom.xml
 delete mode 100644 maven-embedder/src/test/error-reporting-projects/err-resolving-project-dep/project/local-repo/org/apache/maven/errortest/dep/1/dep-1.pom
 delete mode 100644 maven-embedder/src/test/error-reporting-projects/err-resolving-project-dep/project/pom.xml
 delete mode 100644 maven-embedder/src/test/error-reporting-projects/err-resolving-project-dep/project/src/main/java/org/apache/maven/test/error/mojoFailure/App.java
 delete mode 100644 maven-embedder/src/test/error-reporting-projects/err-resolving-project-dep/project/src/test/java/org/apache/maven/test/error/mojoFailure/AppTest.java
 delete mode 100644 maven-embedder/src/test/error-reporting-projects/ext-deps-resolve-err/local-repo/org/apache/maven/errortest/test-maven-ext-dep/1/test-maven-ext-dep-1.pom
 delete mode 100644 maven-embedder/src/test/error-reporting-projects/ext-deps-resolve-err/local-repo/org/apache/maven/errortest/test-maven-ext/1/test-maven-ext-1.pom
 delete mode 100644 maven-embedder/src/test/error-reporting-projects/ext-deps-resolve-err/project/pom.xml
 delete mode 100644 maven-embedder/src/test/error-reporting-projects/ext-plugin-artifact-missing/local-repo/org/apache/maven/errortest/ext-plugin-artifact-missing-maven-plugin/1/ext-plugin-artifact-missing-maven-plugin-1.pom
 delete mode 100644 maven-embedder/src/test/error-reporting-projects/ext-plugin-artifact-missing/project/pom.xml
 delete mode 100644 maven-embedder/src/test/error-reporting-projects/ext-plugin-realm-error/plugin/pom.xml
 delete mode 100644 maven-embedder/src/test/error-reporting-projects/ext-plugin-realm-error/plugin/src/main/java/org/plugin/ComponentOne.java
 delete mode 100644 maven-embedder/src/test/error-reporting-projects/ext-plugin-realm-error/plugin/src/main/java/org/plugin/ComponentTwo.java
 delete mode 100644 maven-embedder/src/test/error-reporting-projects/ext-plugin-realm-error/plugin/src/main/java/org/plugin/TestPlugin.java
 delete mode 100644 maven-embedder/src/test/error-reporting-projects/ext-plugin-realm-error/plugin/src/main/resources/META-INF/plexus/components.xml
 delete mode 100644 maven-embedder/src/test/error-reporting-projects/ext-plugin-realm-error/project/pom.xml
 delete mode 100644 maven-embedder/src/test/error-reporting-projects/ext-plugin-version-err/local-repo/org/apache/maven/errortest/ext-plugin-version-err-maven-plugin/1/ext-plugin-version-err-maven-plugin-1.jar
 delete mode 100644 maven-embedder/src/test/error-reporting-projects/ext-plugin-version-err/local-repo/org/apache/maven/errortest/ext-plugin-version-err-maven-plugin/1/ext-plugin-version-err-maven-plugin-1.pom
 delete mode 100644 maven-embedder/src/test/error-reporting-projects/ext-plugin-version-err/local-repo/org/apache/maven/errortest/ext-plugin-version-err-maven-plugin/maven-metadata-local.xml
 delete mode 100644 maven-embedder/src/test/error-reporting-projects/ext-plugin-version-err/plugin/pom.xml
 delete mode 100644 maven-embedder/src/test/error-reporting-projects/ext-plugin-version-err/plugin/src/main/java/org/plugin/TestPlugin.java
 delete mode 100644 maven-embedder/src/test/error-reporting-projects/ext-plugin-version-err/project/pom.xml
 delete mode 100644 maven-embedder/src/test/error-reporting-projects/ext-realm-error/ext/pom.xml
 delete mode 100644 maven-embedder/src/test/error-reporting-projects/ext-realm-error/ext/src/main/java/org/ext/App.java
 delete mode 100644 maven-embedder/src/test/error-reporting-projects/ext-realm-error/ext/src/main/resources/META-INF/plexus/components.xml
 delete mode 100644 maven-embedder/src/test/error-reporting-projects/ext-realm-error/project/pom.xml
 delete mode 100644 maven-embedder/src/test/error-reporting-projects/interp-from-model/pom.xml
 delete mode 100644 maven-embedder/src/test/error-reporting-projects/interp-from-project/project/local-repo/org/test/bad-pom/1/bad-pom-1.pom
 delete mode 100644 maven-embedder/src/test/error-reporting-projects/interp-from-project/project/pom.xml
 delete mode 100644 maven-embedder/src/test/error-reporting-projects/load-extern-profiles-ioex/pom.xml
 delete mode 100644 maven-embedder/src/test/error-reporting-projects/load-extern-profiles-xex/pom.xml
 delete mode 100644 maven-embedder/src/test/error-reporting-projects/load-extern-profiles-xex/profiles.xml
 delete mode 100644 maven-embedder/src/test/error-reporting-projects/missing-direct-invoke-mojo/plugin/pom.xml
 delete mode 100644 maven-embedder/src/test/error-reporting-projects/missing-direct-invoke-mojo/plugin/src/main/java/org/plugin/TestPlugin.java
 delete mode 100644 maven-embedder/src/test/error-reporting-projects/missing-module-pom/child1/pom.xml
 delete mode 100644 maven-embedder/src/test/error-reporting-projects/missing-module-pom/child1/src/main/java/org/test/App.java
 delete mode 100644 maven-embedder/src/test/error-reporting-projects/missing-module-pom/child1/src/test/java/org/test/AppTest.java
 delete mode 100644 maven-embedder/src/test/error-reporting-projects/missing-module-pom/pom.xml
 delete mode 100644 maven-embedder/src/test/error-reporting-projects/missing-parent-pom/pom.xml
 delete mode 100644 maven-embedder/src/test/error-reporting-projects/missing-req-mojo-param/plugin/pom.xml
 delete mode 100644 maven-embedder/src/test/error-reporting-projects/missing-req-mojo-param/plugin/src/main/java/org/plugin/TestPlugin.java
 delete mode 100644 maven-embedder/src/test/error-reporting-projects/missing-req-mojo-param/project/pom.xml
 delete mode 100644 maven-embedder/src/test/error-reporting-projects/mojo-config-error/plugin/pom.xml
 delete mode 100644 maven-embedder/src/test/error-reporting-projects/mojo-config-error/plugin/src/main/java/org/plugin/TestPlugin.java
 delete mode 100644 maven-embedder/src/test/error-reporting-projects/mojo-config-error/plugin/src/main/resources/META-INF/maven/plugin.xml
 delete mode 100644 maven-embedder/src/test/error-reporting-projects/mojo-config-error/project/pom.xml
 delete mode 100644 maven-embedder/src/test/error-reporting-projects/mojo-exec-err/plugin/pom.xml
 delete mode 100644 maven-embedder/src/test/error-reporting-projects/mojo-exec-err/plugin/src/main/java/org/plugin/TestPlugin.java
 delete mode 100644 maven-embedder/src/test/error-reporting-projects/mojo-exec-err/project/pom.xml
 delete mode 100644 maven-embedder/src/test/error-reporting-projects/mojo-lookup-err/plugin/pom.xml
 delete mode 100644 maven-embedder/src/test/error-reporting-projects/mojo-lookup-err/plugin/src/main/java/org/plugin/TestPlugin.java
 delete mode 100644 maven-embedder/src/test/error-reporting-projects/mojo-lookup-err/project/pom.xml
 delete mode 100644 maven-embedder/src/test/error-reporting-projects/parent-parse-ioex/child/pom.xml
 delete mode 100644 maven-embedder/src/test/error-reporting-projects/parent-parse-ioex/pom.xml
 delete mode 100644 maven-embedder/src/test/error-reporting-projects/parent-parse-xex/child/pom.xml
 delete mode 100644 maven-embedder/src/test/error-reporting-projects/parent-parse-xex/pom.xml
 delete mode 100644 maven-embedder/src/test/error-reporting-projects/profile-activator-err/pom.xml
 delete mode 100644 maven-embedder/src/test/error-reporting-projects/profile-activator-lookup-err/ext/pom.xml
 delete mode 100644 maven-embedder/src/test/error-reporting-projects/profile-activator-lookup-err/ext/src/main/java/org/ext/App.java
 delete mode 100644 maven-embedder/src/test/error-reporting-projects/profile-activator-lookup-err/ext/src/main/resources/META-INF/plexus/components.xml
 delete mode 100644 maven-embedder/src/test/error-reporting-projects/profile-activator-lookup-err/project/pom.xml
 delete mode 100644 maven-embedder/src/test/error-reporting-projects/project-collision/mod1/pom.xml
 delete mode 100644 maven-embedder/src/test/error-reporting-projects/project-collision/mod2/pom.xml
 delete mode 100644 maven-embedder/src/test/error-reporting-projects/project-collision/pom.xml
 delete mode 100644 maven-embedder/src/test/error-reporting-projects/project-cycle/dep/pom.xml
 delete mode 100644 maven-embedder/src/test/error-reporting-projects/project-cycle/pom.xml
 delete mode 100644 maven-embedder/src/test/error-reporting-projects/project-dep-missing/pom.xml
 delete mode 100644 maven-embedder/src/test/error-reporting-projects/project-dep-missing/src/main/java/org/apache/maven/test/error/mojoFailure/App.java
 delete mode 100644 maven-embedder/src/test/error-reporting-projects/project-dep-missing/src/test/java/org/apache/maven/test/error/mojoFailure/AppTest.java
 delete mode 100644 maven-embedder/src/test/error-reporting-projects/project-mojo-failure/pom.xml
 delete mode 100644 maven-embedder/src/test/error-reporting-projects/project-mojo-failure/src/main/java/org/apache/maven/test/error/mojoFailure/App.java
 delete mode 100644 maven-embedder/src/test/error-reporting-projects/project-mojo-failure/src/test/java/org/apache/maven/test/error/mojoFailure/AppTest.java
 delete mode 100644 maven-embedder/src/test/error-reporting-projects/project-parse-xex/pom.xml
 delete mode 100644 maven-embedder/src/test/error-reporting-projects/project-validation/pom.xml
 delete mode 100644 maven-embedder/src/test/error-reporting-projects/repo-creation-err/pom.xml
 delete mode 100644 maven-embedder/src/test/eventing-projects/read-with-deps/pom.xml
 delete mode 100644 maven-embedder/src/test/eventing-projects/read-with-deps/repo/tests/dep/1/dep-1.pom
 delete mode 100644 maven-embedder/src/test/eventing-projects/simple-read-project/pom.xml
 delete mode 100644 maven-embedder/src/test/extensions/META-INF/plexus/components.xml
 delete mode 100644 maven-embedder/src/test/plugin-version-references/jar-pom.xml
 delete mode 100644 maven-embedder/src/test/plugin-version-references/maven-plugin-pom.xml
 delete mode 100644 maven-embedder/src/test/projects/bad-module-non-recursive/badmodule/pom.xml
 delete mode 100644 maven-embedder/src/test/projects/bad-module-non-recursive/goodmodule/pom.xml
 delete mode 100644 maven-embedder/src/test/projects/bad-module-non-recursive/pom.xml
 delete mode 100644 maven-embedder/src/test/projects/invalid-goal/pom.xml
 delete mode 100644 maven-embedder/src/test/projects/isolated-project-getting-parent-pom/project/pom.xml
 delete mode 100644 maven-embedder/src/test/projects/isolated-project-getting-parent-pom/project/src/main/java/org/codehaus/m2eclipse/App.java
 delete mode 100644 maven-embedder/src/test/projects/isolated-project-getting-parent-pom/project/src/test/java/org/codehaus/m2eclipse/AppTest.java
 delete mode 100644 maven-embedder/src/test/projects/isolated-project-getting-parent-pom/repository/org/codehaus/m2eclipse/parent/1.0-SNAPSHOT/maven-metadata-company.xml
 delete mode 100644 maven-embedder/src/test/projects/isolated-project-getting-parent-pom/repository/org/codehaus/m2eclipse/parent/1.0-SNAPSHOT/parent-1.0-SNAPSHOT.pom
 delete mode 100644 maven-embedder/src/test/projects/isolated-project-getting-parent-pom/repository/org/codehaus/m2eclipse/parent/maven-metadata-local.xml
 delete mode 100644 maven-embedder/src/test/projects/isolated-project-getting-parent-pom/settings.xml
 delete mode 100644 maven-embedder/src/test/projects/optional-dep/pom.xml
 delete mode 100644 maven-embedder/src/test/projects/readProject-missingModuleIgnored/pom.xml
 delete mode 100644 maven-embedder/src/test/projects/readProject-withScmInheritance/modules/child1/pom.xml
 delete mode 100644 maven-embedder/src/test/projects/readProject-withScmInheritance/pom.xml
 delete mode 100644 maven-embedder/src/test/resources/META-INF/maven/org.apache.maven/maven-core/pom.properties
 delete mode 100644 maven-embedder/src/test/resources/pom-with-distribution-status.xml
 delete mode 100644 maven-embedder/src/test/resources/pom-without-dependencies.xml
 delete mode 100644 maven-embedder/src/test/resources/pom.xml
 delete mode 100644 maven-embedder/src/test/resources/pom2.xml
 delete mode 100644 maven-embedder/src/test/resources/settings/invalid-settings.xml
 delete mode 100644 maven-embedder/src/test/resources/settings/valid-settings.xml
 delete mode 100644 maven-model-builder/src/main/mdo/profiles.mdo


[maven] 01/01: Removing code redundancy Using assertj, JUnit Jupiter

Posted by kh...@apache.org.
This is an automated email from the ASF dual-hosted git repository.

khmarbaise pushed a commit to branch MODELTESTS_IMPROVEMENT
in repository https://gitbox.apache.org/repos/asf/maven.git

commit 4cdd4faf036b8ff5bf0084fda3ba56c6191fee89
Author: Karl Heinz Marbaise <kh...@apache.org>
AuthorDate: Fri Nov 29 00:25:33 2019 +0100

    Removing code redundancy
    Using assertj, JUnit Jupiter
---
 maven-artifact/pom.xml                             |  5 ++
 maven-model/pom.xml                                | 23 +++++++-
 .../org/apache/maven/model/ActivationFileTest.java | 31 ++---------
 .../org/apache/maven/model/ActivationOSTest.java   | 29 +---------
 .../apache/maven/model/ActivationPropertyTest.java | 31 ++---------
 .../org/apache/maven/model/ActivationTest.java     | 31 ++---------
 .../java/org/apache/maven/model/BuildTest.java     | 31 ++---------
 .../org/apache/maven/model/CiManagementTest.java   | 31 ++---------
 .../org/apache/maven/model/ContributorTest.java    | 30 +---------
 .../maven/model/DependencyManagementTest.java      | 29 +---------
 .../org/apache/maven/model/DependencyTest.java     | 29 +---------
 .../maven/model/DeploymentRepositoryTest.java      | 29 +---------
 .../java/org/apache/maven/model/DeveloperTest.java | 29 +---------
 .../maven/model/DistributionManagementTest.java    | 29 +---------
 .../java/org/apache/maven/model/ExclusionTest.java | 29 +---------
 .../java/org/apache/maven/model/ExtensionTest.java | 29 +---------
 .../apache/maven/model/IssueManagementTest.java    | 29 +---------
 .../java/org/apache/maven/model/LicenseTest.java   | 29 +---------
 .../org/apache/maven/model/MailingListTest.java    | 29 +---------
 .../java/org/apache/maven/model/ModelTest.java     | 29 +---------
 .../org/apache/maven/model/ModelTestInterface.java | 65 ++++++++++++++++++++++
 .../java/org/apache/maven/model/NotifierTest.java  | 30 +---------
 .../org/apache/maven/model/OrganizationTest.java   | 30 +---------
 .../java/org/apache/maven/model/ParentTest.java    | 30 +---------
 .../maven/model/PluginConfigurationTest.java       | 29 +---------
 .../apache/maven/model/PluginContainerTest.java    | 29 +---------
 .../apache/maven/model/PluginExecutionTest.java    | 29 +---------
 .../apache/maven/model/PluginManagementTest.java   | 30 +---------
 .../java/org/apache/maven/model/PluginTest.java    | 30 +---------
 .../org/apache/maven/model/PrerequisitesTest.java  | 30 +---------
 .../java/org/apache/maven/model/ProfileTest.java   | 29 +---------
 .../org/apache/maven/model/RelocationTest.java     | 30 +---------
 .../org/apache/maven/model/ReportPluginTest.java   | 30 +---------
 .../java/org/apache/maven/model/ReportSetTest.java | 29 +---------
 .../java/org/apache/maven/model/ReportingTest.java | 30 +---------
 .../apache/maven/model/RepositoryPolicyTest.java   | 29 +---------
 .../org/apache/maven/model/RepositoryTest.java     | 31 ++---------
 .../java/org/apache/maven/model/ResourceTest.java  | 31 ++---------
 .../test/java/org/apache/maven/model/ScmTest.java  | 29 ++--------
 .../test/java/org/apache/maven/model/SiteTest.java | 30 +---------
 pom.xml                                            | 13 +++++
 41 files changed, 224 insertions(+), 980 deletions(-)

diff --git a/maven-artifact/pom.xml b/maven-artifact/pom.xml
index 336505b..5e7b339 100644
--- a/maven-artifact/pom.xml
+++ b/maven-artifact/pom.xml
@@ -41,6 +41,11 @@ under the License.
       <groupId>org.apache.commons</groupId>
       <artifactId>commons-lang3</artifactId>
     </dependency>
+    <dependency>
+      <groupId>org.assertj</groupId>
+      <artifactId>assertj-core</artifactId>
+      <scope>test</scope>
+    </dependency>
   </dependencies>
 
   <build>
diff --git a/maven-model/pom.xml b/maven-model/pom.xml
index f1deea5..8aff60d 100644
--- a/maven-model/pom.xml
+++ b/maven-model/pom.xml
@@ -19,7 +19,8 @@ specific language governing permissions and limitations
 under the License.
 -->
 
-<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 https://maven.apache.org/xsd/maven-4.0.0.xsd">
+<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 https://maven.apache.org/xsd/maven-4.0.0.xsd">
   <modelVersion>4.0.0</modelVersion>
 
   <parent>
@@ -42,11 +43,31 @@ under the License.
       <groupId>org.codehaus.plexus</groupId>
       <artifactId>plexus-utils</artifactId>
     </dependency>
+    <dependency>
+      <groupId>org.junit.jupiter</groupId>
+      <artifactId>junit-jupiter-engine</artifactId>
+      <scope>test</scope>
+    </dependency>
+    <dependency>
+      <groupId>org.assertj</groupId>
+      <artifactId>assertj-core</artifactId>
+      <scope>test</scope>
+    </dependency>
+
   </dependencies>
 
   <build>
     <plugins>
       <plugin>
+        <artifactId>maven-compiler-plugin</artifactId>
+        <configuration>
+          <compilerArgs>
+            <arg>-Xlint:deprecation</arg>
+            <arg>-Xlint:unchecked</arg>
+          </compilerArgs>
+        </configuration>
+      </plugin>
+      <plugin>
         <groupId>org.codehaus.modello</groupId>
         <artifactId>modello-maven-plugin</artifactId>
         <configuration>
diff --git a/maven-model/src/test/java/org/apache/maven/model/ActivationFileTest.java b/maven-model/src/test/java/org/apache/maven/model/ActivationFileTest.java
index f88da58..d86651d 100644
--- a/maven-model/src/test/java/org/apache/maven/model/ActivationFileTest.java
+++ b/maven-model/src/test/java/org/apache/maven/model/ActivationFileTest.java
@@ -19,38 +19,15 @@ package org.apache.maven.model;
  * under the License.
  */
 
-import junit.framework.TestCase;
+import org.junit.jupiter.api.DisplayName;
 
 /**
  * Tests {@code ActivationFile}.
  *
  * @author Benjamin Bentmann
  */
-public class ActivationFileTest
-    extends TestCase
+@DisplayName( "ActivationFile" )
+class ActivationFileTest implements ModelTestInterface< ActivationFile >
 {
-
-    public void testHashCodeNullSafe()
-    {
-        new ActivationFile().hashCode();
-    }
-
-    public void testEqualsNullSafe()
-    {
-        assertFalse( new ActivationFile().equals( null ) );
-
-        new ActivationFile().equals( new ActivationFile() );
-    }
-
-    public void testEqualsIdentity()
-    {
-        ActivationFile thing = new ActivationFile();
-        assertTrue( thing.equals( thing ) );
-    }
-
-    public void testToStringNullSafe()
-    {
-        assertNotNull( new ActivationFile().toString() );
-    }
-
 }
+
diff --git a/maven-model/src/test/java/org/apache/maven/model/ActivationOSTest.java b/maven-model/src/test/java/org/apache/maven/model/ActivationOSTest.java
index f0d3045..5820aed 100644
--- a/maven-model/src/test/java/org/apache/maven/model/ActivationOSTest.java
+++ b/maven-model/src/test/java/org/apache/maven/model/ActivationOSTest.java
@@ -19,38 +19,15 @@ package org.apache.maven.model;
  * under the License.
  */
 
-import junit.framework.TestCase;
+import org.junit.jupiter.api.DisplayName;
 
 /**
  * Tests {@code ActivationOS}.
  *
  * @author Benjamin Bentmann
  */
-public class ActivationOSTest
-    extends TestCase
+@DisplayName( "ActivationOS" )
+class ActivationOSTest implements ModelTestInterface< ActivationOS >
 {
 
-    public void testHashCodeNullSafe()
-    {
-        new ActivationOS().hashCode();
-    }
-
-    public void testEqualsNullSafe()
-    {
-        assertFalse( new ActivationOS().equals( null ) );
-
-        new ActivationOS().equals( new ActivationOS() );
-    }
-
-    public void testEqualsIdentity()
-    {
-        ActivationOS thing = new ActivationOS();
-        assertTrue( thing.equals( thing ) );
-    }
-
-    public void testToStringNullSafe()
-    {
-        assertNotNull( new ActivationOS().toString() );
-    }
-
 }
diff --git a/maven-model/src/test/java/org/apache/maven/model/ActivationPropertyTest.java b/maven-model/src/test/java/org/apache/maven/model/ActivationPropertyTest.java
index 5f5e048..1727d29 100644
--- a/maven-model/src/test/java/org/apache/maven/model/ActivationPropertyTest.java
+++ b/maven-model/src/test/java/org/apache/maven/model/ActivationPropertyTest.java
@@ -19,38 +19,15 @@ package org.apache.maven.model;
  * under the License.
  */
 
-import junit.framework.TestCase;
+import org.junit.jupiter.api.DisplayName;
 
 /**
  * Tests {@code ActivationProperty}.
  *
  * @author Benjamin Bentmann
  */
-public class ActivationPropertyTest
-    extends TestCase
+@DisplayName( "ActivationProperty" )
+class ActivationPropertyTest implements ModelTestInterface< ActivationProperty >
 {
-
-    public void testHashCodeNullSafe()
-    {
-        new ActivationProperty().hashCode();
-    }
-
-    public void testEqualsNullSafe()
-    {
-        assertFalse( new ActivationProperty().equals( null ) );
-
-        new ActivationProperty().equals( new ActivationProperty() );
-    }
-
-    public void testEqualsIdentity()
-    {
-        ActivationProperty thing = new ActivationProperty();
-        assertTrue( thing.equals( thing ) );
-    }
-
-    public void testToStringNullSafe()
-    {
-        assertNotNull( new ActivationProperty().toString() );
-    }
-
 }
+
diff --git a/maven-model/src/test/java/org/apache/maven/model/ActivationTest.java b/maven-model/src/test/java/org/apache/maven/model/ActivationTest.java
index f6d0f91..34d82e1 100644
--- a/maven-model/src/test/java/org/apache/maven/model/ActivationTest.java
+++ b/maven-model/src/test/java/org/apache/maven/model/ActivationTest.java
@@ -19,38 +19,15 @@ package org.apache.maven.model;
  * under the License.
  */
 
-import junit.framework.TestCase;
+import org.junit.jupiter.api.DisplayName;
 
 /**
  * Tests {@code Activation}.
  *
  * @author Benjamin Bentmann
  */
-public class ActivationTest
-    extends TestCase
+@DisplayName( "Activation" )
+class ActivationTest implements ModelTestInterface< Activation >
 {
-
-    public void testHashCodeNullSafe()
-    {
-        new Activation().hashCode();
-    }
-
-    public void testEqualsNullSafe()
-    {
-        assertFalse( new Activation().equals( null ) );
-
-        new Activation().equals( new Activation() );
-    }
-
-    public void testEqualsIdentity()
-    {
-        Activation thing = new Activation();
-        assertTrue( thing.equals( thing ) );
-    }
-
-    public void testToStringNullSafe()
-    {
-        assertNotNull( new Activation().toString() );
-    }
-
 }
+
diff --git a/maven-model/src/test/java/org/apache/maven/model/BuildTest.java b/maven-model/src/test/java/org/apache/maven/model/BuildTest.java
index 80a60d5..e1488ad 100644
--- a/maven-model/src/test/java/org/apache/maven/model/BuildTest.java
+++ b/maven-model/src/test/java/org/apache/maven/model/BuildTest.java
@@ -19,38 +19,15 @@ package org.apache.maven.model;
  * under the License.
  */
 
-import junit.framework.TestCase;
+import org.junit.jupiter.api.DisplayName;
 
 /**
  * Tests {@code Build}.
  *
  * @author Benjamin Bentmann
  */
-public class BuildTest
-    extends TestCase
+@DisplayName( "Build" )
+class BuildTest implements ModelTestInterface< Build >
 {
-
-    public void testHashCodeNullSafe()
-    {
-        new Build().hashCode();
-    }
-
-    public void testEqualsNullSafe()
-    {
-        assertFalse( new Build().equals( null ) );
-
-        new Build().equals( new Build() );
-    }
-
-    public void testEqualsIdentity()
-    {
-        Build thing = new Build();
-        assertTrue( thing.equals( thing ) );
-    }
-
-    public void testToStringNullSafe()
-    {
-        assertNotNull( new Build().toString() );
-    }
-
 }
+
diff --git a/maven-model/src/test/java/org/apache/maven/model/CiManagementTest.java b/maven-model/src/test/java/org/apache/maven/model/CiManagementTest.java
index 7194c84..5dacbfd 100644
--- a/maven-model/src/test/java/org/apache/maven/model/CiManagementTest.java
+++ b/maven-model/src/test/java/org/apache/maven/model/CiManagementTest.java
@@ -19,38 +19,15 @@ package org.apache.maven.model;
  * under the License.
  */
 
-import junit.framework.TestCase;
+import org.junit.jupiter.api.DisplayName;
 
 /**
  * Tests {@code CiManagement}.
  *
  * @author Benjamin Bentmann
  */
-public class CiManagementTest
-    extends TestCase
+@DisplayName( "CiManagement" )
+class CiManagementTest implements ModelTestInterface< CiManagement >
 {
-
-    public void testHashCodeNullSafe()
-    {
-        new CiManagement().hashCode();
-    }
-
-    public void testEqualsNullSafe()
-    {
-        assertFalse( new CiManagement().equals( null ) );
-
-        new CiManagement().equals( new CiManagement() );
-    }
-
-    public void testEqualsIdentity()
-    {
-        CiManagement thing = new CiManagement();
-        assertTrue( thing.equals( thing ) );
-    }
-
-    public void testToStringNullSafe()
-    {
-        assertNotNull( new CiManagement().toString() );
-    }
-
 }
+
diff --git a/maven-model/src/test/java/org/apache/maven/model/ContributorTest.java b/maven-model/src/test/java/org/apache/maven/model/ContributorTest.java
index 491b99a..3853cd1 100644
--- a/maven-model/src/test/java/org/apache/maven/model/ContributorTest.java
+++ b/maven-model/src/test/java/org/apache/maven/model/ContributorTest.java
@@ -19,38 +19,14 @@ package org.apache.maven.model;
  * under the License.
  */
 
-import junit.framework.TestCase;
+import org.junit.jupiter.api.DisplayName;
 
 /**
  * Tests {@code Contributor}.
  *
  * @author Benjamin Bentmann
  */
-public class ContributorTest
-    extends TestCase
+@DisplayName( "Contributore" )
+class ContributorTest implements ModelTestInterface< Contributor >
 {
-
-    public void testHashCodeNullSafe()
-    {
-        new Contributor().hashCode();
-    }
-
-    public void testEqualsNullSafe()
-    {
-        assertFalse( new Contributor().equals( null ) );
-
-        new Contributor().equals( new Contributor() );
-    }
-
-    public void testEqualsIdentity()
-    {
-        Contributor thing = new Contributor();
-        assertTrue( thing.equals( thing ) );
-    }
-
-    public void testToStringNullSafe()
-    {
-        assertNotNull( new Contributor().toString() );
-    }
-
 }
diff --git a/maven-model/src/test/java/org/apache/maven/model/DependencyManagementTest.java b/maven-model/src/test/java/org/apache/maven/model/DependencyManagementTest.java
index 7702c62..d4fd03a 100644
--- a/maven-model/src/test/java/org/apache/maven/model/DependencyManagementTest.java
+++ b/maven-model/src/test/java/org/apache/maven/model/DependencyManagementTest.java
@@ -19,38 +19,15 @@ package org.apache.maven.model;
  * under the License.
  */
 
-import junit.framework.TestCase;
+import org.junit.jupiter.api.DisplayName;
 
 /**
  * Tests {@code DependencyManagement}.
  *
  * @author Benjamin Bentmann
  */
-public class DependencyManagementTest
-    extends TestCase
+@DisplayName( "DependencyManagement" )
+class DependencyManagementTest implements ModelTestInterface< DependencyManagement >
 {
 
-    public void testHashCodeNullSafe()
-    {
-        new DependencyManagement().hashCode();
-    }
-
-    public void testEqualsNullSafe()
-    {
-        assertFalse( new DependencyManagement().equals( null ) );
-
-        new DependencyManagement().equals( new DependencyManagement() );
-    }
-
-    public void testEqualsIdentity()
-    {
-        DependencyManagement thing = new DependencyManagement();
-        assertTrue( thing.equals( thing ) );
-    }
-
-    public void testToStringNullSafe()
-    {
-        assertNotNull( new DependencyManagement().toString() );
-    }
-
 }
diff --git a/maven-model/src/test/java/org/apache/maven/model/DependencyTest.java b/maven-model/src/test/java/org/apache/maven/model/DependencyTest.java
index ec0a833..9438b97 100644
--- a/maven-model/src/test/java/org/apache/maven/model/DependencyTest.java
+++ b/maven-model/src/test/java/org/apache/maven/model/DependencyTest.java
@@ -19,38 +19,15 @@ package org.apache.maven.model;
  * under the License.
  */
 
-import junit.framework.TestCase;
+import org.junit.jupiter.api.DisplayName;
 
 /**
  * Tests {@code Dependency}.
  *
  * @author Benjamin Bentmann
  */
-public class DependencyTest
-    extends TestCase
+@DisplayName( "Dependency" )
+class DependencyTest implements ModelTestInterface< Dependency >
 {
 
-    public void testHashCodeNullSafe()
-    {
-        new Dependency().hashCode();
-    }
-
-    public void testEqualsNullSafe()
-    {
-        assertFalse( new Dependency().equals( null ) );
-
-        new Dependency().equals( new Dependency() );
-    }
-
-    public void testEqualsIdentity()
-    {
-        Dependency thing = new Dependency();
-        assertTrue( thing.equals( thing ) );
-    }
-
-    public void testToStringNullSafe()
-    {
-        assertNotNull( new Dependency().toString() );
-    }
-
 }
diff --git a/maven-model/src/test/java/org/apache/maven/model/DeploymentRepositoryTest.java b/maven-model/src/test/java/org/apache/maven/model/DeploymentRepositoryTest.java
index 169ec65..d598f6d 100644
--- a/maven-model/src/test/java/org/apache/maven/model/DeploymentRepositoryTest.java
+++ b/maven-model/src/test/java/org/apache/maven/model/DeploymentRepositoryTest.java
@@ -19,38 +19,15 @@ package org.apache.maven.model;
  * under the License.
  */
 
-import junit.framework.TestCase;
+import org.junit.jupiter.api.DisplayName;
 
 /**
  * Tests {@code DeploymentRepository}.
  *
  * @author Benjamin Bentmann
  */
-public class DeploymentRepositoryTest
-    extends TestCase
+@DisplayName( "DeploymentRepository" )
+class DeploymentRepositoryTest implements ModelTestInterface< DeploymentRepository >
 {
 
-    public void testHashCodeNullSafe()
-    {
-        new DeploymentRepository().hashCode();
-    }
-
-    public void testEqualsNullSafe()
-    {
-        assertFalse( new DeploymentRepository().equals( null ) );
-
-        new DeploymentRepository().equals( new DeploymentRepository() );
-    }
-
-    public void testEqualsIdentity()
-    {
-        DeploymentRepository thing = new DeploymentRepository();
-        assertTrue( thing.equals( thing ) );
-    }
-
-    public void testToStringNullSafe()
-    {
-        assertNotNull( new DeploymentRepository().toString() );
-    }
-
 }
diff --git a/maven-model/src/test/java/org/apache/maven/model/DeveloperTest.java b/maven-model/src/test/java/org/apache/maven/model/DeveloperTest.java
index c0dfe56..daa0e68 100644
--- a/maven-model/src/test/java/org/apache/maven/model/DeveloperTest.java
+++ b/maven-model/src/test/java/org/apache/maven/model/DeveloperTest.java
@@ -19,38 +19,15 @@ package org.apache.maven.model;
  * under the License.
  */
 
-import junit.framework.TestCase;
+import org.junit.jupiter.api.DisplayName;
 
 /**
  * Tests {@code Developer}.
  *
  * @author Benjamin Bentmann
  */
-public class DeveloperTest
-    extends TestCase
+@DisplayName( "Developer" )
+class DeveloperTest implements ModelTestInterface< Developer >
 {
 
-    public void testHashCodeNullSafe()
-    {
-        new Developer().hashCode();
-    }
-
-    public void testEqualsNullSafe()
-    {
-        assertFalse( new Developer().equals( null ) );
-
-        new Developer().equals( new Developer() );
-    }
-
-    public void testEqualsIdentity()
-    {
-        Developer thing = new Developer();
-        assertTrue( thing.equals( thing ) );
-    }
-
-    public void testToStringNullSafe()
-    {
-        assertNotNull( new Developer().toString() );
-    }
-
 }
diff --git a/maven-model/src/test/java/org/apache/maven/model/DistributionManagementTest.java b/maven-model/src/test/java/org/apache/maven/model/DistributionManagementTest.java
index 0314d61..c514ca0 100644
--- a/maven-model/src/test/java/org/apache/maven/model/DistributionManagementTest.java
+++ b/maven-model/src/test/java/org/apache/maven/model/DistributionManagementTest.java
@@ -19,38 +19,15 @@ package org.apache.maven.model;
  * under the License.
  */
 
-import junit.framework.TestCase;
+import org.junit.jupiter.api.DisplayName;
 
 /**
  * Tests {@code DistributionManagement}.
  *
  * @author Benjamin Bentmann
  */
-public class DistributionManagementTest
-    extends TestCase
+@DisplayName( "DistributionManagement" )
+class DistributionManagementTest implements ModelTestInterface< DistributionManagement >
 {
 
-    public void testHashCodeNullSafe()
-    {
-        new DistributionManagement().hashCode();
-    }
-
-    public void testEqualsNullSafe()
-    {
-        assertFalse( new DistributionManagement().equals( null ) );
-
-        new DistributionManagement().equals( new DistributionManagement() );
-    }
-
-    public void testEqualsIdentity()
-    {
-        DistributionManagement thing = new DistributionManagement();
-        assertTrue( thing.equals( thing ) );
-    }
-
-    public void testToStringNullSafe()
-    {
-        assertNotNull( new DistributionManagement().toString() );
-    }
-
 }
diff --git a/maven-model/src/test/java/org/apache/maven/model/ExclusionTest.java b/maven-model/src/test/java/org/apache/maven/model/ExclusionTest.java
index 6febace..7595866 100644
--- a/maven-model/src/test/java/org/apache/maven/model/ExclusionTest.java
+++ b/maven-model/src/test/java/org/apache/maven/model/ExclusionTest.java
@@ -19,38 +19,15 @@ package org.apache.maven.model;
  * under the License.
  */
 
-import junit.framework.TestCase;
+import org.junit.jupiter.api.DisplayName;
 
 /**
  * Tests {@code Exclusion}.
  *
  * @author Benjamin Bentmann
  */
-public class ExclusionTest
-    extends TestCase
+@DisplayName( "Exclusion" )
+class ExclusionTest implements ModelTestInterface< Exclusion >
 {
 
-    public void testHashCodeNullSafe()
-    {
-        new Exclusion().hashCode();
-    }
-
-    public void testEqualsNullSafe()
-    {
-        assertFalse( new Exclusion().equals( null ) );
-
-        new Exclusion().equals( new Exclusion() );
-    }
-
-    public void testEqualsIdentity()
-    {
-        Exclusion thing = new Exclusion();
-        assertTrue( thing.equals( thing ) );
-    }
-
-    public void testToStringNullSafe()
-    {
-        assertNotNull( new Exclusion().toString() );
-    }
-
 }
diff --git a/maven-model/src/test/java/org/apache/maven/model/ExtensionTest.java b/maven-model/src/test/java/org/apache/maven/model/ExtensionTest.java
index 4b8cd8a..ed39bb5 100644
--- a/maven-model/src/test/java/org/apache/maven/model/ExtensionTest.java
+++ b/maven-model/src/test/java/org/apache/maven/model/ExtensionTest.java
@@ -19,38 +19,15 @@ package org.apache.maven.model;
  * under the License.
  */
 
-import junit.framework.TestCase;
+import org.junit.jupiter.api.DisplayName;
 
 /**
  * Tests {@code Extension}.
  *
  * @author Benjamin Bentmann
  */
-public class ExtensionTest
-    extends TestCase
+@DisplayName( "Extension" )
+class ExtensionTest implements ModelTestInterface< Extension >
 {
 
-    public void testHashCodeNullSafe()
-    {
-        new Extension().hashCode();
-    }
-
-    public void testEqualsNullSafe()
-    {
-        assertFalse( new Extension().equals( null ) );
-
-        new Extension().equals( new Extension() );
-    }
-
-    public void testEqualsIdentity()
-    {
-        Extension thing = new Extension();
-        assertTrue( thing.equals( thing ) );
-    }
-
-    public void testToStringNullSafe()
-    {
-        assertNotNull( new Extension().toString() );
-    }
-
 }
diff --git a/maven-model/src/test/java/org/apache/maven/model/IssueManagementTest.java b/maven-model/src/test/java/org/apache/maven/model/IssueManagementTest.java
index 5e50c15..bdd0b9f 100644
--- a/maven-model/src/test/java/org/apache/maven/model/IssueManagementTest.java
+++ b/maven-model/src/test/java/org/apache/maven/model/IssueManagementTest.java
@@ -19,38 +19,15 @@ package org.apache.maven.model;
  * under the License.
  */
 
-import junit.framework.TestCase;
+import org.junit.jupiter.api.DisplayName;
 
 /**
  * Tests {@code IssueManagement}.
  *
  * @author Benjamin Bentmann
  */
-public class IssueManagementTest
-    extends TestCase
+@DisplayName( "IssueManagement" )
+class IssueManagementTest implements ModelTestInterface< IssueManagement >
 {
 
-    public void testHashCodeNullSafe()
-    {
-        new IssueManagement().hashCode();
-    }
-
-    public void testEqualsNullSafe()
-    {
-        assertFalse( new IssueManagement().equals( null ) );
-
-        new IssueManagement().equals( new IssueManagement() );
-    }
-
-    public void testEqualsIdentity()
-    {
-        IssueManagement thing = new IssueManagement();
-        assertTrue( thing.equals( thing ) );
-    }
-
-    public void testToStringNullSafe()
-    {
-        assertNotNull( new IssueManagement().toString() );
-    }
-
 }
diff --git a/maven-model/src/test/java/org/apache/maven/model/LicenseTest.java b/maven-model/src/test/java/org/apache/maven/model/LicenseTest.java
index 179921b..5fef64a 100644
--- a/maven-model/src/test/java/org/apache/maven/model/LicenseTest.java
+++ b/maven-model/src/test/java/org/apache/maven/model/LicenseTest.java
@@ -19,38 +19,15 @@ package org.apache.maven.model;
  * under the License.
  */
 
-import junit.framework.TestCase;
+import org.junit.jupiter.api.DisplayName;
 
 /**
  * Tests {@code License}.
  *
  * @author Benjamin Bentmann
  */
-public class LicenseTest
-    extends TestCase
+@DisplayName( "License" )
+class LicenseTest implements ModelTestInterface< License >
 {
 
-    public void testHashCodeNullSafe()
-    {
-        new License().hashCode();
-    }
-
-    public void testEqualsNullSafe()
-    {
-        assertFalse( new License().equals( null ) );
-
-        new License().equals( new License() );
-    }
-
-    public void testEqualsIdentity()
-    {
-        License thing = new License();
-        assertTrue( thing.equals( thing ) );
-    }
-
-    public void testToStringNullSafe()
-    {
-        assertNotNull( new License().toString() );
-    }
-
 }
diff --git a/maven-model/src/test/java/org/apache/maven/model/MailingListTest.java b/maven-model/src/test/java/org/apache/maven/model/MailingListTest.java
index 6129695..b2f3ebe 100644
--- a/maven-model/src/test/java/org/apache/maven/model/MailingListTest.java
+++ b/maven-model/src/test/java/org/apache/maven/model/MailingListTest.java
@@ -19,38 +19,15 @@ package org.apache.maven.model;
  * under the License.
  */
 
-import junit.framework.TestCase;
+import org.junit.jupiter.api.DisplayName;
 
 /**
  * Tests {@code MailingList}.
  *
  * @author Benjamin Bentmann
  */
-public class MailingListTest
-    extends TestCase
+@DisplayName( "MailingList" )
+class MailingListTest implements ModelTestInterface< MailingList >
 {
 
-    public void testHashCodeNullSafe()
-    {
-        new MailingList().hashCode();
-    }
-
-    public void testEqualsNullSafe()
-    {
-        assertFalse( new MailingList().equals( null ) );
-
-        new MailingList().equals( new MailingList() );
-    }
-
-    public void testEqualsIdentity()
-    {
-        MailingList thing = new MailingList();
-        assertTrue( thing.equals( thing ) );
-    }
-
-    public void testToStringNullSafe()
-    {
-        assertNotNull( new MailingList().toString() );
-    }
-
 }
diff --git a/maven-model/src/test/java/org/apache/maven/model/ModelTest.java b/maven-model/src/test/java/org/apache/maven/model/ModelTest.java
index c9ec4da..2a16ba5 100644
--- a/maven-model/src/test/java/org/apache/maven/model/ModelTest.java
+++ b/maven-model/src/test/java/org/apache/maven/model/ModelTest.java
@@ -19,38 +19,15 @@ package org.apache.maven.model;
  * under the License.
  */
 
-import junit.framework.TestCase;
+import org.junit.jupiter.api.DisplayName;
 
 /**
  * Tests {@code Model}.
  *
  * @author Benjamin Bentmann
  */
-public class ModelTest
-    extends TestCase
+@DisplayName( "Model" )
+class ModelTest implements ModelTestInterface< Model >
 {
 
-    public void testHashCodeNullSafe()
-    {
-        new Model().hashCode();
-    }
-
-    public void testEqualsNullSafe()
-    {
-        assertFalse( new Model().equals( null ) );
-
-        new Model().equals( new Model() );
-    }
-
-    public void testEqualsIdentity()
-    {
-        Model thing = new Model();
-        assertTrue( thing.equals( thing ) );
-    }
-
-    public void testToStringNullSafe()
-    {
-        assertNotNull( new Model().toString() );
-    }
-
 }
diff --git a/maven-model/src/test/java/org/apache/maven/model/ModelTestInterface.java b/maven-model/src/test/java/org/apache/maven/model/ModelTestInterface.java
new file mode 100644
index 0000000..d8108de
--- /dev/null
+++ b/maven-model/src/test/java/org/apache/maven/model/ModelTestInterface.java
@@ -0,0 +1,65 @@
+package org.apache.maven.model;
+
+/*
+ * Licensed to the Apache Software Foundation (ASF) under one
+ * or more contributor license agreements.  See the NOTICE file
+ * distributed with this work for additional information
+ * regarding copyright ownership.  The ASF licenses this file
+ * to you under the Apache License, Version 2.0 (the
+ * "License"); you may not use this file except in compliance
+ * with the License.  You may obtain a copy of the License at
+ *
+ *   http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing,
+ * software distributed under the License is distributed on an
+ * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+ * KIND, either express or implied.  See the License for the
+ * specific language governing permissions and limitations
+ * under the License.
+ */
+
+import org.junit.jupiter.api.DisplayName;
+import org.junit.jupiter.api.Test;
+
+import static org.assertj.core.api.Assertions.assertThat;
+import static org.assertj.core.api.Assertions.assertThatCode;
+
+interface ModelTestInterface< T >
+{
+    @SuppressWarnings( "unchecked" )
+    default T createNewInstance(Class< ? > x) throws ReflectiveOperationException
+    {
+        return ( T ) x.getDeclaredConstructor().newInstance();
+    }
+
+    @Test
+    @DisplayName( "hashCode should not fail with null." )
+    default void hashCodeNullSafe()
+    {
+        assertThatCode( () -> createNewInstance( this.getClass() ).hashCode() ).doesNotThrowAnyException();
+    }
+
+    @Test
+    @DisplayName( "equals should not fail with null." )
+    default void equalsNullSafe() throws ReflectiveOperationException
+    {
+        assertThat( createNewInstance( this.getClass() ).equals( null ) ).isFalse();
+    }
+
+    @Test
+    @DisplayName( "equals should result in false for two different instances." )
+    default void equalsSameToBeFalse() throws ReflectiveOperationException
+    {
+        T firstInstance = createNewInstance( this.getClass() );
+        T secondInstance = createNewInstance( this.getClass() );
+        assertThat( firstInstance.equals( secondInstance ) ).isFalse();
+    }
+
+    @Test
+    @DisplayName( "toString should not be null." )
+    default void toStringNullSafe() throws ReflectiveOperationException
+    {
+        assertThat( createNewInstance( this.getClass() ).toString() ).isNotNull();
+    }
+}
diff --git a/maven-model/src/test/java/org/apache/maven/model/NotifierTest.java b/maven-model/src/test/java/org/apache/maven/model/NotifierTest.java
index 4e5d068..ab4defb 100644
--- a/maven-model/src/test/java/org/apache/maven/model/NotifierTest.java
+++ b/maven-model/src/test/java/org/apache/maven/model/NotifierTest.java
@@ -19,38 +19,14 @@ package org.apache.maven.model;
  * under the License.
  */
 
-import junit.framework.TestCase;
+import org.junit.jupiter.api.DisplayName;
 
 /**
  * Tests {@code Notifier}.
  *
  * @author Benjamin Bentmann
  */
-public class NotifierTest
-    extends TestCase
+@DisplayName( "Notifier" )
+class NotifierTest implements ModelTestInterface< Notifier >
 {
-
-    public void testHashCodeNullSafe()
-    {
-        new Notifier().hashCode();
-    }
-
-    public void testEqualsNullSafe()
-    {
-        assertFalse( new Notifier().equals( null ) );
-
-        new Notifier().equals( new Notifier() );
-    }
-
-    public void testEqualsIdentity()
-    {
-        Notifier thing = new Notifier();
-        assertTrue( thing.equals( thing ) );
-    }
-
-    public void testToStringNullSafe()
-    {
-        assertNotNull( new Notifier().toString() );
-    }
-
 }
diff --git a/maven-model/src/test/java/org/apache/maven/model/OrganizationTest.java b/maven-model/src/test/java/org/apache/maven/model/OrganizationTest.java
index 48abe77..ef5eb4f 100644
--- a/maven-model/src/test/java/org/apache/maven/model/OrganizationTest.java
+++ b/maven-model/src/test/java/org/apache/maven/model/OrganizationTest.java
@@ -19,38 +19,14 @@ package org.apache.maven.model;
  * under the License.
  */
 
-import junit.framework.TestCase;
+import org.junit.jupiter.api.DisplayName;
 
 /**
  * Tests {@code Organization}.
  *
  * @author Benjamin Bentmann
  */
-public class OrganizationTest
-    extends TestCase
+@DisplayName( "Organization" )
+class OrganizationTest implements ModelTestInterface< Organization >
 {
-
-    public void testHashCodeNullSafe()
-    {
-        new Organization().hashCode();
-    }
-
-    public void testEqualsNullSafe()
-    {
-        assertFalse( new Organization().equals( null ) );
-
-        new Organization().equals( new Organization() );
-    }
-
-    public void testEqualsIdentity()
-    {
-        Organization thing = new Organization();
-        assertTrue( thing.equals( thing ) );
-    }
-
-    public void testToStringNullSafe()
-    {
-        assertNotNull( new Organization().toString() );
-    }
-
 }
diff --git a/maven-model/src/test/java/org/apache/maven/model/ParentTest.java b/maven-model/src/test/java/org/apache/maven/model/ParentTest.java
index 78d4567..3419438 100644
--- a/maven-model/src/test/java/org/apache/maven/model/ParentTest.java
+++ b/maven-model/src/test/java/org/apache/maven/model/ParentTest.java
@@ -19,38 +19,14 @@ package org.apache.maven.model;
  * under the License.
  */
 
-import junit.framework.TestCase;
+import org.junit.jupiter.api.DisplayName;
 
 /**
  * Tests {@code Parent}.
  *
  * @author Benjamin Bentmann
  */
-public class ParentTest
-    extends TestCase
+@DisplayName( "Parent" )
+class ParentTest implements ModelTestInterface< Parent >
 {
-
-    public void testHashCodeNullSafe()
-    {
-        new Parent().hashCode();
-    }
-
-    public void testEqualsNullSafe()
-    {
-        assertFalse( new Parent().equals( null ) );
-
-        new Parent().equals( new Parent() );
-    }
-
-    public void testEqualsIdentity()
-    {
-        Parent thing = new Parent();
-        assertTrue( thing.equals( thing ) );
-    }
-
-    public void testToStringNullSafe()
-    {
-        assertNotNull( new Parent().toString() );
-    }
-
 }
diff --git a/maven-model/src/test/java/org/apache/maven/model/PluginConfigurationTest.java b/maven-model/src/test/java/org/apache/maven/model/PluginConfigurationTest.java
index cbb123d..39642ba 100644
--- a/maven-model/src/test/java/org/apache/maven/model/PluginConfigurationTest.java
+++ b/maven-model/src/test/java/org/apache/maven/model/PluginConfigurationTest.java
@@ -19,38 +19,15 @@ package org.apache.maven.model;
  * under the License.
  */
 
-import junit.framework.TestCase;
+import org.junit.jupiter.api.DisplayName;
 
 /**
  * Tests {@code PluginConfiguration}.
  *
  * @author Benjamin Bentmann
  */
-public class PluginConfigurationTest
-    extends TestCase
+@DisplayName( "PluginConfiguration" )
+class PluginConfigurationTest implements ModelTestInterface< PluginConfiguration >
 {
 
-    public void testHashCodeNullSafe()
-    {
-        new PluginConfiguration().hashCode();
-    }
-
-    public void testEqualsNullSafe()
-    {
-        assertFalse( new PluginConfiguration().equals( null ) );
-
-        new PluginConfiguration().equals( new PluginConfiguration() );
-    }
-
-    public void testEqualsIdentity()
-    {
-        PluginConfiguration thing = new PluginConfiguration();
-        assertTrue( thing.equals( thing ) );
-    }
-
-    public void testToStringNullSafe()
-    {
-        assertNotNull( new PluginConfiguration().toString() );
-    }
-
 }
diff --git a/maven-model/src/test/java/org/apache/maven/model/PluginContainerTest.java b/maven-model/src/test/java/org/apache/maven/model/PluginContainerTest.java
index 878298c..9aab597 100644
--- a/maven-model/src/test/java/org/apache/maven/model/PluginContainerTest.java
+++ b/maven-model/src/test/java/org/apache/maven/model/PluginContainerTest.java
@@ -19,38 +19,15 @@ package org.apache.maven.model;
  * under the License.
  */
 
-import junit.framework.TestCase;
+import org.junit.jupiter.api.DisplayName;
 
 /**
  * Tests {@code PluginContainer}.
  *
  * @author Benjamin Bentmann
  */
-public class PluginContainerTest
-    extends TestCase
+@DisplayName( "PluginContainer" )
+class PluginContainerTest implements ModelTestInterface< PluginContainer >
 {
 
-    public void testHashCodeNullSafe()
-    {
-        new PluginContainer().hashCode();
-    }
-
-    public void testEqualsNullSafe()
-    {
-        assertFalse( new PluginContainer().equals( null ) );
-
-        new PluginContainer().equals( new PluginContainer() );
-    }
-
-    public void testEqualsIdentity()
-    {
-        PluginContainer thing = new PluginContainer();
-        assertTrue( thing.equals( thing ) );
-    }
-
-    public void testToStringNullSafe()
-    {
-        assertNotNull( new PluginContainer().toString() );
-    }
-
 }
diff --git a/maven-model/src/test/java/org/apache/maven/model/PluginExecutionTest.java b/maven-model/src/test/java/org/apache/maven/model/PluginExecutionTest.java
index e8fff51..8bd1241 100644
--- a/maven-model/src/test/java/org/apache/maven/model/PluginExecutionTest.java
+++ b/maven-model/src/test/java/org/apache/maven/model/PluginExecutionTest.java
@@ -19,38 +19,15 @@ package org.apache.maven.model;
  * under the License.
  */
 
-import junit.framework.TestCase;
+import org.junit.jupiter.api.DisplayName;
 
 /**
  * Tests {@code PluginExecution}.
  *
  * @author Benjamin Bentmann
  */
-public class PluginExecutionTest
-    extends TestCase
+@DisplayName( "PluginExecution" )
+class PluginExecutionTest implements ModelTestInterface< PluginExecution >
 {
 
-    public void testHashCodeNullSafe()
-    {
-        new PluginExecution().hashCode();
-    }
-
-    public void testEqualsNullSafe()
-    {
-        assertFalse( new PluginExecution().equals( null ) );
-
-        new PluginExecution().equals( new PluginExecution() );
-    }
-
-    public void testEqualsIdentity()
-    {
-        PluginExecution thing = new PluginExecution();
-        assertTrue( thing.equals( thing ) );
-    }
-
-    public void testToStringNullSafe()
-    {
-        assertNotNull( new PluginExecution().toString() );
-    }
-
 }
diff --git a/maven-model/src/test/java/org/apache/maven/model/PluginManagementTest.java b/maven-model/src/test/java/org/apache/maven/model/PluginManagementTest.java
index 571399f..d53450a 100644
--- a/maven-model/src/test/java/org/apache/maven/model/PluginManagementTest.java
+++ b/maven-model/src/test/java/org/apache/maven/model/PluginManagementTest.java
@@ -19,38 +19,14 @@ package org.apache.maven.model;
  * under the License.
  */
 
-import junit.framework.TestCase;
+import org.junit.jupiter.api.DisplayName;
 
 /**
  * Tests {@code PluginManagement}.
  *
  * @author Benjamin Bentmann
  */
-public class PluginManagementTest
-    extends TestCase
+@DisplayName( "PluginManagement" )
+class PluginManagementTest implements ModelTestInterface< PluginManagement >
 {
-
-    public void testHashCodeNullSafe()
-    {
-        new PluginManagement().hashCode();
-    }
-
-    public void testEqualsNullSafe()
-    {
-        assertFalse( new PluginManagement().equals( null ) );
-
-        new PluginManagement().equals( new PluginManagement() );
-    }
-
-    public void testEqualsIdentity()
-    {
-        PluginManagement thing = new PluginManagement();
-        assertTrue( thing.equals( thing ) );
-    }
-
-    public void testToStringNullSafe()
-    {
-        assertNotNull( new PluginManagement().toString() );
-    }
-
 }
diff --git a/maven-model/src/test/java/org/apache/maven/model/PluginTest.java b/maven-model/src/test/java/org/apache/maven/model/PluginTest.java
index 582145e..f75a9f1 100644
--- a/maven-model/src/test/java/org/apache/maven/model/PluginTest.java
+++ b/maven-model/src/test/java/org/apache/maven/model/PluginTest.java
@@ -19,38 +19,14 @@ package org.apache.maven.model;
  * under the License.
  */
 
-import junit.framework.TestCase;
+import org.junit.jupiter.api.DisplayName;
 
 /**
  * Tests {@code Plugin}.
  *
  * @author Benjamin Bentmann
  */
-public class PluginTest
-    extends TestCase
+@DisplayName( "Plugin" )
+class PluginTest implements ModelTestInterface< Plugin >
 {
-
-    public void testHashCodeNullSafe()
-    {
-        new Plugin().hashCode();
-    }
-
-    public void testEqualsNullSafe()
-    {
-        assertFalse( new Plugin().equals( null ) );
-
-        new Plugin().equals( new Plugin() );
-    }
-
-    public void testEqualsIdentity()
-    {
-        Plugin thing = new Plugin();
-        assertTrue( thing.equals( thing ) );
-    }
-
-    public void testToStringNullSafe()
-    {
-        assertNotNull( new Plugin().toString() );
-    }
-
 }
diff --git a/maven-model/src/test/java/org/apache/maven/model/PrerequisitesTest.java b/maven-model/src/test/java/org/apache/maven/model/PrerequisitesTest.java
index 727f2c3..c3b3150 100644
--- a/maven-model/src/test/java/org/apache/maven/model/PrerequisitesTest.java
+++ b/maven-model/src/test/java/org/apache/maven/model/PrerequisitesTest.java
@@ -19,38 +19,14 @@ package org.apache.maven.model;
  * under the License.
  */
 
-import junit.framework.TestCase;
+import org.junit.jupiter.api.DisplayName;
 
 /**
  * Tests {@code Prerequisites}.
  *
  * @author Benjamin Bentmann
  */
-public class PrerequisitesTest
-    extends TestCase
+@DisplayName( "Prerequisites" )
+class PrerequisitesTest implements ModelTestInterface< Prerequisites >
 {
-
-    public void testHashCodeNullSafe()
-    {
-        new Prerequisites().hashCode();
-    }
-
-    public void testEqualsNullSafe()
-    {
-        assertFalse( new Prerequisites().equals( null ) );
-
-        new Prerequisites().equals( new Prerequisites() );
-    }
-
-    public void testEqualsIdentity()
-    {
-        Prerequisites thing = new Prerequisites();
-        assertTrue( thing.equals( thing ) );
-    }
-
-    public void testToStringNullSafe()
-    {
-        assertNotNull( new Prerequisites().toString() );
-    }
-
 }
diff --git a/maven-model/src/test/java/org/apache/maven/model/ProfileTest.java b/maven-model/src/test/java/org/apache/maven/model/ProfileTest.java
index 512e2a8..921fca3 100644
--- a/maven-model/src/test/java/org/apache/maven/model/ProfileTest.java
+++ b/maven-model/src/test/java/org/apache/maven/model/ProfileTest.java
@@ -19,38 +19,15 @@ package org.apache.maven.model;
  * under the License.
  */
 
-import junit.framework.TestCase;
+import org.junit.jupiter.api.DisplayName;
 
 /**
  * Tests {@code Profile}.
  *
  * @author Benjamin Bentmann
  */
-public class ProfileTest
-    extends TestCase
+@DisplayName( "Profile" )
+class ProfileTest implements ModelTestInterface< Profile >
 {
 
-    public void testHashCodeNullSafe()
-    {
-        new Profile().hashCode();
-    }
-
-    public void testEqualsNullSafe()
-    {
-        assertFalse( new Profile().equals( null ) );
-
-        new Profile().equals( new Profile() );
-    }
-
-    public void testEqualsIdentity()
-    {
-        Profile thing = new Profile();
-        assertTrue( thing.equals( thing ) );
-    }
-
-    public void testToStringNullSafe()
-    {
-        assertNotNull( new Profile().toString() );
-    }
-
 }
diff --git a/maven-model/src/test/java/org/apache/maven/model/RelocationTest.java b/maven-model/src/test/java/org/apache/maven/model/RelocationTest.java
index 265304d..92dd309 100644
--- a/maven-model/src/test/java/org/apache/maven/model/RelocationTest.java
+++ b/maven-model/src/test/java/org/apache/maven/model/RelocationTest.java
@@ -19,38 +19,14 @@ package org.apache.maven.model;
  * under the License.
  */
 
-import junit.framework.TestCase;
+import org.junit.jupiter.api.DisplayName;
 
 /**
  * Tests {@code Relocation}.
  *
  * @author Benjamin Bentmann
  */
-public class RelocationTest
-    extends TestCase
+@DisplayName( "Relocation" )
+class RelocationTest implements ModelTestInterface< Relocation >
 {
-
-    public void testHashCodeNullSafe()
-    {
-        new Relocation().hashCode();
-    }
-
-    public void testEqualsNullSafe()
-    {
-        assertFalse( new Relocation().equals( null ) );
-
-        new Relocation().equals( new Relocation() );
-    }
-
-    public void testEqualsIdentity()
-    {
-        Relocation thing = new Relocation();
-        assertTrue( thing.equals( thing ) );
-    }
-
-    public void testToStringNullSafe()
-    {
-        assertNotNull( new Relocation().toString() );
-    }
-
 }
diff --git a/maven-model/src/test/java/org/apache/maven/model/ReportPluginTest.java b/maven-model/src/test/java/org/apache/maven/model/ReportPluginTest.java
index d10cb79..15c6586 100644
--- a/maven-model/src/test/java/org/apache/maven/model/ReportPluginTest.java
+++ b/maven-model/src/test/java/org/apache/maven/model/ReportPluginTest.java
@@ -19,38 +19,14 @@ package org.apache.maven.model;
  * under the License.
  */
 
-import junit.framework.TestCase;
+import org.junit.jupiter.api.DisplayName;
 
 /**
  * Tests {@code ReportPlugin}.
  *
  * @author Benjamin Bentmann
  */
-public class ReportPluginTest
-    extends TestCase
+@DisplayName( "ReportPlugin" )
+class ReportPluginTest implements ModelTestInterface< ReportPlugin >
 {
-
-    public void testHashCodeNullSafe()
-    {
-        new ReportPlugin().hashCode();
-    }
-
-    public void testEqualsNullSafe()
-    {
-        assertFalse( new ReportPlugin().equals( null ) );
-
-        new ReportPlugin().equals( new ReportPlugin() );
-    }
-
-    public void testEqualsIdentity()
-    {
-        ReportPlugin thing = new ReportPlugin();
-        assertTrue( thing.equals( thing ) );
-    }
-
-    public void testToStringNullSafe()
-    {
-        assertNotNull( new ReportPlugin().toString() );
-    }
-
 }
diff --git a/maven-model/src/test/java/org/apache/maven/model/ReportSetTest.java b/maven-model/src/test/java/org/apache/maven/model/ReportSetTest.java
index 2f51415..864c9c9 100644
--- a/maven-model/src/test/java/org/apache/maven/model/ReportSetTest.java
+++ b/maven-model/src/test/java/org/apache/maven/model/ReportSetTest.java
@@ -19,38 +19,15 @@ package org.apache.maven.model;
  * under the License.
  */
 
-import junit.framework.TestCase;
+import org.junit.jupiter.api.DisplayName;
 
 /**
  * Tests {@code ReportSet}.
  *
  * @author Benjamin Bentmann
  */
-public class ReportSetTest
-    extends TestCase
+@DisplayName( "ReportSet" )
+class ReportSetTest implements ModelTestInterface< ReportSet >
 {
 
-    public void testHashCodeNullSafe()
-    {
-        new ReportSet().hashCode();
-    }
-
-    public void testEqualsNullSafe()
-    {
-        assertFalse( new ReportSet().equals( null ) );
-
-        new ReportSet().equals( new ReportSet() );
-    }
-
-    public void testEqualsIdentity()
-    {
-        ReportSet thing = new ReportSet();
-        assertTrue( thing.equals( thing ) );
-    }
-
-    public void testToStringNullSafe()
-    {
-        assertNotNull( new ReportSet().toString() );
-    }
-
 }
diff --git a/maven-model/src/test/java/org/apache/maven/model/ReportingTest.java b/maven-model/src/test/java/org/apache/maven/model/ReportingTest.java
index dbc0fa2..063b1e5 100644
--- a/maven-model/src/test/java/org/apache/maven/model/ReportingTest.java
+++ b/maven-model/src/test/java/org/apache/maven/model/ReportingTest.java
@@ -19,38 +19,14 @@ package org.apache.maven.model;
  * under the License.
  */
 
-import junit.framework.TestCase;
+import org.junit.jupiter.api.DisplayName;
 
 /**
  * Tests {@code Reporting}.
  *
  * @author Benjamin Bentmann
  */
-public class ReportingTest
-    extends TestCase
+@DisplayName( "Reporting" )
+class ReportingTest implements ModelTestInterface< Reporting >
 {
-
-    public void testHashCodeNullSafe()
-    {
-        new Reporting().hashCode();
-    }
-
-    public void testEqualsNullSafe()
-    {
-        assertFalse( new Reporting().equals( null ) );
-
-        new Reporting().equals( new Reporting() );
-    }
-
-    public void testEqualsIdentity()
-    {
-        Reporting thing = new Reporting();
-        assertTrue( thing.equals( thing ) );
-    }
-
-    public void testToStringNullSafe()
-    {
-        assertNotNull( new Reporting().toString() );
-    }
-
 }
diff --git a/maven-model/src/test/java/org/apache/maven/model/RepositoryPolicyTest.java b/maven-model/src/test/java/org/apache/maven/model/RepositoryPolicyTest.java
index 3ae3435..71c2b71 100644
--- a/maven-model/src/test/java/org/apache/maven/model/RepositoryPolicyTest.java
+++ b/maven-model/src/test/java/org/apache/maven/model/RepositoryPolicyTest.java
@@ -19,38 +19,15 @@ package org.apache.maven.model;
  * under the License.
  */
 
-import junit.framework.TestCase;
+import org.junit.jupiter.api.DisplayName;
 
 /**
  * Tests {@code RepositoryPolicy}.
  *
  * @author Benjamin Bentmann
  */
-public class RepositoryPolicyTest
-    extends TestCase
+@DisplayName( "RepositoryPolicy" )
+class RepositoryPolicyTest implements ModelTestInterface< RepositoryPolicy >
 {
 
-    public void testHashCodeNullSafe()
-    {
-        new RepositoryPolicy().hashCode();
-    }
-
-    public void testEqualsNullSafe()
-    {
-        assertFalse( new RepositoryPolicy().equals( null ) );
-
-        new RepositoryPolicy().equals( new RepositoryPolicy() );
-    }
-
-    public void testEqualsIdentity()
-    {
-        RepositoryPolicy thing = new RepositoryPolicy();
-        assertTrue( thing.equals( thing ) );
-    }
-
-    public void testToStringNullSafe()
-    {
-        assertNotNull( new RepositoryPolicy().toString() );
-    }
-
 }
diff --git a/maven-model/src/test/java/org/apache/maven/model/RepositoryTest.java b/maven-model/src/test/java/org/apache/maven/model/RepositoryTest.java
index b68b70a..713fa4a 100644
--- a/maven-model/src/test/java/org/apache/maven/model/RepositoryTest.java
+++ b/maven-model/src/test/java/org/apache/maven/model/RepositoryTest.java
@@ -19,38 +19,15 @@ package org.apache.maven.model;
  * under the License.
  */
 
-import junit.framework.TestCase;
+import org.junit.jupiter.api.DisplayName;
 
 /**
  * Tests {@code Repository}.
  *
  * @author Benjamin Bentmann
  */
-public class RepositoryTest
-    extends TestCase
+@DisplayName( "Repository" )
+class RepositoryTest implements ModelTestInterface< Repository >
 {
-
-    public void testHashCodeNullSafe()
-    {
-        new Repository().hashCode();
-    }
-
-    public void testEqualsNullSafe()
-    {
-        assertFalse( new Repository().equals( null ) );
-
-        new Repository().equals( new Repository() );
-    }
-
-    public void testEqualsIdentity()
-    {
-        Repository thing = new Repository();
-        assertTrue( thing.equals( thing ) );
-    }
-
-    public void testToStringNullSafe()
-    {
-        assertNotNull( new Repository().toString() );
-    }
-
 }
+
diff --git a/maven-model/src/test/java/org/apache/maven/model/ResourceTest.java b/maven-model/src/test/java/org/apache/maven/model/ResourceTest.java
index fa40ab4..d09a3c6 100644
--- a/maven-model/src/test/java/org/apache/maven/model/ResourceTest.java
+++ b/maven-model/src/test/java/org/apache/maven/model/ResourceTest.java
@@ -19,38 +19,15 @@ package org.apache.maven.model;
  * under the License.
  */
 
-import junit.framework.TestCase;
+import org.junit.jupiter.api.DisplayName;
 
 /**
  * Tests {@code Resource}.
  *
  * @author Benjamin Bentmann
  */
-public class ResourceTest
-    extends TestCase
+@DisplayName( "Resource" )
+class ResourceTest implements ModelTestInterface< Resource >
 {
-
-    public void testHashCodeNullSafe()
-    {
-        new Resource().hashCode();
-    }
-
-    public void testEqualsNullSafe()
-    {
-        assertFalse( new Resource().equals( null ) );
-
-        new Resource().equals( new Resource() );
-    }
-
-    public void testEqualsIdentity()
-    {
-        Resource thing = new Resource();
-        assertTrue( thing.equals( thing ) );
-    }
-
-    public void testToStringNullSafe()
-    {
-        assertNotNull( new Resource().toString() );
-    }
-
 }
+
diff --git a/maven-model/src/test/java/org/apache/maven/model/ScmTest.java b/maven-model/src/test/java/org/apache/maven/model/ScmTest.java
index 4d76993..b244fb5 100644
--- a/maven-model/src/test/java/org/apache/maven/model/ScmTest.java
+++ b/maven-model/src/test/java/org/apache/maven/model/ScmTest.java
@@ -19,38 +19,17 @@ package org.apache.maven.model;
  * under the License.
  */
 
-import junit.framework.TestCase;
+import org.junit.jupiter.api.DisplayName;
 
 /**
  * Tests {@code Scm}.
  *
  * @author Benjamin Bentmann
  */
-public class ScmTest
-    extends TestCase
+@DisplayName( "Scm" )
+class ScmTest implements ModelTestInterface< Scm >
 {
 
-    public void testHashCodeNullSafe()
-    {
-        new Scm().hashCode();
-    }
-
-    public void testEqualsNullSafe()
-    {
-        assertFalse( new Scm().equals( null ) );
-
-        new Scm().equals( new Scm() );
-    }
-
-    public void testEqualsIdentity()
-    {
-        Scm thing = new Scm();
-        assertTrue( thing.equals( thing ) );
-    }
+}
 
-    public void testToStringNullSafe()
-    {
-        assertNotNull( new Scm().toString() );
-    }
 
-}
diff --git a/maven-model/src/test/java/org/apache/maven/model/SiteTest.java b/maven-model/src/test/java/org/apache/maven/model/SiteTest.java
index 84896bb..1d96718 100644
--- a/maven-model/src/test/java/org/apache/maven/model/SiteTest.java
+++ b/maven-model/src/test/java/org/apache/maven/model/SiteTest.java
@@ -19,38 +19,14 @@ package org.apache.maven.model;
  * under the License.
  */
 
-import junit.framework.TestCase;
+import org.junit.jupiter.api.DisplayName;
 
 /**
  * Tests {@code Site}.
  *
  * @author Benjamin Bentmann
  */
-public class SiteTest
-    extends TestCase
+@DisplayName( "Site" )
+class SiteTest implements ModelTestInterface< Site >
 {
-
-    public void testHashCodeNullSafe()
-    {
-        new Site().hashCode();
-    }
-
-    public void testEqualsNullSafe()
-    {
-        assertFalse( new Site().equals( null ) );
-
-        new Site().equals( new Site() );
-    }
-
-    public void testEqualsIdentity()
-    {
-        Site thing = new Site();
-        assertTrue( thing.equals( thing ) );
-    }
-
-    public void testToStringNullSafe()
-    {
-        assertNotNull( new Site().toString() );
-    }
-
 }
diff --git a/pom.xml b/pom.xml
index d36ad7e..0c5f68b 100644
--- a/pom.xml
+++ b/pom.xml
@@ -446,6 +446,19 @@ under the License.
         <version>1.3</version>
         <scope>test</scope>
       </dependency>
+      <dependency>
+        <groupId>org.assertj</groupId>
+        <artifactId>assertj-core</artifactId>
+        <version>3.14.0</version>
+        <scope>test</scope>
+      </dependency>
+      <dependency>
+        <groupId>org.junit</groupId>
+        <artifactId>junit-bom</artifactId>
+        <version>5.5.2</version>
+        <type>pom</type>
+        <scope>import</scope>
+      </dependency>
     </dependencies>
     <!--bootstrap-start-comment-->
   </dependencyManagement>