8 *
9 * This code is distributed in the hope that it will be useful, but WITHOUT
10 * ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or
11 * FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License
12 * version 2 for more details (a copy is included in the LICENSE file that
13 * accompanied this code).
14 *
15 * You should have received a copy of the GNU General Public License version
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 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
25 * @summary Unit test for formatter
26 * @bug 4906370 4962433 4973103 4989961 5005818 5031150 4970931 4989491 5002937
27 * 5005104 5007745 5061412 5055180 5066788 5088703 6317248 6318369 6320122
28 * 6344623 6369500 6534606 6282094 6286592 6476425 5063507 6469160
29 *
30 * @run shell/timeout=240 Basic.sh
31 */
32
33 import static java.lang.System.out;
34
35 public class Basic {
36
37 private static int fail = 0;
38 private static int pass = 0;
39
40 private static Throwable first;
41
42 static void pass() {
43 pass++;
44 }
45
46 static void fail(String fs, Class ex) {
47 String s = "'" + fs + "': " + ex.getName() + " not thrown";
48 if (first == null)
|
8 *
9 * This code is distributed in the hope that it will be useful, but WITHOUT
10 * ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or
11 * FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License
12 * version 2 for more details (a copy is included in the LICENSE file that
13 * accompanied this code).
14 *
15 * You should have received a copy of the GNU General Public License version
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 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
25 * @summary Unit test for formatter
26 * @bug 4906370 4962433 4973103 4989961 5005818 5031150 4970931 4989491 5002937
27 * 5005104 5007745 5061412 5055180 5066788 5088703 6317248 6318369 6320122
28 * 6344623 6369500 6534606 6282094 6286592 6476425 5063507 6469160 6476168
29 *
30 * @run shell/timeout=240 Basic.sh
31 */
32
33 import static java.lang.System.out;
34
35 public class Basic {
36
37 private static int fail = 0;
38 private static int pass = 0;
39
40 private static Throwable first;
41
42 static void pass() {
43 pass++;
44 }
45
46 static void fail(String fs, Class ex) {
47 String s = "'" + fs + "': " + ex.getName() + " not thrown";
48 if (first == null)
|