Karm / mandrel-integration-tests

Integration tests for GraalVM and its Mandrel distribution. Runs Quarkus, Helidon and Micronaut applications and small targeted reproducers. The focus is solely on native-image utility and compilation of Java applications into native executables.
Apache License 2.0
5 stars 3 forks source link

Adds test method annotation IfMandrelVersion #38

Closed Karm closed 3 years ago

Karm commented 3 years ago

Examples:

    @IfMandrelVersion(min = "20.1", max="20.3.2")

    @IfMandrelVersion(min = "21.1", inContainer = true)

    @IfMandrelVersion(min = "20.1.0.4", max = "20.3.2")

    @IfMandrelVersion(min = "21.1")

The actual comparator comes from Graal's own org.graalvm.home.Version.

The version detected is spit out in the log:

INFO  [o.g.t.i.u.v.UsedVersion] (getVersion) Running command [native-image, --version] to determine Mandrel version used.
INFO  [o.g.t.i.u.v.UsedVersion] (getVersion) The test suite runs with Mandrel version 20.3.2-final installed locally on PATH.
INFO  [o.g.t.i.u.v.UsedVersion] (getVersion) Running command [docker, run, -t, quay.io/quarkus/ubi-quarkus-mandrel:20.1-java11, native-image, --version] to determine Mandrel version used.
INFO  [o.g.t.i.u.v.UsedVersion] (getVersion) The test suite runs with Mandrel version 20.1.0.4-final in container.

If no annotation with inContainer = true is used (any such test activated), TS does not attempt to run any containers:

INFO  [o.g.t.i.u.v.UsedVersion] (getVersion) Running command [native-image, --version] to determine Mandrel version used.
INFO  [o.g.t.i.u.v.UsedVersion] (getVersion) The test suite runs with Mandrel version 21.1.0-snapshot installed locally on PATH.
Karm commented 3 years ago

@jerboaa Docs updated.