Skip to content

Commit b040aed

Browse files
committed
Update message formatting in SvgConverterIntegrationTest
DEVSIX-3014
1 parent 52f4ddb commit b040aed

File tree

1 file changed

+8
-7
lines changed

1 file changed

+8
-7
lines changed

svg/src/test/java/com/itextpdf/svg/converter/SvgConverterIntegrationTest.java

Lines changed: 8 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -42,6 +42,7 @@ This file is part of the iText (R) project.
4242
*/
4343
package com.itextpdf.svg.converter;
4444

45+
import com.itextpdf.io.util.MessageFormatUtil;
4546
import com.itextpdf.kernel.geom.Rectangle;
4647
import com.itextpdf.kernel.pdf.PdfDocument;
4748
import com.itextpdf.kernel.pdf.PdfPage;
@@ -284,7 +285,7 @@ public void drawOnSpecifiedPositionX() throws IOException, InterruptedException
284285
String name = "eclipse";
285286
int x = 50;
286287
int y = 0;
287-
String destName = name + "_" + x + "_" + y;
288+
String destName = MessageFormatUtil.format("{0}_{1}_{2}", name, x, y);
288289
FileInputStream fis = new FileInputStream(sourceFolder + name + ".svg");
289290
drawOnSpecifiedPositionDocument(fis, destinationFolder + destName + ".pdf", x, y);
290291

@@ -296,7 +297,7 @@ public void drawOnSpecifiedPositionY() throws IOException, InterruptedException
296297
String name = "eclipse";
297298
int x = 0;
298299
int y = 100;
299-
String destName = name + "_" + x + "_" + y;
300+
String destName = MessageFormatUtil.format("{0}_{1}_{2}", name, x, y);
300301
FileInputStream fis = new FileInputStream(sourceFolder + name + ".svg");
301302
drawOnSpecifiedPositionDocument(fis, destinationFolder + destName + ".pdf", x, y);
302303

@@ -308,7 +309,7 @@ public void drawOnSpecifiedPositionXY() throws IOException, InterruptedException
308309
String name = "eclipse";
309310
int x = 50;
310311
int y = 100;
311-
String destName = name + "_" + x + "_" + y;
312+
String destName = MessageFormatUtil.format("{0}_{1}_{2}", name, x, y);
312313
FileInputStream fis = new FileInputStream(sourceFolder + name + ".svg");
313314
drawOnSpecifiedPositionDocument(fis, destinationFolder + destName + ".pdf", x, y);
314315

@@ -321,7 +322,7 @@ public void drawOnSpecifiedPositionNegativeX() throws IOException, InterruptedEx
321322
String name = "eclipse";
322323
int x = -50;
323324
int y = 0;
324-
String destName = name + "_" + x + "_" + y;
325+
String destName = MessageFormatUtil.format("{0}_{1}_{2}", name, x, y);
325326
FileInputStream fis = new FileInputStream(sourceFolder + name + ".svg");
326327
drawOnSpecifiedPositionDocument(fis, destinationFolder + destName + ".pdf", x, y);
327328

@@ -333,7 +334,7 @@ public void drawOnSpecifiedPositionNegativeY() throws IOException, InterruptedEx
333334
String name = "eclipse";
334335
int x = 0;
335336
int y = -100;
336-
String destName = name + "_" + x + "_" + y;
337+
String destName = MessageFormatUtil.format("{0}_{1}_{2}", name, x, y);
337338
FileInputStream fis = new FileInputStream(sourceFolder + name + ".svg");
338339
drawOnSpecifiedPositionDocument(fis, destinationFolder + destName + ".pdf", x, y);
339340

@@ -346,7 +347,7 @@ public void drawOnSpecifiedPositionNegativeXY() throws IOException, InterruptedE
346347
String name = "eclipse";
347348
int x = -50;
348349
int y = -100;
349-
String destName = name + "_" + x + "_" + y;
350+
String destName = MessageFormatUtil.format("{0}_{1}_{2}", name, x, y);
350351
FileInputStream fis = new FileInputStream(sourceFolder + name + ".svg");
351352
drawOnSpecifiedPositionDocument(fis, destinationFolder + destName + ".pdf", x, y);
352353

@@ -359,7 +360,7 @@ public void drawOnSpecifiedPositionPartialOnPage() throws IOException, Interrupt
359360
String name = "eclipse";
360361
int x = -50;
361362
int y = -50;
362-
String destName = name + "_" + x + "_" + y;
363+
String destName = MessageFormatUtil.format("{0}_{1}_{2}", name, x, y);
363364
FileInputStream fis = new FileInputStream(sourceFolder + name + ".svg");
364365
drawOnSpecifiedPositionDocument(fis, destinationFolder + destName + ".pdf", x, y);
365366

0 commit comments

Comments
 (0)