private void createPartitionedRegion(final String regionName) {
    cacheRule.createCache();

    PartitionAttributesFactory paf = new PartitionAttributesFactory();
    paf.setLocalMaxMemory(10);
    paf.setRedundantCopies(0);

    RegionFactory regionFactory =
        cacheRule.getCache().createRegionFactory(RegionShortcut.PARTITION);
    regionFactory.setPartitionAttributes(paf.create());

    regionFactory.create(regionName);
  }
TRAC #41779: InternalExecution.setWaitOnExceptionFlag(true) does not add the exception from the
local node to the FunctionException list of exceptions

<p>
Extracted from {@link PRFunctionExecutionDUnitTest}.
geode-core/src/distributedTest/java/org/apache/geode/internal/cache/execute/FunctionExceptionsIncludeLocalMemberRegressionTest.java