+
+ /**
+ * @throws Exception
+ * Testing of {@link SetAsyncInputMessageFactory} for correct translation from POJO
+ */
+ @Test
+ public void testSetAsyncInputWithNullMasks() throws Exception {
+ SetAsyncInputBuilder builder = new SetAsyncInputBuilder();
+ BufferHelper.setupHeader(builder, EncodeConstants.OF13_VERSION_ID);
+ builder.setPacketInMask(null);
+ builder.setPortStatusMask(null);
+ builder.setFlowRemovedMask(null);
+ SetAsyncInput message = builder.build();
+
+ ByteBuf out = UnpooledByteBufAllocator.DEFAULT.buffer();
+ setAsyncFactory.serialize(message, out);
+
+ BufferHelper.checkHeaderV13(out,(byte) 28, 8);
+ Assert.assertTrue("Unexpected data", out.readableBytes() == 0);
+ }
+}
\ No newline at end of file