645N/A * Copyright (c) 2000, Oracle and/or its affiliates. All rights reserved. 645N/A * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. 645N/A * This code is free software; you can redistribute it and/or modify it 645N/A * under the terms of the GNU General Public License version 2 only, as 645N/A * published by the Free Software Foundation. 645N/A * This code is distributed in the hope that it will be useful, but WITHOUT 645N/A * ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or 645N/A * FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License 645N/A * version 2 for more details (a copy is included in the LICENSE file that 645N/A * accompanied this code). 645N/A * You should have received a copy of the GNU General Public License version * 2 along with this work; if not, write to the Free Software Foundation, * Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA. * Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA * or visit www.oracle.com if you need additional information or have any * @summary Basic test for LinkedHashMap. (Based on MapBash) for (
int i=
0; i<
numItr; i++) {
throw new Exception(
"Size not as expected.");
throw new Exception(
"Incorrect hashCode computation.");
throw new Exception(
"Collection views test failed.");
throw new Exception(
"Linked list doesn't contain a link.");
throw new Exception(
"Could not retrieve a link.");
throw new Exception(
"Map nonempty after removing all links.");
throw new Exception(
"Linked list size not as expected.");
throw new Exception(
"put returns non-null value erroenously.");
throw new Exception(
"put returns a null value erroenously.");
throw new Exception(
"Clone not equal to original. (1)");
throw new Exception(
"Clone not equal to original. (2)");
throw new Exception(
"Clone not equal to original. (3)");
throw new Exception(
"Clone not equal to original. (4)");
throw new Exception(
"Original doesn't contain clone!");
throw new Exception(
"Clone doesn't contain original!");
throw new Exception(
"Serialize Clone not equal to original. (1)");
throw new Exception(
"Serialize Clone not equal to original. (2)");
throw new Exception(
"Serialize Clone not equal to original. (3)");
throw new Exception(
"Serialize Clone not equal to original. (4)");
throw new Exception(
"Original doesn't contain Serialize clone!");
throw new Exception(
"Serialize Clone doesn't contain original!");
throw new Exception(
"entrySet().removeAll failed.");
throw new Exception(
"Iterator.remove() failed");
// Test ordering properties with insert order throw new Exception(
"Insertion order not preserved.");
throw new Exception(
"Wrong value: "+i+
", "+m.
get(x)+
", "+x);
throw new Exception(
"Insertion order not preserved after read.");
throw new Exception(
"Insert order not preserved after reinsert.");
throw new Exception(
"Insert-order Map != clone.");
throw new Exception(
"Clone: Wrong val: "+i+
", "+m.
get(x)+
", "+x);
throw new Exception(
"Clone: altered by read.");
// Test ordering properties with access order throw new Exception(
"Insertion order not properly preserved.");
throw new Exception(
"Wrong value: "+i+
", "+m.
get(x)+
", "+x);
throw new Exception(
"Insert order not properly altered by read.");
throw new Exception(
"Insertion order not altered by reinsert.");
throw new Exception(
"Access-order Map != clone.");
throw new Exception(
"Clone: Wrong val: "+i+
", "+m.
get(x)+
", "+x);
throw new Exception(
"Clone: order not properly altered by read.");