Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Res class not generated for commonTest only resources #4442

Closed
luca992 opened this issue Mar 7, 2024 · 2 comments
Closed

Res class not generated for commonTest only resources #4442

luca992 opened this issue Mar 7, 2024 · 2 comments
Assignees
Labels
enhancement New feature or request resources

Comments

@luca992
Copy link
Contributor

luca992 commented Mar 7, 2024

Describe the bug
I would like to have multiplatform resources only in my commonTest source set where the dependency on compose.components.resources is only added in commonTest like:

val commonTest by getting {
    dependencies {
        implementation(compose.components.resources)
    }
}

This does not work and the Res is not generated. I have to add implementation(compose.components.resources) in commonMain for Res to be generated.

Versions

  • Kotlin version*: 1.9.22
  • Compose Multiplatform version*: 1.6.0

To Reproduce
Add resources to commonTest/composeResources (not commonMain) and set:

val commonTest by getting {
    dependencies {
        implementation(compose.components.resources)
    }
}

Expected behavior
Res class is generated for commonTest only

@luca992 luca992 added bug Something isn't working submitted labels Mar 7, 2024
@igordmn igordmn added enhancement New feature or request resources and removed bug Something isn't working submitted labels Mar 7, 2024
luca992 added a commit to Kamel-Media/Kamel that referenced this issue Mar 8, 2024
comment out compose resources to publish and workaround:

JetBrains/compose-multiplatform#4442

JetBrains/compose-multiplatform#4295
@terrakok
Copy link
Member

Yes, the test resources is in our backlog. We will work on that in the future. It doesn't work yet

luca992 added a commit to Kamel-Media/Kamel that referenced this issue May 25, 2024
@okushnikov
Copy link
Collaborator

Please check the following ticket on YouTrack for follow-ups to this issue. GitHub issues will be closed in the coming weeks.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
enhancement New feature or request resources
Projects
None yet
Development

No branches or pull requests

4 participants