TestHarness.java (1447:7d34e91f66bb) | TestHarness.java (2169:860f1d21763a) |
---|---|
1/* 2 * Copyright (c) 2012, 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 6 * under the terms of the GNU General Public License version 2 only, as 7 * published by the Free Software Foundation. Oracle designates this 8 * particular file as subject to the "Classpath" exception as provided --- 286 unchanged lines hidden (view full) --- 295 296 try { 297 m.invoke(null); 298 fail("Exception should have been thrown"); 299 } catch (InvocationTargetException | IllegalAccessException e) { 300 if (verboseLocal.get() == Boolean.TRUE) { 301 System.out.println(e.getCause()); 302 } | 1/* 2 * Copyright (c) 2012, 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 6 * under the terms of the GNU General Public License version 2 only, as 7 * published by the Free Software Foundation. Oracle designates this 8 * particular file as subject to the "Classpath" exception as provided --- 286 unchanged lines hidden (view full) --- 295 296 try { 297 m.invoke(null); 298 fail("Exception should have been thrown"); 299 } catch (InvocationTargetException | IllegalAccessException e) { 300 if (verboseLocal.get() == Boolean.TRUE) { 301 System.out.println(e.getCause()); 302 } |
303 assertEquals(e.getCause().getClass(), exceptionType); | 303 assertTrue(exceptionType.isAssignableFrom(e.getCause().getClass())); |
304 } 305 compiler.cleanup(); 306 } 307 308 /** 309 * Convenience method for above, which assumes stdMethodName, 310 * a return type of 'int', and no arguments. 311 */ --- 43 unchanged lines hidden --- | 304 } 305 compiler.cleanup(); 306 } 307 308 /** 309 * Convenience method for above, which assumes stdMethodName, 310 * a return type of 'int', and no arguments. 311 */ --- 43 unchanged lines hidden --- |