PDF417WriterTestCase.java (zxing-zxing-3.4.1) | : | PDF417WriterTestCase.java (zxing-zxing-3.5.0) | ||
---|---|---|---|---|
skipping to change at line 34 | skipping to change at line 34 | |||
import com.google.zxing.WriterException; | import com.google.zxing.WriterException; | |||
import com.google.zxing.common.BitMatrix; | import com.google.zxing.common.BitMatrix; | |||
import org.junit.Assert; | import org.junit.Assert; | |||
import org.junit.Test; | import org.junit.Test; | |||
/** | /** | |||
* Tests {@link PDF417Writer}. | * Tests {@link PDF417Writer}. | |||
*/ | */ | |||
public final class PDF417WriterTestCase extends Assert { | public final class PDF417WriterTestCase extends Assert { | |||
@SuppressWarnings("checkstyle:lineLength") | ||||
@Test | @Test | |||
public void testDataMatrixImageWriter() throws WriterException { | public void testDataMatrixImageWriter() throws WriterException { | |||
Map<EncodeHintType,Object> hints = new EnumMap<>(EncodeHintType.class); | Map<EncodeHintType,Object> hints = new EnumMap<>(EncodeHintType.class); | |||
hints.put(EncodeHintType.MARGIN, 0); | hints.put(EncodeHintType.MARGIN, 0); | |||
int size = 64; | int size = 64; | |||
PDF417Writer writer = new PDF417Writer(); | PDF417Writer writer = new PDF417Writer(); | |||
BitMatrix matrix = writer.encode("Hello Google", BarcodeFormat.PDF_417, size , size, hints); | BitMatrix matrix = writer.encode("Hello Google", BarcodeFormat.PDF_417, size , size, hints); | |||
assertNotNull(matrix); | assertNotNull(matrix); | |||
String expected = | String expected = | |||
"X X X X X X X X X X X X X X X X X X X X X X X X X X X X X X X X X X X X X X X X X X X X X X X X X X X X X X X X X X X X X X X X X X \n" + | "X X X X X X X X X X X X X X X X X X X X X X X X X X X X X X X X X X X X X X X X X X X X X X X X X X X X X X X X X X X X X X X X X X \n" + | |||
End of changes. 1 change blocks. | ||||
0 lines changed or deleted | 1 lines changed or added |