This is an automated email from the ASF dual-hosted git repository. zhangliang pushed a commit to branch master in repository https://gitbox.apache.org/repos/asf/shardingsphere.git
The following commit(s) were added to refs/heads/master by this push: new b808d5b804d Refactor ReadwriteSplittingExportableRuleAttributeTest (#33584) b808d5b804d is described below commit b808d5b804d5e67b27df50d6f9abc3e7d43d7b17 Author: Liang Zhang <zhangli...@apache.org> AuthorDate: Thu Nov 7 14:53:49 2024 +0800 Refactor ReadwriteSplittingExportableRuleAttributeTest (#33584) --- .../rule/attribute/ReadwriteSplittingExportableRuleAttributeTest.java | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/features/readwrite-splitting/core/src/test/java/org/apache/shardingsphere/readwritesplitting/rule/attribute/ReadwriteSplittingExportableRuleAttributeTest.java b/features/readwrite-splitting/core/src/test/java/org/apache/shardingsphere/readwritesplitting/rule/attribute/ReadwriteSplittingExportableRuleAttributeTest.java index b57875bfe63..bc0c7b75c54 100644 --- a/features/readwrite-splitting/core/src/test/java/org/apache/shardingsphere/readwritesplitting/rule/attribute/ReadwriteSplittingExportableRuleAttributeTest.java +++ b/features/readwrite-splitting/core/src/test/java/org/apache/shardingsphere/readwritesplitting/rule/attribute/ReadwriteSplittingExportableRuleAttributeTest.java @@ -36,9 +36,9 @@ class ReadwriteSplittingExportableRuleAttributeTest { @Test void assertGetExportData() { - ReadwriteSplittingDataSourceGroupRuleConfiguration config = new ReadwriteSplittingDataSourceGroupRuleConfiguration("foo_group", "write_ds", Arrays.asList("read_ds0", "read_ds1"), "foo_algo"); - Map<String, ReadwriteSplittingDataSourceGroupRule> dataSourceGroupRules = new HashMap<>(2, 1F); + Map<String, ReadwriteSplittingDataSourceGroupRule> dataSourceGroupRules = new HashMap<>(); dataSourceGroupRules.put("ignored_group", mock(ReadwriteSplittingDataSourceGroupRule.class)); + ReadwriteSplittingDataSourceGroupRuleConfiguration config = new ReadwriteSplittingDataSourceGroupRuleConfiguration("foo_group", "write_ds", Arrays.asList("read_ds0", "read_ds1"), "foo_algo"); dataSourceGroupRules.put("foo_group", new ReadwriteSplittingDataSourceGroupRule(config, TransactionalReadQueryStrategy.FIXED, null)); ReadwriteSplittingExportableRuleAttribute ruleAttribute = new ReadwriteSplittingExportableRuleAttribute(dataSourceGroupRules); Map<String, Object> actual = ruleAttribute.getExportData();