@Test
    @SuppressWarnings("deprecation")
    public void queryForPaginagedListShouldBeTraced() throws Exception {
        // Given
        final String queryForPaginatedListId = "queryForPaginatedListId";
        // to emulate lazy-loading, otherwise exception is thrown
        TransactionManager mockTxManager = mock(TransactionManager.class);
        when(this.mockSqlMapExecutorDelegate.getTxManager()).thenReturn(mockTxManager);
        SqlMapClientTemplate clientTemplate = new SqlMapClientTemplate(this.mockDataSource, this.sqlMapClient);
        // When
        clientTemplate.queryForPaginatedList(queryForPaginatedListId, 1);
        clientTemplate.queryForPaginatedList(queryForPaginatedListId, new Object(), 1);
        // Then
        PluginTestVerifier verifier = PluginTestVerifierHolder.getInstance();
        Method queryForPaginatedList1 = SqlMapClientTemplate.class.getDeclaredMethod("queryForPaginatedList",
                String.class, int.class);
        Method queryForPaginatedList2 = SqlMapClientTemplate.class.getDeclaredMethod("queryForPaginatedList",
                String.class, Object.class, int.class);
        verifier.verifyTrace(event("IBATIS_SPRING", queryForPaginatedList1,
                Expectations.cachedArgs(queryForPaginatedListId)));
        verifier.verifyTrace(event("IBATIS_SPRING", queryForPaginatedList2,
                Expectations.cachedArgs(queryForPaginatedListId)));
    }
Tests against spring-ibatis 2.0.7+. Prior versions require com.ibatis:ibatis2 dependency, which is not available in the repository.

@author HyunGil Jeong
agent-module/plugins-it/ibatis-it/src/test/java/com/navercorp/pinpoint/it/plugin/ibatis/SqlMapClientTemplateIT.java