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

Jackson uses platform line endings.

Open arthur-noseda opened this issue 5 years ago • 2 comments
trafficstars

When building the project on Windows, I encountered an issue with one of Jackson2HalFormsIntegrationTest's methods. It seems Jackson is using the underlying platform's line ending when serializing. The expected is not met on Windows (nor should it on Mac).

arthur-noseda avatar Sep 13 '20 13:09 arthur-noseda

We HEAVILY test against Jackson. How is the ONLY place this manifests?

gregturn avatar Jun 30 '21 21:06 gregturn

We HEAVILY test against Jackson. How is the ONLY place this manifests?

It looks like this is the only test that explicitly declares a JSON string containing line separators. If formatting is important for that assertion then it could use AssertJ's conventional assertThat(serialized).isEqualToNormalizingNewlines(expected); to fix the build on Windows.

ParkerM avatar Sep 23 '22 21:09 ParkerM