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

ScalaPB Plugin: Add option scala3_sources #3258

Merged
merged 6 commits into from
Jan 21, 2025
Merged

Conversation

b-eyselein
Copy link
Contributor

Like the title says, this option allows users of the scalapb-Plugin to submit the option scala3_sources to scalapb directly.

Copy link
Member

@lefou lefou left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Looks reasonable. Thank you! Do you intend to add a test case for that options? It's not a requirement, but helps with maintenance.

@b-eyselein
Copy link
Contributor Author

I've added a simple test, but I don't know if this is enough. If not, can you please give me a hint on how to improve it?

@@ -182,6 +188,11 @@ object TutorialTests extends TestSuite {
}
}

"calledWithScala3Sources" - workspaceTest(TutorialWithScala3Soures) { eval =>
val result = eval.apply(Tutorial.core.compileScalaPB)
assert(result.isRight)
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

@b-eyselein Is there something unique to the scala3_sources option in the generated file(s)? you could assert some specific file content.

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

It mainly uses ? instead of _for unknown types which generates a bunch of compiler warnings...

@lihaoyi lihaoyi merged commit 6c164de into com-lihaoyi:main Jan 21, 2025
31 checks passed
@lefou lefou added this to the 0.12.6 milestone Jan 21, 2025
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants