DefaultComponentSelectionRulesTest.groovy

Clone Tools
  • last updated a few seconds ago
Constraints
Constraints: committers
 
Constraints: files
Constraints: dates
Remove parameter support in ComponentSelectionRules

Previous parameters are available on `ComponentSelection` instead.

    • -1
    • +1
    ./DefaultComponentSelectionRulesTest.groovy
  1. … 10 more files in changeset.
Remove parameter support in ComponentSelectionRules

Previous parameters are available on `ComponentSelection` instead.

    • -1
    • +1
    ./DefaultComponentSelectionRulesTest.groovy
  1. … 10 more files in changeset.
Remove parameter support in ComponentSelectionRules

Previous parameters are available on `ComponentSelection` instead.

    • -1
    • +1
    ./DefaultComponentSelectionRulesTest.groovy
  1. … 8 more files in changeset.
Remove parameter support in ComponentSelectionRules

Previous parameters are available on `ComponentSelection` instead.

    • -1
    • +1
    ./DefaultComponentSelectionRulesTest.groovy
  1. … 8 more files in changeset.
Remove parameter support in ComponentSelectionRules

Previous parameters are available on `ComponentSelection` instead.

    • -1
    • +1
    ./DefaultComponentSelectionRulesTest.groovy
  1. … 11 more files in changeset.
Remove parameter support in ComponentSelectionRules

Previous parameters are available on `ComponentSelection` instead.

    • -1
    • +1
    ./DefaultComponentSelectionRulesTest.groovy
  1. … 11 more files in changeset.
Remove parameter support in ComponentSelectionRules

Previous parameters are available on `ComponentSelection` instead.

    • -1
    • +1
    ./DefaultComponentSelectionRulesTest.groovy
  1. … 8 more files in changeset.
Deprecate extra parameters in ComponentSelectionRules

Since methods have been added on ComponentSelection, the logic for

detecting extra parameters in provided closures is now deprecated.

Fixes #6607

    • -13
    • +3
    ./DefaultComponentSelectionRulesTest.groovy
  1. … 12 more files in changeset.
Add accessors to ComponentSelection

The Groovy DSL gave access to ComponentMetadata and IvyModuleDescriptor

through the use of dynamic closure parameters.

These extra parameters are now available directly on the

ComponentSelection allowing access to them from the Action based API.

Note that this implies a slight semantical change, where rules using

closures would never see a null ComponentMetadata or IvyModuleDescriptor

while the API on ComponentSelection are effectively nullable.

Issue #6607

    • -9
    • +0
    ./DefaultComponentSelectionRulesTest.groovy
  1. … 6 more files in changeset.
Normalize `ModuleIdentifier`

This commit reworks the `ComponentModuleIdentifier`/`ComponentModuleSelector`/`ModuleVersionSelector`

classes to use `ModuleIdentifier` under the hood, instead of storing denormalized strings. This has

the advantage that we can reduce the use of the module identifier factory, which is called very

often during dependency resolution. Sharing instances reduces the need for conversions, and makes

comparisons faster.

    • -1
    • +4
    ./DefaultComponentSelectionRulesTest.groovy
  1. … 164 more files in changeset.
Rework generics around RuleAction adapter and validator

The class itself does not need to be generic, only the methods.

    • -1
    • +1
    ./DefaultComponentSelectionRulesTest.groovy
  1. … 8 more files in changeset.
Unit test fixes

    • -19
    • +12
    ./DefaultComponentSelectionRulesTest.groovy
  1. … 3 more files in changeset.
Renamed ‘beforeChange’ to ‘setMutationValidator’ in a few cases

+review REVIEW-5438

    • -1
    • +1
    ./DefaultComponentSelectionRulesTest.groovy
  1. … 10 more files in changeset.
Better name for configuration mutation types

    • -6
    • +8
    ./DefaultComponentSelectionRulesTest.groovy
  1. … 8 more files in changeset.
Changed some types so that they only support a single MutationValidator, rather than zero or more, as we only ever need one.

Changed some collections back to use java.util types, to keep object weight down.

    • -7
    • +8
    ./DefaultComponentSelectionRulesTest.groovy
  1. … 8 more files in changeset.
Component selection rules can check its own mutation

    • -2
    • +26
    ./DefaultComponentSelectionRulesTest.groovy
  1. … 1 more file in changeset.
Renamed ComponentSelectionRules.module() -> withModule()

    • -8
    • +8
    ./DefaultComponentSelectionRulesTest.groovy
  1. … 8 more files in changeset.
Provide a rule source instance instead of class when defining component selection rules

    • -8
    • +9
    ./DefaultComponentSelectionRulesTest.groovy
  1. … 7 more files in changeset.
Allow component selection rules to be defined with @Mutate

    • -11
    • +60
    ./DefaultComponentSelectionRulesTest.groovy
  1. … 8 more files in changeset.
Simplified component selection rules test with respect to notation parsing

+review REVIEW-5180

    • -47
    • +33
    ./DefaultComponentSelectionRulesTest.groovy
  1. … 2 more files in changeset.
Simplified unit test by using mock RuleActionAdapter

    • -157
    • +82
    ./DefaultComponentSelectionRulesTest.groovy
  1. … 2 more files in changeset.
Moved contextualization of rule action validation exception inside RuleActionAdapter

    • -3
    • +3
    ./DefaultComponentSelectionRulesTest.groovy
  1. … 3 more files in changeset.
Removed RuleAction from the public API: no replacement yet

    • -3
    • +4
    ./DefaultComponentSelectionRulesTest.groovy
  1. … 34 more files in changeset.
Extracted RuleAction conversion and validation to generic capabilities

+review REVIEW-5180

    • -11
    • +11
    ./DefaultComponentSelectionRulesTest.groovy
  1. … 11 more files in changeset.
Improving component selection rules targeting tests - Separated targeted tests from untargeted tests - Cleaned up instances of rule order assumptions - Extracted validation into RuleActionValidator +review REVIEW-5180

    • -18
    • +18
    ./DefaultComponentSelectionRulesTest.groovy
  1. … 5 more files in changeset.
Changing component selection rule targeting to use a collection of Spec/RuleAction tuples

+review REVIEW-5180

    • -14
    • +12
    ./DefaultComponentSelectionRulesTest.groovy
  1. … 10 more files in changeset.
Improving tests for component selection rule targeting

+review REVIEW-5180

    • -12
    • +3
    ./DefaultComponentSelectionRulesTest.groovy
  1. … 1 more file in changeset.
Minor refactoring for component selection rule targeting - Moved all validation to ModuleIdentifierNotationParser - Changed ComponentSelectionMatchingSpec to accept ModuleIdentifier in constructor - Wrapped notation parser errors in a contextual exception +review REVIEW-5180

    • -12
    • +20
    ./DefaultComponentSelectionRulesTest.groovy
  1. … 4 more files in changeset.
Change component selection rule targeting to use NotationParser

+review REVIEW-5180

    • -26
    • +57
    ./DefaultComponentSelectionRulesTest.groovy
  1. … 2 more files in changeset.
Revert breaking changes to InvalidActionClosureException

- Use InvalidUserCodeException for invalid component selection rule closure

- This is temporary pending improvements to the component selection rule Java API

+review REVIEW-5137

    • -7
    • +4
    ./DefaultComponentSelectionRulesTest.groovy
  1. … 4 more files in changeset.