JooKS-me commented on a change in pull request #10355:
URL: https://github.com/apache/shardingsphere/pull/10355#discussion_r633280527
##########
File path:
shardingsphere-governance/shardingsphere-governance-core/src/test/java/org/apache/shardingsphere/governance/core/facade/GovernanceFacadeTest.java
##########
@@ -47,7 +48,9 @@ public void assertInit() {
GovernanceConfiguration config = new
GovernanceConfiguration("test_name", new RegistryCenterConfiguration("TEST",
"127.0.0.1", new Properties()), false);
governanceFacade.init(config, Arrays.asList("schema_0", "schema_1"));
assertNotNull(governanceFacade.getRegistryCenter());
- // TODO use reflection to assert attributes of GovernanceFacade
+ assertFalse((Boolean) getField(governanceFacade, "isOverwrite"));
+ assertNotNull(getField(governanceFacade, "registryCenterRepository"));
Review comment:
@SteNicholas Hi, do you mean to check the attribute values of
`registryCenterRepository` one by one? I have some confusion because I think it
has no attribute values.
In this test code, `governanceFacade.init(config, Arrays.asList("schema_0",
"schema_1"));` will generate a `RegistryCenterRepositoryFixture` class instance
through the SPI mechanism, but we know that `RegistryCenterRepositoryFixture`
does not have any Attributes, except for the `PATH_SEPARATOR` defined in the
interface `RegistryCenterRepository`.
However, I can check the attributes of `listenerManager` one by one.
Is it right ?
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
For queries about this service, please contact Infrastructure at:
[email protected]