You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@harmony.apache.org by "Tim Ellison (JIRA)" <ji...@apache.org> on 2009/04/16 12:24:14 UTC
[jira] Assigned: (HARMONY-6143) [classlib][beans]
java.beans.beancontext.BeanContextSupport.readChildren((ObjectInputStream)
null) should throw NullPointerException
[ https://issues.apache.org/jira/browse/HARMONY-6143?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ]
Tim Ellison reassigned HARMONY-6143:
------------------------------------
Assignee: Tim Ellison
> [classlib][beans] java.beans.beancontext.BeanContextSupport.readChildren((ObjectInputStream) null) should throw NullPointerException
> ------------------------------------------------------------------------------------------------------------------------------------
>
> Key: HARMONY-6143
> URL: https://issues.apache.org/jira/browse/HARMONY-6143
> Project: Harmony
> Issue Type: Bug
> Components: Classlib
> Affects Versions: 5.0M8
> Reporter: Kevin Zhou
> Assignee: Tim Ellison
> Fix For: 5.0M9
>
> Attachments: HARMONY-6143.diff
>
> Original Estimate: 48h
> Remaining Estimate: 48h
>
> Given a test case [1], RI passes them all while HY fails the 1st test scenario.
> Initialize a BeanContextSupport object using default constructor, add a object which implements Serializable. Then invoking readChildren of this object triggers a NullPointerException.
> But for HY, it needs to write this added object first, then invoking readChildren of this object can trigger a NullPointerException; otherwise no exception is thrown.
> [1] Test Case:
> public void test_readChildren_scenario1() throws Exception {
> BeanContextSupport beanContextSupport = new BeanContextSupport();
> beanContextSupport.add("Serializable");
> try {
> beanContextSupport.readChildren((ObjectInputStream) null);
> fail("should throw NullPointerException");
> } catch (NullPointerException e) {
> // Expected
> }
> }
> public void test_readChildren_scenario2() throws Exception {
> BeanContextSupport beanContextSupport = new BeanContextSupport();
> beanContextSupport.add("Serializable");
> beanContextSupport.writeChildren(new ObjectOutputStream(new ByteArrayOutputStream()));
> try {
> beanContextSupport.readChildren((ObjectInputStream) 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.