yihua commented on code in PR #11121:
URL: https://github.com/apache/hudi/pull/11121#discussion_r1588552025
##########
hudi-io/src/test/java/org/apache/hudi/io/storage/BaseTestStorageConfiguration.java:
##########
@@ -71,13 +72,25 @@ public abstract class BaseTestStorageConfiguration<T> {
@Test
public void testConstructorNewInstanceUnwrapCopy() {
- T conf = getConf(EMPTY_MAP);
+ T conf = getConf(prepareConfigs());
StorageConfiguration<T> storageConf = getStorageConfiguration(conf);
StorageConfiguration<T> newStorageConf = storageConf.newInstance();
+ Class unwrapperConfClass = storageConf.unwrap().getClass();
assertNotSame(storageConf, newStorageConf);
+ validateConfigs(newStorageConf);
assertNotSame(storageConf.unwrap(), newStorageConf.unwrap());
assertSame(storageConf.unwrap(), storageConf.unwrap());
+ assertSame(storageConf.unwrap(), storageConf.unwrapAs(unwrapperConfClass));
assertNotSame(storageConf.unwrap(), storageConf.unwrapCopy());
+ validateConfigs(getStorageConfiguration(storageConf.unwrapCopy()));
+ assertNotSame(storageConf.unwrap(),
storageConf.unwrapCopyAs(unwrapperConfClass));
+ validateConfigs(getStorageConfiguration((T)
storageConf.unwrapCopyAs(unwrapperConfClass)));
Review Comment:
Addressed.
--
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.
To unsubscribe, e-mail: [email protected]
For queries about this service, please contact Infrastructure at:
[email protected]