Skip to content

Conversation

@k163377
Copy link
Contributor

@k163377 k163377 commented Feb 1, 2025

As shown below, by default maven-surefire-plugin only runs tests that match certain naming conventions.

By default, the Surefire Plugin will automatically include all test classes with the following wildcard patterns:

  • "**/Test*.java" - includes all of its subdirectories and all Java filenames that start with "Test".
  • "**/*Test.java" - includes all of its subdirectories and all Java filenames that end with "Test".
  • "**/*Tests.java" - includes all of its subdirectories and all Java filenames that end with "Tests".
  • "**/*TestCase.java" - includes all of its subdirectories and all Java filenames that end with "TestCase".

https://maven.apache.org/surefire/maven-surefire-plugin/examples/inclusion-exclusion.html#inclusions

On the other hand, this repository contains several classes that do not match this naming convention.
For example, the following were detected in #899 (comment)
https://github.com/FasterXML/jackson-module-kotlin/blob/2.19/src/test/kotlin/com/fasterxml/jackson/module/kotlin/test/github/failing/Github242.kt

Therefore, the configuration has been modified so that all tests included in the package are executed.

that fails for reasons different from what it should have been validated for.
Comment on lines -55 to -71
assertEquals(
"""
{
"nullableObject1" : null,
"nullableObject2" : null,
"map" : {
"nullableObject" : null
},
"mapGetter" : {
"nullableObject" : null
},
"nullableObjectGetter2" : null,
"nullableObjectGetter1" : null
}
""".trimIndent(),
json
)
Copy link
Contributor Author

Choose a reason for hiding this comment

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

This test was failing due to the different order of properties in the serialization result.
This was removed as a superfluous test case since there was no need to verify the order of the properties and the necessary verification could be done elsewhere.

@k163377 k163377 merged commit a586f72 into FasterXML:2.18 Feb 1, 2025
20 checks passed
@k163377 k163377 deleted the fix-to-exec-all-tests branch February 1, 2025 23:13
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.

1 participant