internal

Clone Tools
  • last updated a few seconds ago
Constraints
Constraints: committers
 
Constraints: files
Constraints: dates
Added a fallback renderer to use for any JVM binary spec without a more specific renderer.

This happens to include JUnit test suite binaries.

    • -35
    • +0
    ./jvm/ClassDirectoryBinaryRenderer.java
    • -0
    • +35
    ./jvm/JvmBinaryRenderer.java
  1. … 1 more file in changeset.
Introduce `testing-base` module

This commit introduces a new `testing-base` module aimed at detangling the `plugins` module, by extracting 2 things:

* classes that are used independently of a testing framework or the JVM (`TestDescriptor`, ...)

* classes which are specific to JVM testing (`Test`, `TestReport`, `TestWorker`, ...)

The first category are extracted in the `testing-base` module. The second category have been migrated to the `testing-jvm` module, which now includes TestNG specific classes too.

* The `testing-jvm` module no longer depends on `plugins`, but on `testing-base` instead.

* The `plugins` module now depends on `testing-jvm` (so we have effectively inverted the dependency).

It's worth noting that while main classes have been shuffled around, test classes have not been moved, and some quality checks had to be disabled. For example, strict compilation and classcycle cannot be used anymore in the `testing-jvm` module without introducing breaking changes.

Two classes (`JUnitOptions` and `TestNGOptions`) have been migrated from Groovy to Java.

At this point, building Gradle is broken. Subsequent commits will fix that.

Story: gradle/langos#103

Item: refactor-plugins

    • -41
    • +0
    ./tasks/testing/DefaultJUnitXmlReport.java
    • -33
    • +0
    ./tasks/testing/DefaultTestClassDescriptor.java
    • -41
    • +0
    ./tasks/testing/DefaultTestDescriptor.java
    • -28
    • +0
    ./tasks/testing/DefaultTestMethodDescriptor.java
    • -34
    • +0
    ./tasks/testing/DefaultTestSuiteDescriptor.java
    • -46
    • +0
    ./tasks/testing/TestClassProcessor.java
    • -22
    • +0
    ./tasks/testing/TestClassRunInfo.java
  1. … 264 more files in changeset.
Use the standard Scala `LanguageTransform` in Play support

To make this work, needed to allow ScalaLanguagePlugin to joint compile all

sources for a binary.

This implementation is a basic and somewhat hacky placeholder for true dependency-aware source handling:

- Source sets should be able to depend on other source sets, resulting in the correct task dependencies and inputs

- Joint-compilation should only be used in the case where sources are co-dependent.

Currently we use joint-compilation when:

- We have a language transform that supports joint-compilation

- Binary is flagged with `BinarySpecInternal.hasCodependentSources()`

At this stage, only `PlayApplicationBinarySpec` is flagged with `hasCodependentSources`.

    • -0
    • +5
    ./jvm/DefaultClassDirectoryBinarySpec.java
  1. … 9 more files in changeset.
Modified exception handling when TestNG does not support preserving order or grouping by instances. The NoSuchMethodException is wrapped by a GradleException with a meaningful message.

Made it easier to use `java-lang` plugin without a `JarBinarySpec`

- Moved `getId()` up to `BinarySpecInternal` and `BaseBinarySpec`

- Refactored `DependencyResolvingClasspath`

- The complete set of dependencies is provided

- Does not have any knowledge of Jvm classes

- JavaLanguagePlugin will resolve sourceSet dependencies for a variant that

is not a `JarBinarySpec`

+review REVIEW-5733

    • -0
    • +6
    ./jvm/DefaultClassDirectoryBinarySpec.java
  1. … 5 more files in changeset.
Fixed error handling for explicit setting of groupByInstances option when underlying TestNG does not support it.

Fix typo

Simplified the naming scheme used to the output directories of JVM binaries.

Reused `BinaryNamingScheme` to calculate the output directories for these binaries.

Also added classes dir, resources dir and API jar output paths to components report.

    • -8
    • +1
    ./jvm/ClassDirectoryBinaryRenderer.java
  1. … 24 more files in changeset.
Moved `namingScheme` property up to `BinarySpecInternal` from the native binaries.

Also changed `DefaultBinaryNamingScheme` to deal with binaries with no parent and a name that was provided by something else.

    • -4
    • +11
    ./jvm/DefaultClassDirectoryBinarySpec.java
  1. … 8 more files in changeset.
Incorporated feedback.

    • -4
    • +4
    ./tasks/testing/testng/TestNGSpec.java
  1. … 5 more files in changeset.
Merged `BinaryNamingSchemeBuilder` into `BinaryNamingScheme`.

    • -9
    • +1
    ./jvm/ClassDirectoryBinaryNamingScheme.java
  1. … 12 more files in changeset.
Removed some more `Action` methods from `LanguageSourceSet` subtypes, as these methods are no longer required to mix in the configuration DSL.

+review REVIEW-5708

  1. … 5 more files in changeset.
Removed `LanguageSourceSet.source()` method, as this method is no longer required to mix in the configuration DSL.

+review REVIEW-5708

  1. … 4 more files in changeset.
Removed the various `Action` methods from the software model types, as these methods are no longer required to mix in the configuration DSL.

+review REVIEW-5708

    • -12
    • +0
    ./jvm/DefaultClassDirectoryBinarySpec.java
  1. … 11 more files in changeset.
Fixed some test cases for changes to view types.

+review REVIEW-5708

  1. … 1 more file in changeset.
Mixed DependentSourceSet into JavaSourceSet, so that the `dependencies` property is reachable from the public API.

This will allow it to be visible to view generation, plus plugins implemented in languages other than Groovy.

+review REVIEW-5708

  1. … 2 more files in changeset.
Use the public type of a binary in its display name.

Also removed `BinarySpecInternal.setPublicType()` as this is always known at construction now.

+review REVIEW-5708

    • -5
    • +0
    ./jvm/DefaultClassDirectoryBinarySpec.java
  1. … 8 more files in changeset.
BaseBinarySpec.sources is a node-backed ModelMap

    • -6
    • +0
    ./jvm/DefaultClassDirectoryBinarySpec.java
  1. … 22 more files in changeset.
Renamed LanguageSourceSet.fullName -> projectScopedName

This change makes LanguageSourceSet consistent with BinarySpec

Issue: gradle/langos#40 +review REVIEW-5681

  1. … 8 more files in changeset.
Remove unnecessary public API methods

+review REVIEW-5669

  1. … 7 more files in changeset.
Changed the JVM and native component plugins to use names for binaries that reflect the role they play.

Now that more than one component may have a binary with a given name, use:

- `jar` as the name for a Jar binary that belongs to a JVM library

- `executable` as the name for an executable that belongs to a native application

- `sharedLibrary` and `staticLibrary` as the name for the binaries of a native library.

These can later turn into static properties of the appropriate `ComponentSpec` types.

There is a breaking change in this commit: the lifecycle task name and output directory name of the binaries of components with multiple variants now include the component name at the start of the name, rather than somewhere in the middle.

    • -2
    • +2
    ./jvm/ClassDirectoryBinaryNamingScheme.java
  1. … 26 more files in changeset.
Moved the concept of the owning component of a binary up from various subtypes up to BaseBinarySpec.

Previously, native and jvm library binary specs exposed their owning component, for use in rules. This is now available in a consistent way for all binary specs (which can all be owned by a component). Later, this should probably be moved to a view that is mixed in to those binaries that are actually owned by a component.

This change also allows certain immutable properties of the component to be used to calculate some properties of the binary.

    • -0
    • +5
    ./jvm/DefaultClassDirectoryBinarySpec.java
  1. … 11 more files in changeset.
Allow A LanguageSourceSet of any registered type to be created via FunctionalSourceSet

- Adds languageRegistry to FSS

- LSS creation uses FSS's LanguageRegistry

- Don't push language factories into FSS

- Add a basDir property to FSS for initializing LSS's with a default source directory

- Remove language source set factory registration from ComponentRules

  1. … 15 more files in changeset.
Allow managed binaries and components to extend specs

This allows users to declare managed types that extend a non-managed

interface with a registered default implementation. The managed

instance will delegate everything possible to an instance of the

default implementation (stored as an unmanaged instance in the node),

while storing all other managed properties in child nodes.

Changes:

* Instead of generating managed proxy classes during schema extraction,

now they are generated (and cached) during instantiation.

* Instantiation of purely managed types are not validated during schema

extraction.

Things still to do:

* Handle error cases during declaration of managed type

* Add projections for internal views declared for super-types (both

managed and unmanaged)

+review REVIEW-5651

    • -0
    • +5
    ./jvm/DefaultClassDirectoryBinarySpec.java
  1. … 43 more files in changeset.
Moved a bunch of classes from 'core' to 'plugins' project.

    • -1
    • +1
    ./tasks/testing/junit/JULRedirector.java
    • -0
    • +26
    ./tasks/testing/processors/StandardOutputRedirector.java
  1. … 5 more files in changeset.
Changed JavaBasePlugin to create compile and process resources tasks using the legacy types rather than the software model type. This allows the software types to be created later (ie as rules require them).

  1. … 3 more files in changeset.
Changed DefaultClassDirectoryBinarySpec so that it is an adapter over SourceSet, and added some test coverage.

    • -6
    • +4
    ./jvm/DefaultClassDirectoryBinarySpec.java
  1. … 1 more file in changeset.
Moved some logic from DefaultClassDirectoryBinarySpec to DefaultSourceSet.

    • -1
    • +1
    ./jvm/ClassDirectoryBinaryNamingScheme.java
    • -3
    • +0
    ./jvm/ClassDirectoryBinarySpecInternal.java
    • -9
    • +9
    ./jvm/DefaultClassDirectoryBinarySpec.java
  1. … 3 more files in changeset.
Changed BinarySpecInternal so that it carries details about the public type of the binary, and use this to calculate the schema, rather than trying to inspect the binary to figure out if it's decorated or a model view or whatever.

Changed ModelSchemaStore so that it deals only with types and not instances.

    • -0
    • +7
    ./jvm/DefaultClassDirectoryBinarySpec.java
  1. … 18 more files in changeset.
Renamed FileCollectionContainer.resolve() to visitContents()

  1. … 25 more files in changeset.