Skip to content

Commit

Permalink
[ISSUE#12022] Fix MapperManagerTest test (alibaba#12022)
Browse files Browse the repository at this point in the history
  • Loading branch information
mikolls committed May 6, 2024
1 parent d831bc9 commit acd4416
Show file tree
Hide file tree
Showing 2 changed files with 4 additions and 4 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -18,7 +18,7 @@

import com.alibaba.nacos.plugin.datasource.constants.DataSourceConstant;
import com.alibaba.nacos.plugin.datasource.mapper.AbstractMapper;
import com.alibaba.nacos.plugin.datasource.mapper.ConfigInfoMapper;
import com.alibaba.nacos.plugin.datasource.mapper.ConfigInfoAggrMapper;
import com.alibaba.nacos.plugin.datasource.mapper.Mapper;
import com.alibaba.nacos.plugin.datasource.mapper.TestMapper;
import org.junit.Assert;
Expand Down Expand Up @@ -76,7 +76,7 @@ public void testFindMapper() {
public void testEnableDataSourceLogJoin() {
MapperManager.join(new TestMapper());
MapperManager instance = MapperManager.instance(true);
ConfigInfoMapper mapper = instance.findMapper(DataSourceConstant.MYSQL, "test");
ConfigInfoAggrMapper mapper = instance.findMapper(DataSourceConstant.MYSQL, "test");
Assert.assertNotNull(mapper);
}

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -18,13 +18,13 @@

import com.alibaba.nacos.plugin.datasource.constants.DataSourceConstant;
import com.alibaba.nacos.plugin.datasource.impl.TestInterface;
import com.alibaba.nacos.plugin.datasource.impl.base.BaseConfigInfoMapper;
import com.alibaba.nacos.plugin.datasource.impl.mysql.ConfigInfoAggrMapperByMySql;

/**
* Implement interfaces other than Mapper. just for test
* @author mikolls
**/
public class TestMapper extends BaseConfigInfoMapper implements TestInterface {
public class TestMapper extends ConfigInfoAggrMapperByMySql implements TestInterface {

@Override
public String getTableName() {
Expand Down

0 comments on commit acd4416

Please sign in to comment.