harmony-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Leo Li (JIRA)" <j...@apache.org>
Subject [jira] Created: (HARMONY-3775) [classlib][beans]java.beans.beancontext.BeanContextSupport.add() does not throw IllegalStateException while the validatePendingAdd() returns false.
Date Fri, 27 Apr 2007 03:04:16 GMT
[classlib][beans]java.beans.beancontext.BeanContextSupport.add() does not throw IllegalStateException
while the validatePendingAdd() returns false.
---------------------------------------------------------------------------------------------------------------------------------------------------

                 Key: HARMONY-3775
                 URL: https://issues.apache.org/jira/browse/HARMONY-3775
             Project: Harmony
          Issue Type: Bug
          Components: Classlib
            Reporter: Leo Li


Here is a testcase:
public void test_add_validate() throws Exception {
        MyBeanContextSupport mybeanContextSupport = new MyBeanContextSupport();
        try {
            mybeanContextSupport.add(new Object());
            fail("should throw IllegalStateException");
        } catch (IllegalStateException e) {
            // expected
        }
    }

private class MyBeanContextSupport extends BeanContextSupport
    {
        protected  boolean validatePendingAdd(Object targetChild)
        {
            return false;
        }        
    }

RI passes.
Harmony fails.

The same thing happens on remove() with validatePendingRemove() returns false.

-- 
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