userguideOutput

Clone Tools
  • last updated a few seconds ago
Constraints
Constraints: committers
 
Constraints: files
Constraints: dates
Re-enable Play/Scala tests on Java 9+ (#5593)

Almost all Play/Scala tests were ignored on Java 9/10, which makes it lack coverage. This PR does:

- Update Scala version to Java9-compatible version according to [JDK compatibility](https://docs.scala-lang.org/overviews/jdk-compatibility/overview.html).

- Update default Play version to latest 2.6.15, which supports Java 9/10

- Adjust corresponding samples. Previous default Play version 2.3.10 was too old (release at 2014).

- Ignored the tests which can't work on Java 9+.

- Separate Play test resources with different versions. For example, Play 2.6 uses `build.gradle` and `Play 2.4/2.5` uses `build.gradle.old`.

- Previously `AbstractMultiVersionPlayContinuousBuildIntegrationTest` didn't have `targetPlatform` configuration, which made multi-version tests meaningless

- Fix `play-logback` configuration for `2.5.18`.

  1. … 170 more files in changeset.
Consistently report conflict resolution

This commit refactors how conflict resolution selection reasons are handled, in order to:

- collect the list of versions which participated in conflict resolution

- report a single conflict resolution cause when conflicts are resolved several times for the same module

- consistently report module replacement rules as rules, not conflict resolution. Before this change,

a module replacement was reported as both a conflict and a rule

  1. … 29 more files in changeset.
Remove code which added a default reason when the first one wasn't expected

This code was probably leftover from a previous implementation which wasn't

collecting reasons properly. Now, it's possible that the first dependency

we see is actually a constraint, so the test didn't make sense.

It also fixes a rendering issue where multiple blank lines were added in

case of rendering extra sections.

  1. … 4 more files in changeset.
Remove code which added a default reason when the first one wasn't expected

This code was probably leftover from a previous implementation which wasn't

collecting reasons properly. Now, it's possible that the first dependency

we see is actually a constraint, so the test didn't make sense.

It also fixes a rendering issue where multiple blank lines were added in

case of rendering extra sections.

  1. … 4 more files in changeset.
Collect all dependency reasons

This code fixes the problem that we only keep the first dependency reason

that we find when resolving. If it was a dependency without reason, then

even if a transitive dependency had a custom reason, we wouldn't show it.

Now, we properly collect all reasons during resolution, then show them in

the dependency insight report. It's worth noting that the output of the

report has been changed to always include a header, so that we have the

details for all dependencies which match the predicate.

  1. … 7 more files in changeset.
Collect all dependency reasons

This code fixes the problem that we only keep the first dependency reason

that we find when resolving. If it was a dependency without reason, then

even if a transitive dependency had a custom reason, we wouldn't show it.

Now, we properly collect all reasons during resolution, then show them in

the dependency insight report. It's worth noting that the output of the

report has been changed to always include a header, so that we have the

details for all dependencies which match the predicate.

  1. … 7 more files in changeset.
Externalize samples testing infrastructure

This change replaces UserGuideSamplesRunner with an external library

called sample-check. Sample discovery, execution, and normalization

is delegated to this library, with some custom normalizers remaining

in the Gradle codebase.

Samples output has become co-located with the sample code. Samples tests

must be run with Java 8+.

    • -138
    • +0
    ./basicRuleSourcePlugin-model-task.out
  1. … 768 more files in changeset.
Add testing of error output to user guide samples

  1. … 1 more file in changeset.
Update test for changed dependencyInsight output

Fix user guide samples for new plain console behavior

Consistently use component level attributes

Component-level attributes were only used if the component metadata was using Gradle

metadata. This was particularly confusing, as it was possible to define a component-

level attribute in a component-metadata rule, but it would be ignored during matching.

It was possible, however, to add attributes on variants of Ivy or Maven metadata,

but then the error messages in case there wasn't any match was even more confusing:

"Because there are no configurations with attributes"

This commit modifies the resolution engine so that it's possible to use component

level attributes independently of whether the underlying component metadata was

constructed from Ivy, Maven or Gradle metadata. It also changes the error messages

to mention either "configuration" or "variant" depending on whether the matching

strategy was using variant-aware dependency management *or* legacy configurations.

It was confusing because we have the `IMPROVED_POM_SUPPORT` flag which activates

variant construction from Maven metadata. This meant that in practice, if the flag

was active, we were using variants, but still the component level attributes were

not taken into account. If the flag wasn't active, then we would fail with the

error above, despite the fact we had rules on "configuration backed variants".

The separation of configuration/variant in error messages makes it easier for

us to understand in which case we are, since this wasn't always obvious. If we

see "variant", then now we know that the selection failed using the variant-aware

matching. If we see "configuration", then we know it's using the legacy mode.

This commit also needed to make the difference between "this component has no

variant" and "this component doesn't provide any mapping to variants", therefore

the introduction of the `Optional` on `getVariantsForTraversal`. This gives us

the opportunity to give the correct error message in case of failure using

the legacy mode.

Last but not least, this introduces a change in the attributes visible on variants

**and** artifacts. Before this commit, dependending on whether metadata was

Gradle metadata, the "status" attribute would be found or not. Now, the component

level attributes are _always_ merged to variant and artifact attributes, which

means that it's consistent independently of the format. This can be a breaking

change, but a low risk one.

  1. … 38 more files in changeset.
Add complete example to maven-publish chapter in User Guide

The complete example is added as the last section of the chapter and

showcases how to put together the pieces documented in detail in the

previous sections:

- publications including POM customization and custom artifacts

- repositories including conditional URL based on project version

- signing the published artifacts

Resolves #5094.

  1. … 9 more files in changeset.
Bridge tasks into software mode lazily

Only initialize the software model bridging if the user

either uses the `model {}` block or explicitly applies

a rule-based plugin.

Placeholder tasks are now implemented in the task container

directly instead of using the software model. They are also

deprecated as they add a lot of complexity for no gain beyond

what `createLater {}` already offers.

    • -13
    • +12
    ./basicRuleSourcePlugin-model-task.out
    • -13
    • +12
    ./softwareModelExtend-iv-model.out
  1. … 28 more files in changeset.
Remove content on deprecated features and anti-patterns (#5159)

    • -1
    • +0
    ./multiprojectMessagesConfigDependencies.out
    • -1
    • +0
    ./multiprojectMessagesConfigDependenciesAltSolution.out
    • -1
    • +0
    ./multiprojectMessagesConfigDependenciesBroken.out
    • -2
    • +0
    ./multiprojectMessagesDependencies.out
    • -2
    • +0
    ./multiprojectMessagesTaskDependencies.out
  1. … 21 more files in changeset.
Document conditional publishing for ivy-publish plugin

Issue: #5116

    • -0
    • +15
    ./publishingIvyConditionally.out
  1. … 6 more files in changeset.
Document conditional publishing for maven-publish plugin

Issue: #5116

    • -0
    • +18
    ./publishingMavenConditionally.out
  1. … 6 more files in changeset.
Document signing publications

Issue: #4943

    • -0
    • +11
    ./publishingMavenSignAndPublish.out
    • -0
    • +9
    ./signingPluginSignPublication.out
  1. … 9 more files in changeset.
Fix custom report dirs sample and test

  1. … 1 more file in changeset.
Fix custom report dirs sample and test

  1. … 1 more file in changeset.
Create a new chapter on building Java projects (#4800)

Merge the following changes from @pledbrook:

* Create a new chapter on Java projects

This covers a general overview in the Building Java projects chapter and a

fleshed out example in the Java testing chapter of setting up integration tests

in a Java build.

* Prune the Java Plugin chapter

Much of the content was overlapping with the new Building Java & JVM projects

chapter, so it has now been removed. The chapter is now a pure reference.

* Add plugin reference chapter for Base Plugin

  1. … 20 more files in changeset.
Create a new chapter on building Java projects (#4800)

Merge the following changes from @pledbrook:

* Create a new chapter on Java projects

This covers a general overview in the Building Java projects chapter and a

fleshed out example in the Java testing chapter of setting up integration tests

in a Java build.

* Prune the Java Plugin chapter

Much of the content was overlapping with the new Building Java & JVM projects

chapter, so it has now been removed. The chapter is now a pure reference.

* Add plugin reference chapter for Base Plugin

    • -0
    • +2
    ./javaCustomReportDirs.out
  1. … 20 more files in changeset.
Fix bridging of tasks into software model so that deferred tasks are visible to rules without eagerly creating the tasks.

  1. … 3 more files in changeset.
Clean up and reorganize existing content of best practices chapter (#4892)

  1. … 50 more files in changeset.
Test fixes.

  1. … 3 more files in changeset.
Remove spurious newline from tests that check output

    • -1
    • +0
    ./dependentTaskForApplicationDistributionOutput.out
  1. … 40 more files in changeset.
Update expected output for sample

Fix expected user guide sample outputs for changes to log output.

  1. … 1 more file in changeset.
Fix javaQuickstart sample so that we produce the same output for all Java versions

  1. … 2 more files in changeset.
Fix sample output

    • -1
    • +2
    ./basicRuleSourcePlugin-model-task.out
    • -1
    • +2
    ./customTaskClassWithInputOutputAnnotations.out
    • -1
    • +1
    ./customTaskClassWithInputOutputAnnotationsUpToDate.out
    • -7
    • +8
    ./dependentTaskForApplicationDistributionOutput.out
  1. … 54 more files in changeset.
Fix some files chapter integration tests

  1. … 3 more files in changeset.