diff options
author | CGantert345 <57003061+CGantert345@users.noreply.github.com> | 2022-04-13 17:57:16 +0200 |
---|---|---|
committer | GitHub <noreply@github.com> | 2022-04-13 17:57:16 +0200 |
commit | 7a5f15e2b958dca771b83594669401be2b84f2b6 (patch) | |
tree | d96492a7b1958f9822cd994c86d0b0a9f3c6c59f /src/test/java/org/uic/barcode/ticket/api/test/VoucherTimeZoneTestV3.java | |
parent | Merge pull request #45 from UnionInternationalCheminsdeFer/1.3.1 (diff) | |
parent | unit test for fcb version 1 including all elements (diff) | |
download | UIC-barcode-7a5f15e2b958dca771b83594669401be2b84f2b6.tar UIC-barcode-7a5f15e2b958dca771b83594669401be2b84f2b6.tar.gz UIC-barcode-7a5f15e2b958dca771b83594669401be2b84f2b6.tar.bz2 UIC-barcode-7a5f15e2b958dca771b83594669401be2b84f2b6.tar.lz UIC-barcode-7a5f15e2b958dca771b83594669401be2b84f2b6.tar.xz UIC-barcode-7a5f15e2b958dca771b83594669401be2b84f2b6.tar.zst UIC-barcode-7a5f15e2b958dca771b83594669401be2b84f2b6.zip |
Diffstat (limited to 'src/test/java/org/uic/barcode/ticket/api/test/VoucherTimeZoneTestV3.java')
-rw-r--r-- | src/test/java/org/uic/barcode/ticket/api/test/VoucherTimeZoneTestV3.java | 14 |
1 files changed, 8 insertions, 6 deletions
diff --git a/src/test/java/org/uic/barcode/ticket/api/test/VoucherTimeZoneTestV3.java b/src/test/java/org/uic/barcode/ticket/api/test/VoucherTimeZoneTestV3.java index 22b17c2..20fa455 100644 --- a/src/test/java/org/uic/barcode/ticket/api/test/VoucherTimeZoneTestV3.java +++ b/src/test/java/org/uic/barcode/ticket/api/test/VoucherTimeZoneTestV3.java @@ -1,6 +1,5 @@ package org.uic.barcode.ticket.api.test;
-import java.io.IOException;
import java.text.DateFormat;
import java.text.ParseException;
import java.text.SimpleDateFormat;
@@ -11,6 +10,7 @@ import org.junit.After; import org.junit.Before;
import org.junit.Test;
import org.uic.barcode.asn1.uper.UperEncoder;
+import org.uic.barcode.logger.LoggerFactory;
import org.uic.barcode.ticket.EncodingFormatException;
import org.uic.barcode.ticket.api.asn.omv3.UicRailTicketData;
import org.uic.barcode.ticket.api.spec.IVoucher;
@@ -86,6 +86,8 @@ public class VoucherTimeZoneTestV3 { * Prepare tickets.
*/
@Before public void prepare() {
+
+ LoggerFactory.setActivateConsoleLog(true);
defaulttimeZone = TimeZone.getDefault();
@@ -276,7 +278,7 @@ public class VoucherTimeZoneTestV3 { encodedInTimeZone2 = encoder.encode(iTicketDecodedFromAsn1Case2);
encodedInTimeZone3 = encoder.encode(iTicketDecodedFromAsn1Case3);
} catch (EncodingFormatException e) {
- e.printStackTrace();
+ assert(false);
}
}
@@ -290,8 +292,8 @@ public class VoucherTimeZoneTestV3 { iTicketDecodedCase1 = decoder.decodeFromAsn(encodedInTimeZone1);
iTicketDecodedCase2 = decoder.decodeFromAsn(encodedInTimeZone2);
iTicketDecodedCase3 = decoder.decodeFromAsn(encodedInTimeZone3);
- } catch (IOException e) {
- e.printStackTrace();
+ } catch (Exception e) {
+ assert(false);
}
}
@@ -305,8 +307,8 @@ public class VoucherTimeZoneTestV3 { iTicketDecodedFromAsn1Case1 = decoder.decodeFromAsn(encoded1);
iTicketDecodedFromAsn1Case2 = decoder.decodeFromAsn(encoded2);
iTicketDecodedFromAsn1Case3 = decoder.decodeFromAsn(encoded3);
- } catch (IOException e) {
- e.printStackTrace();
+ } catch (Exception e) {
+ assert(false);
}
}
|