Used magic values in PI number encoding test
This commit is contained in:
parent
d528e8dd8c
commit
fa6ad9fcc1
|
@ -42,32 +42,31 @@ public class FourCornerUnicodeDisplayTest {
|
|||
@Test
|
||||
public void testPINSimple() throws Exception {
|
||||
List<FourCornerX06BaklavaPoints> cdc = new ArrayList<>();
|
||||
cdc.add(FCDotCDC1604DashP6.NX24_X); // = X
|
||||
cdc.add(FCDotCDC1604DashP6.NX24_X); // = X
|
||||
cdc.add(FCDotCDC1604DashP6._EQUALS);
|
||||
cdc.add(FCDotCDC1604DashP6.__PIN);
|
||||
cdc.add(FCDotCDC1604DashP6.NX03_C); // T003
|
||||
cdc.add(FCDotCDC1604DashP6.NX01_A); // NXX_001
|
||||
cdc.add(FCDotCDC1604DashP6.NX15_O); // T015
|
||||
cdc.add(FCDotCDC1604DashP6.NX14_N); // NXX_015
|
||||
cdc.add(FCDotCDC1604DashP6.NX05_E); // NXX_005
|
||||
cdc.add(FCDotCDC1604DashP6.NX07_G); // NXX_007
|
||||
cdc.add(FCDotCDC1604DashP6.NX15_O); // NXX_015
|
||||
cdc.add(FCDotCDC1604DashP6.NX04_D); // NXX_004
|
||||
cdc.add(FCDotCDC1604DashP6._SEMICOLON);
|
||||
cdc.add(FCDotCDC1604DashP6.__LINE);
|
||||
|
||||
String out = FourCornerUnicodeDisplay.text().renderFromX06(cdc);
|
||||
Assertions.assertEquals("X¹/₃", out);
|
||||
Assertions.assertEquals("X=¹⁴/₁₅⁵/₁₅⁷/₁₅¹⁵/₁₅⁴/₁₅;\n", FourCornerUnicodeDisplay.text().renderFromX06(cdc));
|
||||
Assertions.assertEquals("X=␂ONEGOD;\n", FourCornerUnicodeDisplay.raw().renderFromX06(cdc));
|
||||
}
|
||||
|
||||
@Test
|
||||
public void testMixedCasing() throws Exception {
|
||||
List<FourCornerX06BaklavaPoints> cdc = new ArrayList<>();
|
||||
|
||||
//cdc.add(FCDotCDC1604DashP6.__PIE);
|
||||
//cdc.add(FCDotCDC1604DashP6.NX26_Z); // select lower case
|
||||
//cdc.add(FCDotCDC1604DashP6.NX01_A);
|
||||
cdc.add(FCDotPIE9CDash26.LOW_A);
|
||||
cdc.add(FCDotPIE9CDash26.LOW_B); // if used as this per letter full escaping here....
|
||||
|
||||
cdc.add(FCDotCDC1604DashP6.__SPACE); // out of range is end lower
|
||||
cdc.add(FCDotCDC1604DashP6.NX02_B);
|
||||
|
||||
//cdc.add(FCDotCDC1604DashP6.__ESC6);
|
||||
cdc.add(FCDotDEC1604DashP7.__ESC_BELOW); // test escape code
|
||||
cdc.add(FCDotCDC1604DashP6.NX03_C);
|
||||
|
||||
cdc.add(FCDotCDC1604DashP6.NX04_D); // thus this upper case D
|
||||
cdc.add(FCDotCDC1604DashP6._DOT);
|
||||
cdc.add(FCDotCDC1604DashP6.__PIE);
|
||||
|
@ -76,8 +75,6 @@ public class FourCornerUnicodeDisplayTest {
|
|||
cdc.add(FCDotCDC1604DashP6.NX11_K);
|
||||
cdc.add(FCDotCDC1604DashP6.NX12_L);
|
||||
cdc.add(FCDotCDC1604DashP6.NX13_M);
|
||||
|
||||
//cdc.add(FCDotCDC1604DashP6.__ESC6);
|
||||
cdc.add(FCDotDEC1604DashP7.__ESC_STOP);
|
||||
cdc.add(FCDotCDC1604DashP6.NX15_O);
|
||||
|
||||
|
@ -96,8 +93,7 @@ public class FourCornerUnicodeDisplayTest {
|
|||
cdc.add(FCDotCDC1604DashP6._AT);
|
||||
cdc.add(FCDotCDC1604DashP6.NX11_K); // = K
|
||||
|
||||
String out = FourCornerUnicodeDisplay.text().renderFromX06(cdc);
|
||||
Assertions.assertEquals("X^%@K", out);
|
||||
Assertions.assertEquals("X^%@K", FourCornerUnicodeDisplay.text().renderFromX06(cdc));
|
||||
}
|
||||
|
||||
@Test
|
||||
|
@ -111,7 +107,6 @@ public class FourCornerUnicodeDisplayTest {
|
|||
cdc.add(FCDotCDC1604DashP6.NX04_D); // 3
|
||||
cdc.add(FCDotCDC1604DashP6.NX11_K); // K
|
||||
|
||||
String out = FourCornerUnicodeDisplay.text().renderFromX06(cdc);
|
||||
Assertions.assertEquals("B3K", out);
|
||||
Assertions.assertEquals("B3K", FourCornerUnicodeDisplay.text().renderFromX06(cdc));
|
||||
}
|
||||
}
|
||||
|
|
Loading…
Reference in a new issue