Buggy code:
public class CheckboxTagTests extends AbstractFormTagTests { private CheckboxTag tag ; private TestBean bean ; protected void onSetUp ( ) { } public void testWithSingleValueBooleanObjectChecked ( ) throws Exception { } public void testWithIndexedBooleanObjectNotChecked ( ) throws Exception { this . tag . setPath ( "someMap[key]" ) ; int result = this . tag . doStartTag ( ) ; assertEquals ( SKIP_BODY , result ) ; String output = getOutput ( ) ; output = ( "<doc>" + output ) + "<//doc>" ; SAXReader reader = new SAXReader ( ) ; Document document = reader . read ( new StringReader ( output ) ) ; Element rootElement = document . getRootElement ( ) ; assertEquals ( "Both<seq2seq4repair_space>tag<seq2seq4repair_space>and<seq2seq4repair_space>hidden<seq2seq4repair_space>element<seq2seq4repair_space>not<seq2seq4repair_space>rendered" , 2 , rootElement . elements ( ) . size ( ) ) ; Element checkboxElement = ( ( Element ) ( rootElement . elements ( ) . get ( 0 ) ) ) ; assertEquals ( "input" , checkboxElement . getName ( ) ) ; assertEquals ( "checkbox" , checkboxElement . attribute ( "type" ) . getValue ( ) ) ; assertEquals ( "someMapkey1" , checkboxElement . attribute ( "id" ) . getValue ( ) ) ; <START_BUG> assertEquals ( "someMapkey" , checkboxElement . attribute ( "name" ) . getValue ( ) ) ; <END_BUG> assertEquals ( "checked" , checkboxElement . attribute ( "checked" ) . getValue ( ) ) ; assertEquals ( "true" , checkboxElement . attribute ( "value" ) . getValue ( ) ) ; } public void testWithSingleValueBooleanObjectCheckedAndDynamicAttributes ( ) throws Exception { } public void testWithSingleValueBooleanChecked ( ) throws Exception { } public void testWithSingleValueBooleanObjectUnchecked ( ) throws Exception { } public void testWithSingleValueBooleanUnchecked ( ) throws Exception { } public void testWithSingleValueNull ( ) throws Exception { } public void testWithSingleValueNotNull ( ) throws Exception { } public void testWithSingleValueAndEditor ( ) throws Exception { } public void testWithMultiValueChecked ( ) throws Exception { } public void testWithMultiValueUnchecked ( ) throws Exception { } public void testWithMultiValueWithEditor ( ) throws Exception { } public void testWithMultiValueIntegerWithEditor ( ) throws Exception { } public void testWithCollection ( ) throws Exception { } public void testWithObjectChecked ( ) throws Exception { } public void testWithObjectUnchecked ( ) throws Exception { } public void testCollectionOfColoursSelected ( ) throws Exception { } public void testCollectionOfColoursNotSelected ( ) throws Exception { } public void testCollectionOfPetsAsString ( ) throws Exception { } public void testCollectionOfPetsAsStringNotSelected ( ) throws Exception { } public void testCollectionOfPets ( ) throws Exception { } public void testCollectionOfPetsNotSelected ( ) throws Exception { } public void testCollectionOfPetsWithEditor ( ) throws Exception { } public void testWithNullValue ( ) throws Exception { } public void testHiddenElementOmittedOnDisabled ( ) throws Exception { } private Date getDate ( ) { } protected TestBean createTestBean ( ) { } private class MyStringTrimmerEditor extends StringTrimmerEditor { public int count = 0 ; public MyStringTrimmerEditor ( ) { } public void setAsText ( String text ) { } } private class MyIntegerEditor extends PropertyEditorSupport { public int count = 0 ; public void setAsText ( String text ) { } } }

Fix:
assertEquals ( "someMap[key]" , checkboxElement . attribute ( "name" ) . getValue ( ) ) ;