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

Add support for Kotlin #192

Open
smwhit opened this issue Oct 23, 2024 · 4 comments
Open

Add support for Kotlin #192

smwhit opened this issue Oct 23, 2024 · 4 comments
Labels
language support Support for a new language

Comments

@smwhit
Copy link

smwhit commented Oct 23, 2024

I've tried cover-agent against kotlin code and it doesn't seem to work. Can support be added?

I get:
cover_agent.CoverAgent - INFO - Current Coverage: 0%
then later

cover_agent.UnitTestGenerator - INFO - Running test with the following command: "./gradlew clean test jacocoTestReport"
cover_agent.UnitTestGenerator - INFO - Test did not increase coverage. Rolling back.`

I also have java code in this project and it works fine if I point cover-agent at the java files.

@EmbeddedDevops1
Copy link
Collaborator

Hi @smwhit. Thanks for filing the issue. Any chance you can point us to an open source repo that we can use to test this out?

@smwhit
Copy link
Author

smwhit commented Oct 27, 2024

Hi @EmbeddedDevops1 - this should do it https://github.com/smwhit/cover-agent-kotlin-testing. Command line I am using for java and kotlin are in the readme.

@EmbeddedDevops1 EmbeddedDevops1 added the language support Support for a new language label Nov 11, 2024
@redvelvets
Copy link
Contributor

image
image
你可能需要针对.kt单独做一个判断,因为kotlin的package没有;,className没有public

@redvelvets
Copy link
Contributor

kotlin is supported

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
language support Support for a new language
Projects
None yet
Development

No branches or pull requests

3 participants