test/jdk/java/util/concurrent/tck/MapTest.java
changeset 48541 946e34c2dec9
parent 47304 3f5f9bc0bdc2
child 53710 49adf961fcb1
equal deleted inserted replaced
48540:221cf8307606 48541:946e34c2dec9
   127         final Object v1 = (permitsNullValues && rnd.nextBoolean())
   127         final Object v1 = (permitsNullValues && rnd.nextBoolean())
   128             ? null : impl.makeValue(1);
   128             ? null : impl.makeValue(1);
   129         final Object v2 = (permitsNullValues && rnd.nextBoolean() && v1 != null)
   129         final Object v2 = (permitsNullValues && rnd.nextBoolean() && v1 != null)
   130             ? null : impl.makeValue(2);
   130             ? null : impl.makeValue(2);
   131 
   131 
   132         /** If true, always lands in first bucket in hash tables. */
   132         // If true, always lands in first bucket in hash tables.
   133         final boolean poorHash = rnd.nextBoolean();
   133         final boolean poorHash = rnd.nextBoolean();
   134         class Key implements Comparable<Key> {
   134         class Key implements Comparable<Key> {
   135             final int i;
   135             final int i;
   136             Key(int i) { this.i = i; }
   136             Key(int i) { this.i = i; }
   137             public int hashCode() { return poorHash ? 0 : super.hashCode(); }
   137             public int hashCode() { return poorHash ? 0 : super.hashCode(); }