Skip to content

Commit

Permalink
update Java version
Browse files Browse the repository at this point in the history
  • Loading branch information
peteroupc committed Aug 15, 2024
1 parent ac72ee1 commit 5b05366
Showing 1 changed file with 12 additions and 2 deletions.
14 changes: 12 additions & 2 deletions src/test/java/com/upokecenter/test/CBORObjectTest.java
Original file line number Diff line number Diff line change
Expand Up @@ -7801,6 +7801,7 @@ public static void TestWriteExtraOne(long longValue) {
}

private void TestWriteUnchangedFloatBits(int bits) {
try {
{
java.io.ByteArrayOutputStream ms = null;
try {
Expand All @@ -7811,7 +7812,7 @@ private void TestWriteUnchangedFloatBits(int bits) {
(byte)((bits >> 24) & 0xff),
(byte)((bits >> 16) & 0xff),
(byte)((bits >> 8) & 0xff),
(byte)(bits & 0xff)
(byte)(bits & 0xff),
};
CBORObject.WriteFloatingPointBits(ms, bits, 4, true);
TestCommon.AssertByteArraysEqual(expectedBytes, ms.toByteArray());
Expand All @@ -7820,9 +7821,14 @@ private void TestWriteUnchangedFloatBits(int bits) {
try { if (ms != null) { ms.close(); } } catch (java.io.IOException ex) {}
}
}
} catch (IOException ex) {
Assert.fail(ex.toString());
throw new IllegalStateException(ex.toString(), ex);
}
}

private void TestWriteUnchangedDoubleBits(long bits) {
try {
{
java.io.ByteArrayOutputStream ms = null;
try {
Expand All @@ -7837,7 +7843,7 @@ private void TestWriteUnchangedDoubleBits(long bits) {
(byte)((bits >> 24) & 0xffL),
(byte)((bits >> 16) & 0xffL),
(byte)((bits >> 8) & 0xffL),
(byte)(bits & 0xffL)
(byte)(bits & 0xffL),
};
CBORObject.WriteFloatingPointBits(ms, bits, 8, true);
TestCommon.AssertByteArraysEqual(expectedBytes, ms.toByteArray());
Expand All @@ -7846,6 +7852,10 @@ private void TestWriteUnchangedDoubleBits(long bits) {
try { if (ms != null) { ms.close(); } } catch (java.io.IOException ex) {}
}
}
} catch (IOException ex) {
Assert.fail(ex.toString());
throw new IllegalStateException(ex.toString(), ex);
}
}

@Test
Expand Down

0 comments on commit 5b05366

Please sign in to comment.