summaryrefslogtreecommitdiffstats
path: root/src/test/java/org/uic/barcode/asn1
diff options
context:
space:
mode:
Diffstat (limited to 'src/test/java/org/uic/barcode/asn1')
-rw-r--r--src/test/java/org/uic/barcode/asn1/test/BinaryStringTest.java4
-rw-r--r--src/test/java/org/uic/barcode/asn1/test/TestSequenceOfLong.java2
-rw-r--r--src/test/java/org/uic/barcode/asn1/test/UperEncodeBooleanTest.java8
-rw-r--r--src/test/java/org/uic/barcode/asn1/test/UperEncodeIntegerConstrainedTest.java2
-rw-r--r--src/test/java/org/uic/barcode/asn1/test/UperEncodeIntegerSmallTest.java2
-rw-r--r--src/test/java/org/uic/barcode/asn1/test/UperEncodeIntegerTest.java2
-rw-r--r--src/test/java/org/uic/barcode/asn1/test/UperEncodeRestrictedIntegerTest.java2
-rw-r--r--src/test/java/org/uic/barcode/asn1/test/UperEncodeSequenceOfIntegerTest.java8
-rw-r--r--src/test/java/org/uic/barcode/asn1/test/UperEncodeSequenceOfRestrictedIntegerTest.java8
9 files changed, 19 insertions, 19 deletions
diff --git a/src/test/java/org/uic/barcode/asn1/test/BinaryStringTest.java b/src/test/java/org/uic/barcode/asn1/test/BinaryStringTest.java
index bb06eae..6129db3 100644
--- a/src/test/java/org/uic/barcode/asn1/test/BinaryStringTest.java
+++ b/src/test/java/org/uic/barcode/asn1/test/BinaryStringTest.java
@@ -41,7 +41,7 @@ public class BinaryStringTest {
0b0000_0001,
};
String bs3 = AsnUtils.toBooleanString(mask);
- byte[] bytes2 = AsnUtils.fromBooleanString(bs3);
+ //byte[] bytes2 = AsnUtils.fromBooleanString(bs3);
byte[] mask2 = new byte[] {
@@ -51,7 +51,7 @@ public class BinaryStringTest {
0b0001_0000,
};
String bs4 = AsnUtils.toBooleanString(mask2);
- byte[] bytes3 = AsnUtils.fromBooleanString(bs4);
+ //byte[] bytes3 = AsnUtils.fromBooleanString(bs4);
assert(bs4.equals(ms2));
diff --git a/src/test/java/org/uic/barcode/asn1/test/TestSequenceOfLong.java b/src/test/java/org/uic/barcode/asn1/test/TestSequenceOfLong.java
index 61af5fa..821bf2b 100644
--- a/src/test/java/org/uic/barcode/asn1/test/TestSequenceOfLong.java
+++ b/src/test/java/org/uic/barcode/asn1/test/TestSequenceOfLong.java
@@ -13,7 +13,7 @@ public class TestSequenceOfLong extends Asn1SequenceOf<Long> {
public TestSequenceOfLong(List<Long> numbers) {
super();
for (Long number: numbers){
- this.add(new Long(number));
+ this.add(Long.valueOf(number));
}
}
diff --git a/src/test/java/org/uic/barcode/asn1/test/UperEncodeBooleanTest.java b/src/test/java/org/uic/barcode/asn1/test/UperEncodeBooleanTest.java
index dea2716..de39e5c 100644
--- a/src/test/java/org/uic/barcode/asn1/test/UperEncodeBooleanTest.java
+++ b/src/test/java/org/uic/barcode/asn1/test/UperEncodeBooleanTest.java
@@ -43,7 +43,7 @@ public class UperEncodeBooleanTest {
}
@Test public void testTrue() throws IllegalArgumentException, IllegalAccessException {
- TestRecord record = new TestRecord(new Boolean(true));
+ TestRecord record = new TestRecord(Boolean.valueOf(true));
byte[] encoded = UperEncoder.encode(record);
String hex = UperEncoder.hexStringFromBytes(encoded);
UperEncoder.logger.log(Level.FINEST,String.format("data hex: %s", hex));
@@ -51,7 +51,7 @@ public class UperEncodeBooleanTest {
}
@Test public void testFalse() throws IllegalArgumentException, IllegalAccessException {
- TestRecord record = new TestRecord(new Boolean(false));
+ TestRecord record = new TestRecord(Boolean.valueOf(false));
byte[] encoded = UperEncoder.encode(record);
String hex = UperEncoder.hexStringFromBytes(encoded);
UperEncoder.logger.log(Level.FINEST,String.format("data hex: %s", hex));
@@ -59,7 +59,7 @@ public class UperEncodeBooleanTest {
}
@Test public void testDecodeTrue() throws IllegalArgumentException, IllegalAccessException {
- TestRecord record = new TestRecord(new Boolean(true));
+ TestRecord record = new TestRecord(Boolean.valueOf(true));
byte[] encoded = UperEncoder.encode(record);
String hex = UperEncoder.hexStringFromBytes(encoded);
UperEncoder.logger.log(Level.FINEST,String.format("data hex: %s", hex));
@@ -70,7 +70,7 @@ public class UperEncodeBooleanTest {
}
@Test public void testDecodeFalse() throws IllegalArgumentException, IllegalAccessException {
- TestRecord record = new TestRecord(new Boolean(false));
+ TestRecord record = new TestRecord(Boolean.valueOf(false));
byte[] encoded = UperEncoder.encode(record);
String hex = UperEncoder.hexStringFromBytes(encoded);
UperEncoder.logger.log(Level.FINEST,String.format("data hex: %s", hex));
diff --git a/src/test/java/org/uic/barcode/asn1/test/UperEncodeIntegerConstrainedTest.java b/src/test/java/org/uic/barcode/asn1/test/UperEncodeIntegerConstrainedTest.java
index 2f46046..bde99fe 100644
--- a/src/test/java/org/uic/barcode/asn1/test/UperEncodeIntegerConstrainedTest.java
+++ b/src/test/java/org/uic/barcode/asn1/test/UperEncodeIntegerConstrainedTest.java
@@ -42,7 +42,7 @@ public class UperEncodeIntegerConstrainedTest {
public TestRecord() {
- this(new Long(63L));
+ this(Long.valueOf(63L));
}
public TestRecord(Long num) {
diff --git a/src/test/java/org/uic/barcode/asn1/test/UperEncodeIntegerSmallTest.java b/src/test/java/org/uic/barcode/asn1/test/UperEncodeIntegerSmallTest.java
index 39bfb32..d6600fe 100644
--- a/src/test/java/org/uic/barcode/asn1/test/UperEncodeIntegerSmallTest.java
+++ b/src/test/java/org/uic/barcode/asn1/test/UperEncodeIntegerSmallTest.java
@@ -33,7 +33,7 @@ public class UperEncodeIntegerSmallTest {
public Integer value2;
public TestRecord() {
- this(new Long(12345678909999899L));
+ this(Long.valueOf(12345678909999899L));
}
public TestRecord(Long num) {
diff --git a/src/test/java/org/uic/barcode/asn1/test/UperEncodeIntegerTest.java b/src/test/java/org/uic/barcode/asn1/test/UperEncodeIntegerTest.java
index 412689b..3e10fc7 100644
--- a/src/test/java/org/uic/barcode/asn1/test/UperEncodeIntegerTest.java
+++ b/src/test/java/org/uic/barcode/asn1/test/UperEncodeIntegerTest.java
@@ -30,7 +30,7 @@ public class UperEncodeIntegerTest {
Asn1BigInteger value;
public TestRecord() {
- this(new Long(12345678909999899L));
+ this(Long.valueOf(12345678909999899L));
}
public TestRecord(Long num) {
diff --git a/src/test/java/org/uic/barcode/asn1/test/UperEncodeRestrictedIntegerTest.java b/src/test/java/org/uic/barcode/asn1/test/UperEncodeRestrictedIntegerTest.java
index f806c88..3f0f08a 100644
--- a/src/test/java/org/uic/barcode/asn1/test/UperEncodeRestrictedIntegerTest.java
+++ b/src/test/java/org/uic/barcode/asn1/test/UperEncodeRestrictedIntegerTest.java
@@ -31,7 +31,7 @@ TestRecord ::= [APPLICATION 0] IMPLICIT SEQUENCE {
Long value;
public TestRecord() {
- this(new Long(33005));
+ this(Long.valueOf(33005));
}
public TestRecord(Long num) {
diff --git a/src/test/java/org/uic/barcode/asn1/test/UperEncodeSequenceOfIntegerTest.java b/src/test/java/org/uic/barcode/asn1/test/UperEncodeSequenceOfIntegerTest.java
index 3213b1e..ea0d955 100644
--- a/src/test/java/org/uic/barcode/asn1/test/UperEncodeSequenceOfIntegerTest.java
+++ b/src/test/java/org/uic/barcode/asn1/test/UperEncodeSequenceOfIntegerTest.java
@@ -46,8 +46,8 @@ TestRecord ::= [APPLICATION 0] IMPLICIT SEQUENCE {
@Test public void test() throws IllegalArgumentException, IllegalAccessException {
ArrayList<Long> nums = new ArrayList<Long>();
- nums.add(new Long(12345678909999899L));
- nums.add(new Long(12345678909999899L));
+ nums.add(Long.valueOf(12345678909999899L));
+ nums.add(Long.valueOf(12345678909999899L));
TestRecord record = new TestRecord(nums);
byte[] encoded = UperEncoder.encode(record);
String hex = UperEncoder.hexStringFromBytes(encoded);
@@ -59,8 +59,8 @@ TestRecord ::= [APPLICATION 0] IMPLICIT SEQUENCE {
@Test public void testDecode() throws IllegalArgumentException, IllegalAccessException {
ArrayList<Long> nums = new ArrayList<Long>();
- nums.add(new Long(12345678909999899L));
- nums.add(new Long(12345678909999899L));
+ nums.add(Long.valueOf(12345678909999899L));
+ nums.add(Long.valueOf(12345678909999899L));
TestRecord record = new TestRecord(nums);
byte[] encoded = UperEncoder.encode(record);
String hex = UperEncoder.hexStringFromBytes(encoded);
diff --git a/src/test/java/org/uic/barcode/asn1/test/UperEncodeSequenceOfRestrictedIntegerTest.java b/src/test/java/org/uic/barcode/asn1/test/UperEncodeSequenceOfRestrictedIntegerTest.java
index 33e9b9f..fffffd4 100644
--- a/src/test/java/org/uic/barcode/asn1/test/UperEncodeSequenceOfRestrictedIntegerTest.java
+++ b/src/test/java/org/uic/barcode/asn1/test/UperEncodeSequenceOfRestrictedIntegerTest.java
@@ -49,8 +49,8 @@ TestRecord ::= [APPLICATION 0] IMPLICIT SEQUENCE {
TestRecord record = new TestRecord();
- record.addNumber(new Long(9500001L));
- record.addNumber(new Long(9699999L));
+ record.addNumber(Long.valueOf(9500001L));
+ record.addNumber(Long.valueOf(9699999L));
byte[] encoded = UperEncoder.encode(record);
@@ -63,8 +63,8 @@ TestRecord ::= [APPLICATION 0] IMPLICIT SEQUENCE {
TestRecord record = new TestRecord();
- record.addNumber(new Long(9500001L));
- record.addNumber(new Long(9699999L));
+ record.addNumber(Long.valueOf(9500001L));
+ record.addNumber(Long.valueOf(9699999L));
byte[] encoded = UperEncoder.encode(record);