DefaultTaskClassValidatorExtractorTest.groovy

Clone Tools
  • last updated a few seconds ago
Constraints
Constraints: committers
 
Constraints: files
Constraints: dates
Support rich task inputs (#3720)

@Nested inputs are now discovered based on the runtime type instead of the static type.

    • -430
    • +0
    ./DefaultTaskClassValidatorExtractorTest.groovy
  1. … 150 more files in changeset.
Warn about annotations on private property

    • -0
    • +29
    ./DefaultTaskClassValidatorExtractorTest.groovy
  1. … 1 more file in changeset.
Warn when `@Input` annotation used on Path property (#2928)

We do this for File and FileCollection already.

    • -0
    • +5
    ./DefaultTaskClassValidatorExtractorTest.groovy
  1. … 1 more file in changeset.
Replace usages of org.gradle.api.Nullable

With javax.annotation.Nullable.

    • -1
    • +1
    ./DefaultTaskClassValidatorExtractorTest.groovy
  1. … 460 more files in changeset.
Make validation warnings read like sentences

+review REVIEW-6501

    • -9
    • +9
    ./DefaultTaskClassValidatorExtractorTest.groovy
  1. … 8 more files in changeset.
Ensure reproducible order of task property validation messages

+review REVIEW-6501

    • -15
    • +16
    ./DefaultTaskClassValidatorExtractorTest.groovy
  1. … 1 more file in changeset.
Fix random order of validation messages in tests

+review REVIEW-6501

    • -15
    • +14
    ./DefaultTaskClassValidatorExtractorTest.groovy
Add more task property validations

- conflicting property types are declared

- same annotation is used on both field and method

- missing @PathSensitive annotation for cacheable task

- @Input used on File or FileCollection property

+review REVIEW-6501

    • -16
    • +182
    ./DefaultTaskClassValidatorExtractorTest.groovy
  1. … 12 more files in changeset.
Fix handling of `@InputFiles` and `@Classpath` being present both

`@Classpath` was introduced in Gradle 3.2. Tasks willing to stay compatible with earlier versions need to annotate their classpath properties with both `@Classpath` and `@InputFiles`. However, the detected type in 3.2 depended on the order the annotations were declared: `@Classpath @InputFiles` worked fine (i.e. was detected as `@InputFiles` prior to 3.2, but as `@Classpath` in 3.2). However, `@InputFiles @Classpath` was detected always as `@InputFiles`. This is now fixed.

+review REVIEW-6381

    • -0
    • +52
    ./DefaultTaskClassValidatorExtractorTest.groovy
  1. … 6 more files in changeset.
Fix test

+review REVIEW-6365

    • -2
    • +1
    ./DefaultTaskClassValidatorExtractorTest.groovy
Add overriding task property annotations with unprocessed annotations

+review REVIEW-6365

    • -2
    • +55
    ./DefaultTaskClassValidatorExtractorTest.groovy
Simplify test

+review REVIEW-6365

    • -30
    • +45
    ./DefaultTaskClassValidatorExtractorTest.groovy
  1. … 2 more files in changeset.
Allow sub task types to override task property type from superclass

Previously some overrides worked (e.g. `@Internal` -> `@InputFile`), but others didn’t (e.g. `@InputFile` -> `@Internal`). This clears up the semantics of how property type inheritance works, so the most specific property type annotation wins in every case.

+review REVIEW-6365

    • -0
    • +52
    ./DefaultTaskClassValidatorExtractorTest.groovy
  1. … 1 more file in changeset.
Register custom task property annotation handlers

This way plugins can register their own custom annotation handlers.

+review REVIEW-6241

    • -0
    • +59
    ./DefaultTaskClassValidatorExtractorTest.groovy
  1. … 10 more files in changeset.