Home
last modified time | relevance | path

Searched refs:objArray (Results 1 – 19 of 19) sorted by relevance

/libcore/harmony-tests/src/test/java/org/apache/harmony/tests/java/util/
DTreeSetTest.java48 Object objArray[] = new Object[1000]; field in TreeSetTest
63 TreeSet myTreeSet = new TreeSet(Arrays.asList(objArray)); in test_ConstructorLjava_util_Collection()
65 myTreeSet.size() == objArray.length); in test_ConstructorLjava_util_Collection()
66 for (int counter = 0; counter < objArray.length; counter++) in test_ConstructorLjava_util_Collection()
68 .contains(objArray[counter])); in test_ConstructorLjava_util_Collection()
95 for (int i = 0; i < objArray.length; i++) in test_ConstructorLjava_util_SortedSet()
96 myTreeSet.add(objArray[i]); in test_ConstructorLjava_util_SortedSet()
99 anotherTreeSet.size() == objArray.length); in test_ConstructorLjava_util_SortedSet()
100 for (int counter = 0; counter < objArray.length; counter++) in test_ConstructorLjava_util_SortedSet()
102 anotherTreeSet.contains(objArray[counter])); in test_ConstructorLjava_util_SortedSet()
[all …]
DEmptyStackExceptionTest.java25 Object[] objArray = new Object[10]; field in EmptyStackExceptionTest
34 for (int counter = 0; counter < objArray.length + 1; counter++) in test_Constructor()
47 for (int counter = 0; counter < objArray.length; counter++) { in setUp()
48 objArray[counter] = new Integer(counter); in setUp()
52 for (int counter = 0; counter < objArray.length; counter++) { in setUp()
53 s.push(objArray[counter]); in setUp()
62 objArray = null; in tearDown()
DTreeMapTest.java92 Object objArray[] = new Object[1000]; field in TreeMapTest
128 assertTrue("Map is incorrect size", myTreeMap.size() == objArray.length); in test_ConstructorLjava_util_Map()
129 for (Object element : objArray) { in test_ConstructorLjava_util_Map()
173 for (Object element : objArray) { in test_clone()
234 .containsValue(objArray[986])); in test_containsValueLjava_lang_Object()
247 anEntrySet.size() == objArray.length); in test_entrySet()
410 ks.size() == objArray.length); in test_keySet()
423 objArray[objArray.length - 1].toString())); in test_lastKey()
424 assertNotSame(objArray[objArray.length - 1].toString(), tm.lastKey()); in test_lastKey()
425 assertEquals(objArray[objArray.length - 2].toString(), tm in test_lastKey()
[all …]
DLinkedListTest.java57 Object[] objArray; field in LinkedListTest
98 ll.get(51) == objArray[50] && (ll.get(52) == objArray[51])); in test_addILjava_lang_Object()
153 assertTrue("Manipulated elements < index", ll.get(i) == objArray[i]); in test_addAllILjava_util_Collection()
156 ll.get(i) == objArray[i - 50]); in test_addAllILjava_util_Collection()
159 ll.get(i) == objArray[i - 100]); in test_addAllILjava_util_Collection()
325 .contains(objArray[99])); in test_containsLjava_lang_Object()
340 assertTrue("Returned incorrect element", ll.get(22) == objArray[22]); in test_getI()
356 assertEquals("Returned incorrect first element", ll.peek(), objArray[0]); in test_peek()
357 … assertEquals("Peek remove the head (first element) of this list", ll.getFirst(), objArray[0]); in test_peek()
366 objArray[0])); in test_getFirst()
[all …]
DHashSetTest.java43 Object[] objArray; field in HashSetTest
91 HashSet hs2 = new HashSet(Arrays.asList(objArray)); in test_ConstructorLjava_util_Collection()
92 for (int counter = 0; counter < objArray.length; counter++) in test_ConstructorLjava_util_Collection()
94 .contains(objArray[counter])); in test_ConstructorLjava_util_Collection()
96 hs2.size() == objArray.length); in test_ConstructorLjava_util_Collection()
148 assertTrue("Returned false for valid object", hs.contains(objArray[90])); in test_containsLjava_lang_Object()
206 assertTrue("Returned incorrect size", hs.size() == (objArray.length + 1)); in test_size()
286 objArray = new Object[1000]; in setUp()
287 for (int i = 0; i < objArray.length; i++) { in setUp()
288 objArray[i] = new Integer(i); in setUp()
[all …]
DLinkedHashSetTest.java40 Object[] objArray; field in LinkedHashSetTest
101 LinkedHashSet hs2 = new LinkedHashSet(Arrays.asList(objArray)); in test_ConstructorLjava_util_Collection()
102 for (int counter = 0; counter < objArray.length; counter++) in test_ConstructorLjava_util_Collection()
104 .contains(objArray[counter])); in test_ConstructorLjava_util_Collection()
106 .size() == objArray.length); in test_ConstructorLjava_util_Collection()
160 assertTrue("Returned false for valid object", hs.contains(objArray[90])); in test_containsLjava_lang_Object()
224 assertTrue("Returned incorrect size", hs.size() == (objArray.length + 1)); in test_size()
359 objArray = new Object[1000]; in setUp()
360 for (int i = 0; i < objArray.length; i++) in setUp()
361 objArray[i] = new Integer(i); in setUp()
[all …]
DIdentityHashMap2Test.java50 private Object[] objArray; field in IdentityHashMap2Test
93 myMap.put(objArray2[counter], objArray[counter]); in test_ConstructorLjava_util_Map()
202 .containsValue(objArray[19])); in test_containsValueLjava_lang_Object()
258 for (int i = 0; i < objArray.length; i++) { in test_keySet()
362 m.remove(objArray[0])); in test_removeLjava_lang_Object()
371 assertEquals("Returned incorrect size, ", (objArray.length), hm.size()); in test_size()
427 for (int i = 0; i < objArray.length; i++) in test_values()
429 .contains(objArray[i])); in test_values()
433 myIdentityHashMap.put(objArray2[i], objArray[i]); in test_values()
435 values.remove(objArray[0]); in test_values()
[all …]
DArrayListTest.java42 Object[] objArray; field in ArrayListTest
80 ArrayList al = new ArrayList(Arrays.asList(objArray)); in test_ConstructorLjava_util_Collection()
82 .size() == objArray.length); in test_ConstructorLjava_util_Collection()
83 for (int counter = 0; counter < objArray.length; counter++) in test_ConstructorLjava_util_Collection()
86 al.get(counter) == objArray[counter]); in test_ConstructorLjava_util_Collection()
111 alist.get(51) == objArray[50] in test_addILjava_lang_Object()
112 && (alist.get(52) == objArray[51])); in test_addILjava_lang_Object()
121 assertEquals(alist.get(1), objArray[0]); in test_addILjava_lang_Object()
122 assertEquals(alist.get(2), objArray[1]); in test_addILjava_lang_Object()
171 assertEquals(alist.get(size - 2), objArray[size - 2]); in test_addILjava_lang_Object_2()
[all …]
DCollectionsTest.java73 private Integer[] objArray; field in CollectionsTest
406 objArray[count++]); in test_enumerationLjava_util_Collection()
408 assertEquals("Enumeration missing elements: " + count, objArray.length, in test_enumerationLjava_util_Collection()
452 objArray[objArray.length - 1]); in test_maxLjava_util_Collection()
492 objArray[0]); in test_minLjava_util_Collection()
504 myobjArray[objArray.length - 1]); in test_minLjava_util_CollectionLjava_util_Comparator()
552 int count = objArray.length - 1; in test_reverseLjava_util_List()
554 assertEquals("Failed to reverse collection", objArray[count], i in test_reverseLjava_util_List()
773 smallList.add(objArray[i]); in test_swapLjava_util_ListII()
881 smallList.add(objArray[i]); in test_replaceAllLjava_util_ListLjava_lang_ObjectLjava_lang_Object()
[all …]
DTreeMapExtendTest.java75 Object objArray[] = new Object[1000]; field in TreeMapExtendTest
187 key = objArray[counter].toString(); in test_SubMap_containsKey()
201 key = objArray[100].toString(); in test_SubMap_containsKey()
213 key = objArray[109].toString(); in test_SubMap_containsKey()
227 key = objArray[counter].toString(); in test_SubMap_containsKey()
245 key = objArray[100].toString(); in test_SubMap_containsKey()
257 key = objArray[109].toString(); in test_SubMap_containsKey()
273 value = objArray[counter]; in test_SubMap_containsValue()
287 value = objArray[100]; in test_SubMap_containsValue()
299 value = objArray[109]; in test_SubMap_containsValue()
[all …]
DHashMapTest.java99 Object[] objArray; field in HashMapTest
161 myMap.put(objArray2[counter], objArray[counter]); in test_ConstructorLjava_util_Map()
359 for (int i = 0; i < objArray.length; i++) in test_keySet()
361 .contains(objArray[i].toString())); in test_keySet()
590 hm.size() == (objArray.length + 2)); in test_size()
601 for (int i = 0; i < objArray.length; i++) in test_values()
603 .contains(objArray[i])); in test_values()
607 myHashMap.put(objArray2[i], objArray[i]); in test_values()
928 objArray = new Object[hmSize]; in setUp()
930 for (int i = 0; i < objArray.length; i++) { in setUp()
[all …]
DLinkedHashMapTest.java48 Object[] objArray; field in LinkedHashMapTest
130 myMap.put(objArray2[counter], objArray[counter]); in test_ConstructorLjava_util_Map()
259 for (int i = 0; i < objArray.length; i++) in test_keySet()
261 .contains(objArray[i].toString())); in test_keySet()
313 for (int i = 0; i < objArray.length; i++) in test_values()
315 .contains(objArray[i])); in test_values()
319 myLinkedHashMap.put(objArray2[i], objArray[i]); in test_values()
515 hm.size() == (objArray.length + 2)); in test_size()
926 objArray = new Object[hmSize]; in setUp()
928 for (int i = 0; i < objArray.length; i++) { in setUp()
[all …]
DIdentityHashMapTest.java61 Object[] objArray; field in IdentityHashMapTest
103 myMap.put(objArray2[counter], objArray[counter]); in test_ConstructorLjava_util_Map()
195 .containsValue(objArray[19])); in test_containsValueLjava_lang_Object()
252 for (int i = 0; i < objArray.length; i++) { in test_keySet()
374 m.remove(objArray[0])); in test_removeLjava_lang_Object()
397 assertEquals("Returned incorrect size, ", (objArray.length + 2), hm in test_size()
466 objArray = new Object[hmSize]; in setUp()
468 for (int i = 0; i < objArray.length; i++) { in setUp()
469 objArray[i] = new Integer(i); in setUp()
471 objArray2[i] = new String(objArray[i].toString()); in setUp()
[all …]
DArraysTest.java59 Object[] objArray; field in ArraysTest
276 Arrays.binarySearch(objectArray, objArray[counter]) == counter); in test_binarySearch$Ljava_lang_ObjectLjava_lang_Object()
305 objectArray[counter] = objArray[arraySize - counter - 1]; in test_binarySearch$Ljava_lang_ObjectLjava_lang_ObjectLjava_util_Comparator()
314 Arrays.binarySearch(objectArray, objArray[counter], comp) == arraySize in test_binarySearch$Ljava_lang_ObjectLjava_lang_ObjectLjava_util_Comparator()
2516 objArray = new Object[arraySize]; in setUp()
2517 for (int i = 0; i < objArray.length; i++) in setUp()
2518 objArray[i] = new Integer(i); in setUp()
2537 objectArray[counter] = objArray[counter]; in setUp()
3027 … Arrays.binarySearch(objectArray, counter, arraySize, objArray[counter]) == counter); in test_binarySearch$Ljava_lang_ObjectIILjava_lang_Object()
3094 objectArray[counter] = objArray[arraySize - counter - 1]; in test_binarySearch$Ljava_lang_ObjectIILjava_lang_ObjectLjava_util_Comparator()
[all …]
DVectorTest.java44 Object[] objArray; field in VectorTest
134 myVector.size() == objArray.length); in test_ConstructorLjava_util_Collection()
135 for (int counter = 0; counter < objArray.length; counter++) in test_ConstructorLjava_util_Collection()
1274 assertTrue("Returned incorrect array", Arrays.equals(objArray, tVector in test_toArray()
1539 objArray = new Object[100]; in setUp()
1541 objArray[i] = "Test " + i; in setUp()
/libcore/luni/src/test/java/libcore/java/util/
DOldTreeSetTest.java33 Object objArray[] = new Object[1000]; field in OldTreeSetTest
37 TreeSet myTreeSet = new TreeSet(Arrays.asList(objArray)); in test_ConstructorLjava_util_Collection()
39 myTreeSet.size() == objArray.length); in test_ConstructorLjava_util_Collection()
40 for (int counter = 0; counter < objArray.length; counter++) in test_ConstructorLjava_util_Collection()
42 .contains(objArray[counter])); in test_ConstructorLjava_util_Collection()
76 ts.add(objArray[0]); in test_addLjava_lang_Object()
77 assertTrue("Added existing element", ts.size() == objArray.length + 1); in test_addLjava_lang_Object()
123 ts.first() == objArray[0]); in test_first()
140 assertTrue("Returned incorrect set", s.contains(objArray[i])); in test_headSetLjava_lang_Object()
168 ts.last() == objArray[objArray.length - 1]); in test_last()
[all …]
DOldListIteratorTest.java29 static Object[] objArray; field in OldListIteratorTest
31 objArray = new Object[100];
32 for (int i = 0; i < objArray.length; i++)
33 objArray[i] = new Integer(i);
37 for (int i = 0; i < objArray.length; i++) { in testHasNext()
45 for (int i = 0; i < objArray.length; i++) { in testNext()
46 assertTrue(objArray[i].equals(l.next())); in testNext()
106 for (int i = 0; i < objArray.length; i++) { in testRemove()
130 for (int i = 0; i < objArray.length; i++) { in testHasPrevious()
147 for (int i = objArray.length - 1; i > -1 ; i--) { in testPrevious()
[all …]
DOldTreeMapTest.java81 Object objArray[] = new Object[1000]; field in OldTreeMapTest
108 assertTrue("Map is incorrect size", myTreeMap.size() == objArray.length); in test_ConstructorLjava_util_Map()
109 for (Object element : objArray) { in test_ConstructorLjava_util_Map()
292 objArray[objArray.length - 1].toString())); in test_lastKey()
349 for (Object element : objArray) { in test_putAllLjava_util_Map()
396 SortedMap subMap = tm.subMap(objArray[100].toString(), objArray[109] in test_subMapLjava_lang_ObjectLjava_lang_Object()
401 objArray[counter].toString()).equals(objArray[counter])); in test_subMapLjava_lang_ObjectLjava_lang_Object()
405 tm.subMap(objArray[9].toString(), objArray[1].toString()); in test_subMapLjava_lang_ObjectLjava_lang_Object()
437 tm.subMap(objArray[9].toString(), null); in test_subMapLjava_lang_ObjectLjava_lang_Object()
444 tm.subMap(null, objArray[9].toString()); in test_subMapLjava_lang_ObjectLjava_lang_Object()
[all …]
/libcore/support/src/test/java/tests/support/
DSupport_UnmodifiableCollectionTest.java92 Object[] objArray; in runTest() local
93 objArray = col.toArray(); in runTest()
97 objArray[counter] == it.next()); in runTest()
101 objArray = new Object[100]; in runTest()
102 col.toArray(objArray); in runTest()
106 objArray[counter] == it.next()); in runTest()