Mercurial > hg > rhino-tests
changeset 286:cf37f34b3231 draft
Added new testGetResourceNPETest case into
ScriptExceptionClassTest.
author | Pavel Tisnovsky <ptisnovs@redhat.com> |
---|---|
date | Mon, 09 Dec 2013 10:40:54 +0100 |
parents | 1a02ffbe785b |
children | 78d18ecc53b9 |
files | ChangeLog src/org/RhinoTests/ScriptExceptionClassTest.java |
diffstat | 2 files changed, 19 insertions(+), 0 deletions(-) [+] |
line wrap: on
line diff
--- a/ChangeLog Fri Dec 06 09:49:13 2013 +0100 +++ b/ChangeLog Mon Dec 09 10:40:54 2013 +0100 @@ -1,3 +1,9 @@ +2013-12-09 Pavel Tisnovsky <ptisnovs@redhat.com> + + * src/org/RhinoTests/ScriptExceptionClassTest.java: + Added new testGetResourceNPETest case into + ScriptExceptionClassTest. + 2013-12-06 Pavel Tisnovsky <ptisnovs@redhat.com> * src/org/RhinoTests/InvocableClassTest.java:
--- a/src/org/RhinoTests/ScriptExceptionClassTest.java Fri Dec 06 09:49:13 2013 +0100 +++ b/src/org/RhinoTests/ScriptExceptionClassTest.java Mon Dec 09 10:40:54 2013 +0100 @@ -1663,6 +1663,19 @@ } /** + * Test for method javax.script.ScriptException.getClass().getResourceNPETest() + */ + protected void testGetResourceNPETest() { + try { + Object resource = this.scriptExceptionClass.getResource(null); + throw new AssertionError("NullPointerException expected!"); + } + catch (NullPointerException e) { + //This is OK OK + } + } + + /** * Test for instanceof operator applied to a class javax.script.ScriptException */ @SuppressWarnings("cast")