public void testDeleteWithRequiredRowsAffectedAndInvalidRowCount() throws SQLException {
   TestSqlMapClientTemplate template = new TestSqlMapClientTemplate();
   template.executor.delete("myStatement", "myParameter");
   template.executorControl.setReturnValue(20, 1);
   template.executorControl.replay();
   try {
     template.delete("myStatement", "myParameter", 10);
     fail("Should have thrown JdbcUpdateAffectedIncorrectNumberOfRowsException");
   } catch (JdbcUpdateAffectedIncorrectNumberOfRowsException ex) {
     // expected
     assertEquals(10, ex.getExpectedRowsAffected());
     assertEquals(20, ex.getActualRowsAffected());
   }
   template.executorControl.verify();
 }