-
Notifications
You must be signed in to change notification settings - Fork 1.1k
fix open issue#11829 #12102
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
fix open issue#11829 #12102
Conversation
for each of these AI generated patches we will need tests to verify that the bug that is being fixed is actually fixed. Without tests we can't accept the patch |
Thanks. I'll push tests soon so that the team can review. |
I have uploaded the test scripts (groovy scripts) for all the PRs I've made. |
ok but these test scripts are not actual tests and are not integrated with the rest of the build. For the PRs to be in an acceptable state actual tests need to be included |
Do you mean an actual micronaut app or a junit test ? Would you be able to give some initial comments on the tests and patches I have submitted? This helps with improvements from my side. |
I would expect for an issue like this which addresses something related to Kotlin that the PR would include a test similar to this one https://github.com/micronaut-projects/micronaut-core/blob/4.10.x/inject-kotlin/src/test/groovy/io/micronaut/kotlin/processing/beans/BeanDefinitionSpec.groovy that verifies the compiled code is correct the same way as your Groovy script does. Having a random Groovy script in the root that reproduces doesn't help as it will never be executed and doesn't count as a test. |
I'd say this isn't a random script : micronaut-core/reproduce_issue.groovy Line 83 in 6a8c8cc
micronaut-core/reproduce_issue.groovy Line 22 in 6a8c8cc
The script contains source and it creates the tests in a specific folder. |
@Jarvx Simply take a look how tests are written in the project and create a test in a similar style. |
val ctx = ApplicationContext.run() | ||
|
||
// Correctly reference the class for Micronaut to create a bean | ||
assertThrows<IllegalStateException> { |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
@Jarvx If you fix this bug, Why do you expect an error? It turns out that after your fix there shouldn't be an error.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Thanks. I am working on a new fix currently. I'll close my existing PRs first.
This is an AI-generated fix for issue #11829. The patch has been tested against version 4.9.0 (as suggested by the branch name).
I’m happy to discuss any improvements or suggestions!