@Test
  public void test_ValidateSerialGatewaySenderQueueAttributes_2() {
    Integer localLocPort = vm0.invoke(() -> WANTestBase.createFirstLocatorWithDSId(1));

    vm1.invoke(() -> WANTestBase.createFirstRemoteLocator(2, localLocPort));

    WANTestBase test = new WANTestBase();
    Properties props = test.getDistributedSystemProperties();
    props.setProperty(MCAST_PORT, "0");
    props.setProperty(LOCATORS, "localhost[" + localLocPort + "]");
    InternalDistributedSystem ds = test.getSystem(props);
    cache = CacheFactory.create(ds);

    GatewaySenderFactory fact = cache.createGatewaySenderFactory();
    fact.setBatchConflationEnabled(true);
    fact.setBatchSize(200);
    fact.setBatchTimeInterval(300);
    fact.setPersistenceEnabled(false);// set persistence to false
    fact.setDiskSynchronous(true);
    fact.setMaximumQueueMemory(200);
    fact.setAlertThreshold(1200);
    GatewayEventFilter myEventFilter1 = new MyGatewayEventFilter1();
    fact.addGatewayEventFilter(myEventFilter1);
    GatewayTransportFilter myStreamFilter1 = new MyGatewayTransportFilter1();
    fact.addGatewayTransportFilter(myStreamFilter1);
    GatewayTransportFilter myStreamFilter2 = new MyGatewayTransportFilter2();
    fact.addGatewayTransportFilter(myStreamFilter2);
    final IgnoredException exp = IgnoredException.addIgnoredException("Could not connect");
    try {
      GatewaySender sender1 = fact.create("TKSender", 2);
      RegionFactory<?, ?> regionFactory = cache.createRegionFactory(RegionShortcut.PARTITION);
      regionFactory.addGatewaySenderId(sender1.getId());
      regionFactory.create("test_ValidateGatewaySenderAttributes");
      Set<GatewaySender> senders = cache.getGatewaySenders();
      assertThat(1).isEqualTo(senders.size());
      GatewaySender gatewaySender = senders.iterator().next();
      Set<RegionQueue> regionQueues = ((AbstractGatewaySender) gatewaySender).getQueues();
      assertThat(GatewaySender.DEFAULT_DISPATCHER_THREADS).isEqualTo(regionQueues.size());
      RegionQueue regionQueue = regionQueues.iterator().next();

      assertThat(regionQueue.getRegion().getAttributes().isDiskSynchronous()).isEqualTo(false);
    } finally {
      exp.remove();
    }
  }
Test to validate that serial gateway sender queue diskSynchronous attribute when persistence of
sender is not enabled.
geode-wan/src/distributedTest/java/org/apache/geode/internal/cache/wan/serial/SerialGatewaySenderQueueDistributedTest.java