Skip to content
Permalink
Browse files

[SMALLFIX]Update static

pr-link: #9080
change-id: cid-2c42fb8615cf0b74f6071ffd9f4b244419c55c39
  • Loading branch information...
XiaoMuxin authored and alluxio-bot committed May 15, 2019
1 parent c8e5dbf commit 3a8d17f564a9e91a1cf6c36b112c2120ee6f38aa
Showing with 7 additions and 6 deletions.
  1. +7 −6 core/common/src/test/java/alluxio/util/io/ByteIOUtilsTest.java
@@ -11,7 +11,8 @@

package alluxio.util.io;

import org.junit.Assert;
import static org.junit.Assert.assertEquals;

import org.junit.Test;

/**
@@ -29,7 +30,7 @@ public void readWriteByte() {
for (long i : values) {
byte v = (byte) i;
ByteIOUtils.writeByte(mBuf, 0, v);
Assert.assertEquals(v, ByteIOUtils.readByte(mBuf, 0));
assertEquals(v, ByteIOUtils.readByte(mBuf, 0));
}
}

@@ -42,9 +43,9 @@ public void readWriteShort() {
for (long i : values) {
short v = (short) i;
ByteIOUtils.writeShort(mBuf, 0, v);
Assert.assertEquals(v, ByteIOUtils.readShort(mBuf, 0));
assertEquals(v, ByteIOUtils.readShort(mBuf, 0));
ByteIOUtils.writeShort(mBuf, 1, v);
Assert.assertEquals(v, ByteIOUtils.readShort(mBuf, 1));
assertEquals(v, ByteIOUtils.readShort(mBuf, 1));
}
}

@@ -58,7 +59,7 @@ public void readWriteInt() {
int v = (int) i;
for (int pos = 0; pos < 4; pos++) {
ByteIOUtils.writeInt(mBuf, pos, v);
Assert.assertEquals(v, ByteIOUtils.readInt(mBuf, pos));
assertEquals(v, ByteIOUtils.readInt(mBuf, pos));
}
}
}
@@ -74,7 +75,7 @@ public void readWriteLong() {
for (long v : values) {
for (int pos = 0; pos < 8; pos++) {
ByteIOUtils.writeLong(mBuf, 0, v);
Assert.assertEquals(v, ByteIOUtils.readLong(mBuf, 0));
assertEquals(v, ByteIOUtils.readLong(mBuf, 0));
}
}
}

0 comments on commit 3a8d17f

Please sign in to comment.
You can’t perform that action at this time.