1616import static org .testng .Assert .assertEquals ;
1717
1818public class ByteConverterTest {
19-
19+ private static final String NEWLINE = System .getProperty ("line.separator" );
20+
2021 @ Test
2122 public void testByte () {
2223 final Map <String , Model > models = ModelConverters .getInstance ().read (ByteConverterModel .class );
@@ -42,13 +43,13 @@ public void testByteProperty() {
4243 Model model = new ModelImpl ()
4344 .property ("byteProperty" , new ByteArrayProperty ());
4445
45- assertEquals (Json .pretty (model ), "{\n " +
46- " \" properties\" : {\n " +
47- " \" byteProperty\" : {\n " +
48- " \" type\" : \" string\" ,\n " +
49- " \" format\" : \" byte\" \n " +
50- " }\n " +
51- " }\n " +
46+ assertEquals (Json .pretty (model ), "{" + NEWLINE +
47+ " \" properties\" : {" + NEWLINE +
48+ " \" byteProperty\" : {" + NEWLINE +
49+ " \" type\" : \" string\" ," + NEWLINE +
50+ " \" format\" : \" byte\" " + NEWLINE +
51+ " }" + NEWLINE +
52+ " }" + NEWLINE +
5253 "}" );
5354 }
5455
@@ -72,17 +73,17 @@ public void testByteArray() {
7273 Model model = new ModelImpl ()
7374 .property ("byteArray" , new ArrayProperty (new BinaryProperty ()));
7475
75- assertEquals (Json .pretty (model ), "{\n " +
76- " \" properties\" : {\n " +
77- " \" byteArray\" : {\n " +
78- " \" type\" : \" array\" ,\n " +
79- " \" items\" : {\n " +
80- " \" type\" : \" string\" ,\n " +
81- " \" format\" : \" binary\" \n " +
82- " }\n " +
83- " }\n " +
84- " }\n " +
85- "}" );
76+ assertEquals (Json .pretty (model ), "{" + NEWLINE +
77+ " \" properties\" : {" + NEWLINE +
78+ " \" byteArray\" : {" + NEWLINE +
79+ " \" type\" : \" array\" ," + NEWLINE +
80+ " \" items\" : {" + NEWLINE +
81+ " \" type\" : \" string\" ," + NEWLINE +
82+ " \" format\" : \" binary\" " + NEWLINE +
83+ " }" + NEWLINE +
84+ " }" + NEWLINE +
85+ " }" + NEWLINE +
86+ "}" );
8687 }
8788
8889 class ByteConverterModel {
0 commit comments