Skip to content

Commit

Permalink
Merge branch 'kl-cache' of github.com:klboke/apollo into kl-cache
Browse files Browse the repository at this point in the history
# Conflicts:
#	apollo-configservice/src/main/java/com/ctrip/framework/apollo/configservice/service/config/ConfigServiceWithCache.java
#	apollo-configservice/src/test/java/com/ctrip/framework/apollo/configservice/service/config/ConfigServiceWithCacheTest.java
  • Loading branch information
klboke committed Apr 4, 2023
2 parents 63fee52 + dfd3fce commit c274197
Showing 1 changed file with 5 additions and 5 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -27,6 +27,7 @@
import com.ctrip.framework.apollo.biz.config.BizConfig;
import com.ctrip.framework.apollo.biz.entity.Release;
import com.ctrip.framework.apollo.biz.entity.ReleaseMessage;
import com.ctrip.framework.apollo.biz.grayReleaseRule.GrayReleaseRulesHolder;
import com.ctrip.framework.apollo.biz.message.Topics;
import com.ctrip.framework.apollo.biz.service.ReleaseMessageService;
import com.ctrip.framework.apollo.biz.service.ReleaseService;
Expand Down Expand Up @@ -60,6 +61,8 @@ public class ConfigServiceWithCacheAndCacheKeyIgnoreCaseTest {
private ReleaseMessage someReleaseMessage;
@Mock
private BizConfig bizConfig;
@Mock
private GrayReleaseRulesHolder grayReleaseRulesHolder;

private String someAppId;
private String someClusterName;
Expand All @@ -71,11 +74,8 @@ public class ConfigServiceWithCacheAndCacheKeyIgnoreCaseTest {

@Before
public void setUp() throws Exception {
configServiceWithCache = new ConfigServiceWithCache();
ReflectionTestUtils.setField(configServiceWithCache, "releaseService", releaseService);
ReflectionTestUtils.setField(configServiceWithCache, "releaseMessageService",
releaseMessageService);
ReflectionTestUtils.setField(configServiceWithCache, "bizConfig", bizConfig);
configServiceWithCache = new ConfigServiceWithCache(releaseService, releaseMessageService,
grayReleaseRulesHolder, bizConfig);

when(bizConfig.isConfigServiceCacheKeyIgnoreCase()).thenReturn(true);

Expand Down

0 comments on commit c274197

Please sign in to comment.