A Java text block is an easy way to have a multiline string value.
But there is a catch if we want to use a text block with the assertion method isEqualTo.
Suppose you have written a piece of code that create a new string value where the line endings are defined using System.lineSeparator().
The string value would have the line ending \n on Linux and MacOS systems, and the line ending \r\n on Windows system.
But a Java text block will always use the line ending \n on every platform, including the Windows platform.
If you would run your tests on a Windows platform then the assertion using isEqualTo will fail, but the test will pass on Linux or MacOS systems.
This is a problem if you are working with developers using different operating systems.
Therefore it is better to use the method isEqualToNormalizingNewlines for these type of assertions.
AssertJ will make sure the line endings are the same and the tests will pass independent of the operating system the tests are run on.