Home
last modified time | relevance | path

Searched refs:shorts (Results 1 – 5 of 5) sorted by relevance

/libcore/luni/src/test/java/libcore/java/lang/reflect/
DArrayTest.java30 private static short[] shorts; field in ArrayTest
41 shorts = new short[] { (short) 0xffff }; in setUp()
52 try { Array.getBoolean(shorts, 0); fail(); } catch (IllegalArgumentException expected) {} in testGetBoolean()
64 try { Array.getByte(shorts, 0); fail(); } catch (IllegalArgumentException expected) {} in testGetByte()
76 try { Array.getChar(shorts, 0); fail(); } catch (IllegalArgumentException expected) {} in testGetChar()
88 assertEquals((double) shorts[0], Array.getDouble(shorts, 0)); in testGetDouble()
100 assertEquals((float) shorts[0], Array.getFloat(shorts, 0)); in testGetFloat()
112 assertEquals((int) shorts[0], Array.getInt(shorts, 0)); in testGetInt()
124 assertEquals((long) shorts[0], Array.getLong(shorts, 0)); in testGetLong()
136 assertEquals(shorts[0], Array.getShort(shorts, 0)); in testGetShort()
[all …]
/libcore/luni/src/test/java/libcore/java/nio/
DBufferTest.java130 short[] shorts = new short[6]; in testByteSwappedBulkGet() local
131 b.order(ByteOrder.BIG_ENDIAN).asShortBuffer().get(shorts, 1, 4); in testByteSwappedBulkGet()
132 assertEquals(0, shorts[0]); in testByteSwappedBulkGet()
133 assertEquals(0x0102, shorts[1]); in testByteSwappedBulkGet()
134 assertEquals(0x0304, shorts[2]); in testByteSwappedBulkGet()
135 assertEquals(0x0506, shorts[3]); in testByteSwappedBulkGet()
136 assertEquals(0x0708, shorts[4]); in testByteSwappedBulkGet()
137 assertEquals(0, shorts[5]); in testByteSwappedBulkGet()
138 b.order(ByteOrder.LITTLE_ENDIAN).asShortBuffer().get(shorts, 1, 4); in testByteSwappedBulkGet()
139 assertEquals(0, shorts[0]); in testByteSwappedBulkGet()
[all …]
/libcore/luni/src/test/java/libcore/java/lang/invoke/
DMethodHandlesTest.java1262 public VariableArityTester(short... shorts) { update(shorts); } in VariableArityTester() argument
1280 public String update(short... shorts) { return lastResult = tally(shorts); } in update() argument
1309 public static String tally(short... shorts) { return Arrays.toString(shorts); } in tally() argument
DMethodHandleAccessorsTest.java600 short[] shorts = {(short) 0x1234, (short) 0x4321}; in testShortSettersAndGetters() local
601 for (short s : shorts) { in testShortSettersAndGetters()
/libcore/harmony-tests/src/test/java/org/apache/harmony/tests/java/io/
DSerializationStressTest1.java486 short[] shorts = { 0, 1, 2, 3 }; in test_18_5_writeObject() local
487 objToSave = shorts; in test_18_5_writeObject()