spring-hateoas icon indicating copy to clipboard operation
spring-hateoas copied to clipboard

Fixes Flaky tests

Open HildoYe opened this issue 3 years ago • 2 comments
trafficstars

There a several flaky tests and this PR fixes those. The problems are entirely ordering issues, and the proposed solutions is mainly to use annotations @JsonPropertyOrder.

The flakiness can be test with mvn -pl . edu.illinois:nondex-maven-plugin:1.1.2:nondex -Dtest=TESTNAME

Tests fixed:

  • config.CustomHypermediaWebFluxTest#getUsingCustomMediaType
  • config.CustomHypermediaWebMvcTest#getUsingCustomMediaType
  • EntityModelIntegrationTest#inlinesContent
  • IanaLinkRelationUnitTest#testAllIanaLinkRelationsHaveStringConstant
  • Jackson2LinkIntegrationTest#writesLinkCorrectly
  • Jackson2ResourceSupportIntegrationTest#doesNotRenderId
  • Jackson2ResourceIntegrationTest#inlinesContent
  • Jackson2PagedResourcesIntegrationTest#serializesPagedResourcesCorrectly
  • mediatype.collectionjson.Jackson2CollectionJsonIntegrationTest#renderComplexStructure
  • mediatype.collectionjson.Jackson2CollectionJsonIntegrationTest#renderSimplePojos
  • mediatype.collectionjson.Jackson2CollectionJsonIntegrationTest#rendersMultipleLinkAsArray
  • mediatype.collectionjson.Jackson2CollectionJsonIntegrationTest#serializesPagedResource
  • mediatype.hal.forms.HalFormsObjectMapperCustomizerTest#objectMapperCustomizerShouldBeApplied
  • mediatype.hal.forms.Jackson2HalFormsIntegrationTest#rendersTitleIfMessageSourceResolvesLocalKey
  • mediatype.hal.forms.Jackson2HalFormsIntegrationTest#rendersTitleIfMessageSourceResolvesNamespacedKey
  • mediatype.hal.forms.Jackson2HalFormsIntegrationTest#rendersCuriesCorrectly
  • mediatype.hal.forms.Jackson2HalFormsIntegrationTest#rendersMultipleResourceResourcesAsEmbedded
  • mediatype.hal.forms.Jackson2HalFormsIntegrationTest#rendersRepresentationModelWithTemplates
  • mediatype.hal.forms.Jackson2HalFormsIntegrationTest#rendersMultipleCuries
  • mediatype.hal.forms.Jackson2HalFormsIntegrationTest#rendersResource
  • mediatype.hal.forms.Jackson2HalFormsIntegrationTest#serializesAnnotatedResourceResourcesAsEmbedded
  • mediatype.hal.forms.Jackson2HalFormsIntegrationTest#serializesMultipleAnnotatedResourceResourcesAsEmbedded
  • mediatype.hal.forms.Jackson2HalFormsIntegrationTest#serializesPagedResource
  • mediatype.hal.Jackson2HalIntegrationTest#rendersTitleIfMessageSourceResolvesLocalKey
  • mediatype.hal.Jackson2HalIntegrationTest#rendersTitleIfMessageSourceResolvesNamespacedKey
  • mediatype.hal.Jackson2HalIntegrationTest#rendersAllExtraRFC8288Attributes
  • mediatype.hal.Jackson2HalIntegrationTest#rendersMultipleCuries
  • mediatype.hal.Jackson2HalIntegrationTest#rendersMultipleResourceResourcesAsEmbedded
  • mediatype.hal.Jackson2HalIntegrationTest#serializesAnnotatedResourceResourcesAsEmbedded
  • mediatype.hal.Jackson2HalIntegrationTest#serializesPagedResource
  • mediatype.hal.HalModelBuilderUnitTest#previewForLinkRelationsUsingHalModelBuilder
  • mediatype.hal.HalModelBuilderUnitTest#progressivelyAddingContentUsingHalModelBuilder
  • mediatype.hal.HalModelBuilderUnitTest#renderDifferentlyTypedEntities
  • mediatype.hal.HalModelBuilderUnitTest#renderExplicitAndImplicitLinkRelations
  • mediatype.hal.HalModelBuilderUnitTest#renderSingleItemUsingDefaultModelBuilder
  • mediatype.hal.HalModelBuilderUnitTest#renderSingleItemUsingHalModelBuilder
  • mediatype.hal.HalModelBuilderUnitTest#embeddedSpecUsingHalModelBuilder
  • mediatype.hal.HalObjectMapperCustomizerTest#objectMapperCustomizerShouldBeApplied
  • mediatype.problem.JacksonSerializationTest#extensionSerialize
  • RepresentationModelIntegrationTest#doesNotRenderId

HildoYe avatar Nov 29 '21 18:11 HildoYe

@HildoYe Please sign the Contributor License Agreement!

Click here to manually synchronize the status of this Pull Request.

See the FAQ for frequently asked questions.

pivotal-cla avatar Nov 29 '21 18:11 pivotal-cla

@HildoYe Thank you for signing the Contributor License Agreement!

pivotal-cla avatar Nov 29 '21 18:11 pivotal-cla