@Test
public void verifyGetAttributeOptionCombo()
{

    // prepare data
    CategoryCombo cc = createCategoryCombo( 'B' );
    CategoryOption categoryOption = createCategoryOption( 'A' );
    categoryOption.setId( 100L );
    when( jdbcTemplate.queryForObject(
        eq( "select categoryoptionid, uid, code, name from dataelementcategoryoption where uid = 'abcdef'" ),
        any( RowMapper.class ) ) ).thenReturn( categoryOption );
    when( jdbcTemplate.query( anyString(), any( RowMapper.class ) ) )
        .thenReturn( singletonList( createCategoryOptionCombo( cc, categoryOption ) ) );
    // method under test
    CategoryOptionCombo categoryOptionCombo = subject.getAttributeOptionCombo( cc, "abcdef", "", IdScheme.UID );
    // assertions
    assertThat( categoryOptionCombo, is( notNullValue() ) );
    verify( jdbcTemplate ).query( sqlCaptor.capture(), any( RowMapper.class ) );
    final String sql = sqlCaptor.getValue();
    assertThat( sql, is( replace( SQL_GET_CATEGORYOPTIONCOMBO_BY_CATEGORYIDS, "resolvedScheme",
        "uid = '" + cc.getUid() + "'", "option_ids", "'100'" ) ) );
}