Skip to content

Support modules without 'main' source set #341

@jjohannes

Description

@jjohannes

Description

The use case is to only have testFixtures (and multiple test sets) in a module.

Currently, you need to add this, as Gradle is adding the dependency between testFixtures and main by default.

configurations {
    testFixturesApi {
        withDependencies { this.removeIf { it is ProjectDependency && it.name == project.name } }
    }
}

Otherwise you get an error like this:

      > Execution failed for ExtraJavaModuleInfoTransform: ./module-0.68.0-SNAPSHOT.jar.
         > Not a module and no mapping defined: module-0.68.0-SNAPSHOT.jar

Steps to reproduce

Create a module that does not contain a src/main/java folder.

Additional context

No response

Hedera network

No response

Version

0.6.0

Operating system

macOS

Metadata

Metadata

Assignees

No one assigned

    Labels

    bugSomething isn't working

    Type

    Projects

    No projects

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions