From 4799e65bf42664e0ec6294799c389f2d7c623a33 Mon Sep 17 00:00:00 2001
From: Andrew Bauer <andy.bauer@kitware.com>
Date: Thu, 14 Apr 2016 15:46:58 -0400
Subject: [PATCH] Fix for
 vtkIOParallelXMLPython-MPI-testParallelMultiBlockWriter test.

It seems like a barrier is needed between when the test files
are deleted and when they're created after that such that the
new files are created after the old files are deleted.
---
 .../Testing/Python/testParallelMultiBlockWriter.py          | 6 +++++-
 1 file changed, 5 insertions(+), 1 deletion(-)

diff --git a/IO/ParallelXML/Testing/Python/testParallelMultiBlockWriter.py b/IO/ParallelXML/Testing/Python/testParallelMultiBlockWriter.py
index 9974a63f3fd..01d9a0f9819 100644
--- a/IO/ParallelXML/Testing/Python/testParallelMultiBlockWriter.py
+++ b/IO/ParallelXML/Testing/Python/testParallelMultiBlockWriter.py
@@ -15,7 +15,6 @@ else:
     nranks = contr.GetNumberOfProcesses()
     rank = contr.GetLocalProcessId()
 
-
 # Let's create a simple multiblock with non-empty blocks as indicated below.
 # <MB> is a multiblock dataset.
 # [<num>] is a leaf node where the number indicates the ranks on which it is
@@ -85,6 +84,11 @@ if rank == 0:
     except OSError: pass
     print("Output: %s" % fname)
 
+# put a barrier here to make sure that the files are deleted by process 0
+# before going further with the test
+if contr:
+    contr.Barrier()
+
 writer.SetFileName(fname)
 writer.SetInputDataObject(createMB(rank, nranks))
 writer.Write()
-- 
GitLab