ViewVC Help
View File | Revision Log | Show Annotations | Download File | Root Listing
root/jsr166/jsr166/src/test/jtreg/util/Hashtable/IllegalLoadFactor.java
(Generate patch)

Comparing jsr166/src/test/jtreg/util/Hashtable/IllegalLoadFactor.java (file contents):
Revision 1.1 by jsr166, Tue Sep 1 01:25:04 2009 UTC vs.
Revision 1.3 by jsr166, Sun Sep 5 21:32:19 2010 UTC

# Line 1 | Line 1
1   /*
2 < * Copyright 1997-1998 Sun Microsystems, Inc.  All Rights Reserved.
2 > * Copyright (c) 1997, 1998, Oracle and/or its affiliates. All rights reserved.
3   * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER.
4   *
5   * This code is free software; you can redistribute it and/or modify it
# Line 16 | Line 16
16   * 2 along with this work; if not, write to the Free Software Foundation,
17   * Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA.
18   *
19 < * Please contact Sun Microsystems, Inc., 4150 Network Circle, Santa Clara,
20 < * CA 95054 USA or visit www.sun.com if you need additional information or
21 < * have any questions.
19 > * Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA
20 > * or visit www.oracle.com if you need additional information or have any
21 > * questions.
22   */
23  
24   /* @test
# Line 45 | Line 45 | public class IllegalLoadFactor {
45            catch (IllegalArgumentException e1) {
46                testSucceeded = true;
47            }
48 <          if(!testSucceeded)
48 >          if (!testSucceeded)
49                throw new Exception("Hashtable, negative load factor");
50  
51            testSucceeded = false;
# Line 56 | Line 56 | public class IllegalLoadFactor {
56            catch (IllegalArgumentException e1) {
57                testSucceeded = true;
58            }
59 <          if(!testSucceeded)
59 >          if (!testSucceeded)
60                throw new Exception("Hashtable, NaN load factor");
61  
62            testSucceeded = false;
# Line 67 | Line 67 | public class IllegalLoadFactor {
67            catch (IllegalArgumentException e1) {
68                testSucceeded = true;
69            }
70 <          if(!testSucceeded)
70 >          if (!testSucceeded)
71                throw new Exception("HashMap, negative load factor");
72  
73            testSucceeded = false;
# Line 78 | Line 78 | public class IllegalLoadFactor {
78            catch (IllegalArgumentException e1) {
79                testSucceeded = true;
80            }
81 <          if(!testSucceeded)
81 >          if (!testSucceeded)
82                throw new Exception("HashMap, NaN load factor");
83  
84  
# Line 90 | Line 90 | public class IllegalLoadFactor {
90            catch (IllegalArgumentException e1) {
91                testSucceeded = true;
92            }
93 <          if(!testSucceeded)
93 >          if (!testSucceeded)
94                throw new Exception("HashSet, negative load factor");
95  
96            testSucceeded = false;
# Line 101 | Line 101 | public class IllegalLoadFactor {
101            catch (IllegalArgumentException e1) {
102                testSucceeded = true;
103            }
104 <          if(!testSucceeded)
104 >          if (!testSucceeded)
105                throw new Exception("HashSet, NaN load factor");
106  
107            testSucceeded = false;
# Line 112 | Line 112 | public class IllegalLoadFactor {
112            catch (IllegalArgumentException e1) {
113                testSucceeded = true;
114            }
115 <          if(!testSucceeded)
115 >          if (!testSucceeded)
116                throw new Exception("WeakHashMap, negative load factor");
117  
118            testSucceeded = false;
# Line 123 | Line 123 | public class IllegalLoadFactor {
123            catch (IllegalArgumentException e1) {
124                testSucceeded = true;
125            }
126 <          if(!testSucceeded)
126 >          if (!testSucceeded)
127                throw new Exception("WeakHashMap, NaN load factor");
128  
129            // Make sure that legal creates don't throw exceptions

Diff Legend

Removed lines
+ Added lines
< Changed lines
> Changed lines