/libcore/luni/src/test/java/libcore/java/util/ |
D | ArrayListTest.java | 36 list.subList(1, 2); in test_sublist_throws() 37 list.subList(0, 3); in test_sublist_throws() 38 list.subList(1, 1); in test_sublist_throws() 42 list.subList(-1, 1); // fromIndex out of bounds in test_sublist_throws() 48 list.subList(0, 4); // toIndex out of bounds in test_sublist_throws() 54 list.subList(-1, 4); // both fromIndex and toIndex out of bounds in test_sublist_throws() 60 list.subList(1, 0); // fromIndex > toIndex in test_sublist_throws() 68 list.subList(1, 2).set(0, "ONE"); in test_sublist_set() 71 list.subList(1, 2).subList(0, 1).set(0, "1"); in test_sublist_set() 75 list.subList(1, 2).set(2, "out of bounds"); in test_sublist_set()
|
D | AbstractListTest.java | 54 new RandomAccessList(/* size */ 0).subList(0, 0); in sublist_outOfBounds() 55 new RandomAccessList(/* size */ 10).subList(0, 10); in sublist_outOfBounds() 56 new RandomAccessList(/* size */ 10).subList(2, 5); in sublist_outOfBounds() 57 new SequentialList(/* elements */).subList(0, 0); in sublist_outOfBounds() 58 new SequentialList(/* elements */ 10, 20, 30).subList(0, 3); in sublist_outOfBounds() 63 list.subList(startIndex, endIndex); in assertSubListOutOfBounds() 118 () -> new OnlyRandomAccessList(listSize).subList(0, subListSize)); in checkSpliteratorOfOnlyRandomAccessList_usesOnlyRandomAccess()
|
D | CollectionsTest.java | 802 keysInOrder.subList(0, i), in check_unmodifiableNavigableMap_defaultMethods() 803 valuesInOrder.subList(0, i), in check_unmodifiableNavigableMap_defaultMethods() 808 keysInOrder.subList(0, i), in check_unmodifiableNavigableMap_defaultMethods() 809 valuesInOrder.subList(0, i), in check_unmodifiableNavigableMap_defaultMethods() 814 keysInOrder.subList(0, i + 1), in check_unmodifiableNavigableMap_defaultMethods() 815 valuesInOrder.subList(0, i + 1), in check_unmodifiableNavigableMap_defaultMethods() 823 keysInOrder.subList(0, i), in check_unmodifiableNavigableMap_defaultMethods() 824 valuesInOrder.subList(0, i), in check_unmodifiableNavigableMap_defaultMethods() 831 keysInOrder.subList(i, numEntries), in check_unmodifiableNavigableMap_defaultMethods() 832 valuesInOrder.subList(i, numEntries), in check_unmodifiableNavigableMap_defaultMethods() [all …]
|
D | ListOfTest.java | 184 assertEquals(expected, actual.subList(0, 0)); in assertBehaviorCommonToAllOfInstances() 186 assertEquals(expected.subList(1, expected.size()), actual.subList(1, actual.size())); in assertBehaviorCommonToAllOfInstances()
|
/libcore/ojluni/src/test/java/util/List/ |
D | ListFactories.java | 113 a(List.<String>of().subList(0,0), in sublists() 115 a(List.of("a").subList(0,0), in sublists() 116 asList("a").subList(0,0)), in sublists() 117 a(List.of("a", "b").subList(0,1), in sublists() 118 asList("a", "b").subList(0,1)), in sublists() 119 a(List.of("a", "b", "c").subList(1,3), in sublists() 120 asList("a", "b", "c").subList(1,3)), in sublists() 121 a(List.of("a", "b", "c", "d").subList(0,4), in sublists() 122 asList("a", "b", "c", "d").subList(0,4)), in sublists() 123 a(List.of("a", "b", "c", "d", "e").subList(0,3), in sublists() [all …]
|
/libcore/ojluni/src/test/java/util/ArrayList/ |
D | SubListModCount.java | 40 var subList = root.subList(0, 0); in main() local 43 subList.size(); in main() 48 var subSubList = subList.subList(0, 0); in main() 62 subList.size(); in main()
|
/libcore/luni/src/test/java/libcore/java/util/concurrent/ |
D | CopyOnWriteArrayListTest.java | 56 List<String> bcd = list.subList(1, 4); in testSubListAndNonStructuralChanges() 68 List<String> bcd = list.subList(1, 4); in testSubListAndStructuralChanges() 80 List<String> bcd = list.subList(1, 4); in testSubListAndSizePreservingStructuralChanges() 116 List<String> bcd = list.subList(1, 4); in testSubListClear() 124 new CopyOnWriteArrayList<String>().subList(0, 0).clear(); // the RI fails here in testSubListClearWhenEmpty() 130 Iterator<String> bcd = list.subList(1, 4).iterator(); in testSubListIteratorGetsSnapshot() 141 List<String> bcd = list.subList(1, 4); in testSubListRemoveByValue() 150 List<String> bcd = list.subList(1, 4); in testSubListRemoveByIndex() 159 List<String> def = list.subList(3, 6); in testSubListRetainAll() 168 List<String> def = list.subList(3, 6); in testSubListRemoveAll() [all …]
|
/libcore/harmony-tests/src/test/java/org/apache/harmony/tests/java/util/ |
D | AbstractListTest.java | 133 List sList = mList.subList(0, 2); in test_subListII() 165 al.subList(3, 7) instanceof RandomAccess); in test_subListII() 173 !(ll.subList(3, 7) instanceof RandomAccess)); in test_subListII() 184 List emptySubList = al.subList(0, 0); in test_subList_empty() 285 List subList = mainList.subList(1, 2); in test_subList_addAll() local 286 assertFalse("subList should not contain \"a\"", subList.contains("a")); in test_subList_addAll() 287 assertFalse("subList should not contain \"c\"", subList.contains("c")); in test_subList_addAll() 288 assertTrue("subList should contain \"b\"", subList.contains("b")); in test_subList_addAll() 291 subList.addAll(Arrays.asList(subObjects)); in test_subList_addAll() 292 assertFalse("subList should not contain \"a\"", subList.contains("a")); in test_subList_addAll() [all …]
|
D | ConcurrentModTest.java | 44 List sub = al.subList(1, 3); in testGet() 88 List sub = al.subList(1, 3); in testSet() 118 List sub = al.subList(1, 3); in testAdd() 148 List sub = al.subList(1, 3); in testRemove() 214 List sub = al.subList(1, 3); in testAddAll()
|
D | CollectionsTest.java | 967 List subList = list.subList(1, 5); in testRotate() local 968 Collections.rotate(subList, -1); in testRotate() 973 Collections.rotate(subList, 2); in testRotate() 1088 sub = new ArrayList(src.subList(3, 11)); in test_indexOfSubList2() 1093 sub = new ArrayList(src.subList(6, 11)); in test_indexOfSubList2() 1098 sub = new ArrayList(src.subList(0, 3)); in test_indexOfSubList2() 1103 sub = new ArrayList(src.subList(9, 11)); in test_indexOfSubList2() 1108 sub = new ArrayList(src.subList(10, 11)); in test_indexOfSubList2() 1113 sub = new ArrayList(src.subList(0, 11)); in test_indexOfSubList2() 1201 sub = new ArrayList(src.subList(0, 8)); in test_lastIndexOfSubList2() [all …]
|
/libcore/ojluni/src/test/java/util/concurrent/tck/ |
D | CopyOnWriteArrayListTest.java | 66 return super.emptyCollection().subList(0, 0); in suite() 533 assertTrue(a.subList(1,1).isEmpty()); in testSubList() 536 List b = a.subList(j,i); in testSubList() 543 List s = a.subList(2, 5); in testSubList() 572 List[] lists = { c, c.subList(1, c.size() - 1) }; in testGet1_IndexOutOfBoundsException() 586 List[] lists = { c, c.subList(1, c.size() - 1) }; in testGet2_IndexOutOfBoundsException() 600 List[] lists = { c, c.subList(1, c.size() - 1) }; in testSet1_IndexOutOfBoundsException() 614 List[] lists = { c, c.subList(1, c.size() - 1) }; in testSet2() 628 List[] lists = { c, c.subList(1, c.size() - 1) }; in testAdd1_IndexOutOfBoundsException() 642 List[] lists = { c, c.subList(1, c.size() - 1) }; in testAdd2_IndexOutOfBoundsException() [all …]
|
D | ArrayListTest.java | 58 return super.emptyCollection().subList(0, 0); in suite()
|
D | VectorTest.java | 58 return super.emptyCollection().subList(0, 0); in suite()
|
/libcore/jsr166-tests/src/test/java/jsr166/ |
D | CopyOnWriteArrayListTest.java | 495 assertTrue(a.subList(1,1).isEmpty()); in testSubList() 498 List b = a.subList(j,i); in testSubList() 505 List s = a.subList(2, 5); in testSubList() 534 List[] lists = { c, c.subList(1, c.size() - 1) }; in testGet1_IndexOutOfBoundsException() 548 List[] lists = { c, c.subList(1, c.size() - 1) }; in testGet2_IndexOutOfBoundsException() 562 List[] lists = { c, c.subList(1, c.size() - 1) }; in testSet1_IndexOutOfBoundsException() 576 List[] lists = { c, c.subList(1, c.size() - 1) }; in testSet2() 590 List[] lists = { c, c.subList(1, c.size() - 1) }; in testAdd1_IndexOutOfBoundsException() 604 List[] lists = { c, c.subList(1, c.size() - 1) }; in testAdd2_IndexOutOfBoundsException() 618 List[] lists = { c, c.subList(1, c.size() - 1) }; in testRemove1_IndexOutOfBounds() [all …]
|
/libcore/ojluni/src/test/java/util/Collections/ |
D | NCopies.java | 87 checkEmpty(x.subList(x.size()/2, x.size()/2)); in checkFoos() 144 checkEmpty(empty.subList(0,0)); 148 checkFoos(foos.subList(foos.size()/2, foos.size()-1));
|
D | CheckedListBash.java | 168 if (all.subList(i, all.size()).indexOf(o) != 0 || in main() 169 all.subList(i+1, all.size()).indexOf(o) != -1) in main() 171 if (all.subList(0,i+1).lastIndexOf(o) != i) in main() 189 || !l.equals(Arrays.asList(ia).subList(0, listSize))) in main()
|
/libcore/ojluni/src/test/java/util/SequencedCollection/ |
D | SimpleList.java | 151 public List<E> subList(int fromIndex, int toIndex) { in subList() method in SimpleList 152 return list.subList(fromIndex, toIndex); in subList()
|
/libcore/ojluni/src/test/java/util/Collection/ |
D | MOAT.java | 87 testCollection(new Vector<Integer>().subList(0,0)); in realMain() 90 testCollection(new ArrayList<Integer>().subList(0,0)); in realMain() 92 testCollection(new LinkedList<Integer>().subList(0,0)); in realMain() 104 testCollection(new CopyOnWriteArrayList<Integer>().subList(0,0)); in realMain() 204 testImmutableList(singletonList.subList(0,1)); in realMain() 205 testImmutableList(singletonList.subList(0,1).subList(0,1)); in realMain() 206 testEmptyList(singletonList.subList(0,0)); in realMain() 207 testEmptyList(singletonList.subList(0,0).subList(0,0)); in realMain() 216 testEmptyList(List.of().subList(0,0)); in realMain() 218 testListMutatorsAlwaysThrow(List.<Integer>of().subList(0,0)); in realMain() [all …]
|
/libcore/ojluni/src/main/java/sun/util/locale/ |
D | LocaleMatcher.java | 116 nonZeroRanges = priorityList.subList(0, splitIndex); in filterBasic() 117 zeroRanges = priorityList.subList(splitIndex, priorityList.size()); in filterBasic() 232 nonZeroRanges = priorityList.subList(0, splitIndex); in filterExtended() 233 zeroRanges = priorityList.subList(splitIndex, priorityList.size()); in filterExtended() 388 nonZeroRanges = priorityList.subList(0, splitIndex); in lookupTag() 389 zeroRanges = priorityList.subList(splitIndex, priorityList.size()); in lookupTag()
|
/libcore/luni/src/test/androidsdk34/src/libcore/android34/java/util/ |
D | ListTest.java | 152 public List<String> subList(int fromIndex, int toIndex) { in subList() method in ListTest.MyList 153 return l.subList(fromIndex, toIndex); in subList()
|
/libcore/ojluni/src/test/java/util/stream/boottest/java/util/stream/ |
D | IntNodeTest.java | 118 tree(l.subList(0, l.size() / 2), m), in tree() 119 tree(l.subList(l.size() / 2, l.size()), m)); in tree()
|
D | NodeTest.java | 95 tree(l.subList(0, l.size() / 2), m), in tree() 96 tree(l.subList(l.size() / 2, l.size()), m )); in tree()
|
D | LongNodeTest.java | 118 tree(l.subList(0, l.size() / 2), m), in tree() 119 tree(l.subList(l.size() / 2, l.size()), m)); in tree()
|
D | DoubleNodeTest.java | 118 tree(l.subList(0, l.size() / 2), m), in tree() 119 tree(l.subList(l.size() / 2, l.size()), m)); in tree()
|
/libcore/ojluni/src/test/java/util/stream/bootlib/java/util/stream/ |
D | StreamTestDataProvider.java | 105 … (ints.length) <= 1 ? aList.subList(0, 0) : aList.subList(1, ints.length / 2)));
|