harmony-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Kevin Zhou (JIRA)" <j...@apache.org>
Subject [jira] Closed: (HARMONY-6108) [classlib] [prefs] Preferences.nodeExists(null) should throw NPE when Preferences node has been removed
Date Thu, 16 Apr 2009 09:46:14 GMT

     [ https://issues.apache.org/jira/browse/HARMONY-6108?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel
]

Kevin Zhou closed HARMONY-6108.
-------------------------------


Thanks, Regis.

> [classlib] [prefs] Preferences.nodeExists(null) should throw NPE when Preferences node
has been removed
> -------------------------------------------------------------------------------------------------------
>
>                 Key: HARMONY-6108
>                 URL: https://issues.apache.org/jira/browse/HARMONY-6108
>             Project: Harmony
>          Issue Type: Bug
>          Components: Classlib
>    Affects Versions: 5.0M8
>            Reporter: Kevin Zhou
>            Assignee: Regis Xu
>             Fix For: 5.0M10
>
>         Attachments: HARMONY-6108.diff
>
>   Original Estimate: 24h
>  Remaining Estimate: 24h
>
> Given a test scenario[1], conduct it on RI and HARMONY.
> RI works well, while HARMONY fails on the 2nd try-catch.
> When a given Preferences node is removed, Preferences.nodeExist(null) should throw NPE
rather than IllegalStateException.
> [1]
> public void test_nodeExists() throws BackingStoreException {
> AbstractPreferences test = (AbstractPreferences) Preferences.userRoot()
> .node("test");
> // 1st
> try { test.nodeExists(null); fail("should throw NullPointerException"); } catch (NullPointerException
e) { // Expected }
> test.removeNode();
> // 2nd
> try { test.nodeExists(null); fail("should throw NullPointerException"); } } catch (NullPointerException
e) { // Expected }
> }

-- 
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.


Mime
View raw message