You are viewing a plain text version of this content. The canonical link for it is here.
Posted to issues@commons.apache.org by "Jaroslav Simak (JIRA)" <ji...@apache.org> on 2013/01/24 10:11:12 UTC
[jira] [Created] (BEANUTILS-419) IllegalArgumentException when
setting property with no index between square brackets
Jaroslav Simak created BEANUTILS-419:
----------------------------------------
Summary: IllegalArgumentException when setting property with no index between square brackets
Key: BEANUTILS-419
URL: https://issues.apache.org/jira/browse/BEANUTILS-419
Project: Commons BeanUtils
Issue Type: Bug
Components: Bean / Property Utils
Affects Versions: 1.8.3
Environment: Sun Java 6
Fedora 17
Reporter: Jaroslav Simak
Priority: Minor
{noformat}
public class BeanUtilsTest {
@Test
public void testSetPropertyWithNoIndexBetweenSquareBrackets() throws IllegalAccessException, InvocationTargetException {
// GIVEN
final SimpleBean bean = new SimpleBean();
final String propName = "property[]";
final String value = "myValue";
// WHEN
BeanUtils.setProperty(bean, propName, value);
// THEN
// Should not fail
}
public static class SimpleBean {
private String property;
public String getProperty() {
return property;
}
public void setProperty(String property) {
this.property = property;
}
}
}
{noformat}
Doesnt fail with BeanUtils 1.6.1
Fails with BeanUtils 1.8.3
--
This message is automatically generated by JIRA.
If you think it was sent incorrectly, please contact your JIRA administrators
For more information on JIRA, see: http://www.atlassian.com/software/jira