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

slachiewicz pushed a commit to branch master
in repository https://gitbox.apache.org/repos/asf/maven-archetype.git


The following commit(s) were added to refs/heads/master by this push:
     new 403cee98 Document how to run one IT and how the test fixtures are built
403cee98 is described below

commit 403cee982b6ad48d9c626292e04b9c23a04c871c
Author: Sylwester Lachiewicz <[email protected]>
AuthorDate: Sat Oct 31 17:49:22 2026 +0000

    Document how to run one IT and how the test fixtures are built
---
 AGENTS.md | 27 +++++++++++++++++++++++++++
 1 file changed, 27 insertions(+)

diff --git a/AGENTS.md b/AGENTS.md
index c413f42c..7b4cd867 100644
--- a/AGENTS.md
+++ b/AGENTS.md
@@ -30,3 +30,30 @@ Agents that scan this repository should consult 
`SECURITY.md` and the
 threat model it links before reporting issues.
 
 Points at the Apache Maven family umbrella security model.
+
+## Building and testing
+
+The Java floor is 8 (`javaVersion` 8 from maven-parent, compiled with 
`--release 8`) and the plugin
+requires Maven 3.9.0. Use no Java 9+ APIs in main or test code.
+
+Run a single plugin integration test from the repository root. The ITs are off 
by default and
+start with the `run-its` profile; `-DskipTests` skips the unit tests, and 
`-am` builds the modules
+the plugin depends on first:
+
+```
+mvn -B -pl maven-archetype-plugin -am verify -P run-its -DskipTests 
-Dinvoker.test=create-1
+```
+
+`-Dinvoker.test` takes a comma-separated list of directories under 
`maven-archetype-plugin/src/it/projects`.
+The log of each one is in 
`maven-archetype-plugin/target/it/logs/<name>/build.log`.
+
+The unit tests of `archetype-common` read their archetypes from a repository 
layout that the build
+creates in `process-test-resources`. The `maven-antrun-plugin` executions in 
`archetype-common/pom.xml`
+jar each directory of `archetype-common/src/test/archetypes` (`basic-1.0`, 
`partial-1.0`, `site-1.0`,
+`old-1.0`, `fileset-1.0`, `fileset_with_postscript-1.0`) and copy the jar, 
together with its
+`META-INF/maven/archetypes/<name>/pom.xml`, to
+`target/test-classes/repositories/central/archetypes/<name>/<version>/`. Edit 
the directory under
+`src/test/archetypes`, never the jar under `target`.
+
+`InternalCatalogArchetypesVerificationTest` generates a project from every 
archetype in the internal
+catalog and downloads them from Maven Central, so it fails offline.

Reply via email to