Lines Matching refs:toArray

33  * A generic JUnit test which tests {@code toArray()} operations on a
43 Object[] array = collection.toArray();
48 * {@link Collection#toArray(Object[])} says: "Note that
49 * <tt>toArray(new Object[0])</tt> is identical in function to
50 * <tt>toArray()</tt>."
56 Object[] array = collection.toArray();
62 E[] array = collection.toArray(empty);
63 assertEquals("toArray(emptyT[]) should return an array of type T",
65 assertEquals("toArray(emptyT[]).length:", getNumElements(), array.length);
72 E[] array = collection.toArray(empty);
73 assertEquals("toArray(emptyT[]) should return an array of type T",
75 assertEquals("toArray(emptyT[]).length:", getNumElements(), array.length);
81 Object[] array = collection.toArray(in);
82 assertEquals("toArray(emptyObject[]) should return an array of type Object",
84 assertEquals("toArray(emptyObject[]).length",
91 assertSame("toArray(sameSizeE[]) should return the given array",
92 array, collection.toArray(array));
99 assertSame("toArray(sameSizeE[]) should return the given array",
100 array, collection.toArray(array));
106 assertSame("toArray(sameSizeObject[]) should return the given array",
107 array, collection.toArray(array));
114 assertSame("toArray(sameSizeObject[]) should return the given array",
115 array, collection.toArray(array));
123 assertSame("toArray(overSizedE[]) should return the given array",
124 array, collection.toArray(array));
130 "toArray(overSizedE[]) should contain element " + expectedSubArray[i],
144 assertSame("toArray(overSizedE[]) should return the given array",
145 array, collection.toArray(array));
161 collection.toArray(array);
162 fail("toArray(notAssignableTo[]) should throw");
171 "toArray(sameSizeNotAssignableTo[]) should return the given array",
172 array, collection.toArray(array));
181 assertEquals("toArray() ordered contents: ",