sashapolo commented on a change in pull request #153:
URL: https://github.com/apache/ignite-3/pull/153#discussion_r643858655
##########
File path:
modules/network/src/test/java/org/apache/ignite/network/MessageSerializationRegistryImplTest.java
##########
@@ -45,11 +47,34 @@ public void testRegisterFactory() {
*/
@Test
public void testRegisterFactoryWithSameType() {
- var registry = new MessageSerializationRegistry();
+ var registry = new MessageSerializationRegistryImpl();
- registry.registerFactory(Msg.TYPE, new MsgSerializationFactory());
+ registry.registerFactory(Msg.GROUP_TYPE, Msg.TYPE, new
MsgSerializationFactory());
- assertThrows(NetworkConfigurationException.class, () ->
registry.registerFactory(Msg.TYPE, new MsgSerializationFactory()));
+ assertThrows(
+ NetworkConfigurationException.class,
+ () -> registry.registerFactory(Msg.GROUP_TYPE, Msg.TYPE, new
MsgSerializationFactory())
+ );
+ }
+
+ /**
+ * Tests that it is possible to register serialization factories for the
same message types but for different
+ * modules.
+ */
+ @Test
+ public void testRegisterFactoryWithSameTypeDifferentModule() {
Review comment:
Nice catch again, the assertion is indeed useless (what a shame)
--
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]