intellij-generateAllSetMethod
intellij-generateAllSetMethod copied to clipboard
Please add JUnit 5 support
"assert all getters" generates a long "assertThat(xx.getxx()).isEqualTo();" list. "assertThat" is not anymore in JUnit 5.
Please use something dependent on the getter return type or simply use "assertEquals(xx expected, xx actual)"
assertThat is from assertJ, you may add depedency from https://joel-costigliola.github.io/assertj/
Thank you for the information :)
Ah, hamcrest like assertions https://junit.org/junit5/docs/current/user-guide/#writing-tests-assertions-third-party
I'll look if my company allows to add this into the projects.
It just looked for me like an bug in the first place, because JUnit 5 deprecated and removed assertThat.
But it's another dependency I need to add and maintain. Happy dependency hell. :dizzy_face:
I think that it will be possible to add without any dependency in plugin side. Just add generate asserts with hamcrestAssertions entry and generate the code. And let the user choose, if it choose that it is expected that he will have the dependency in it's project.
Any news about this evolve :) ?
how about support Hamcrest
I suggest adding an ability to choose your preferred testing framework in settings in case if you have more than one on your classpath. What do you think?