protected void checkClientValue(final Region<Object, Object> region) {
    // Because register interest is asynchronous, we need to wait for the value to arrive.
    GeodeAwaitility.await().untilAsserted(new WaitCriterion() {

      @Override
      public boolean done() {
        return region.get("A") != null;
      }

      @Override
      public String description() {
        return "Client region never received value for key A";
      }
    });
    assertEquals(TestSerializable.class, region.get("A").getClass());

    // do a register interest which will download the value
    region.registerInterest("B", KEYS_VALUES);
    assertEquals(TestSerializable.class, region.get("B").getClass());
  }
This test creates the following topology

vm0 a peer accessor for both a PR and a replicate region vm1 a peer data store for a replicate
region and a PR vm2 a client of vm0 vm3 a client vm1

The test then performs all region operations in operationVM, while deserialization is prevented
in disallowDeserializationVM.

If an operation causes a deserialization in the disallow VM, this test will fail.
geode-core/src/distributedTest/java/org/apache/geode/pdx/PdxDeserializationDUnitTest.java