]> SALOME platform Git repositories - modules/paravis.git/commitdiff
Salome HOME
Use real temporary file name for unit tests trace
authorCédric Aguerre <cedric.aguerre@edf.fr>
Wed, 10 Aug 2016 09:13:59 +0000 (11:13 +0200)
committerCédric Aguerre <cedric.aguerre@edf.fr>
Wed, 10 Aug 2016 09:13:59 +0000 (11:13 +0200)
test/VisuPrs/bugs/A5.py
test/VisuPrs/bugs/C5.py

index d5af545e25554573be684a66c391134a831a6a90..357194dc985775b4b1b078b59369733bb8704fd8 100644 (file)
@@ -34,9 +34,10 @@ data_file = datadir + "TimeStamps.med"
 
 tmp_dir = os.getenv("TmpDir")
 if tmp_dir == None:
-    tmp_dir = "/tmp"
+  import tempfile
+  tmp_dir = tempfile.mkdtemp()
 
-save_file = tmp_dir + "/TimeStamps_save.hdf"
+save_file = os.path.join(tmp_dir, "TimeStamps_save.hdf")
 print "Save to file ", save_file
 
 pvsimple.OpenDataFile(data_file)
index d1e47240dcbe7406217ed391eb89a815b76ca124..f48af7b65b6f60f05d83399628a1542b0a75a886 100644 (file)
@@ -144,7 +144,8 @@ theDuration = 20
 NbOfLoops = 4
 #thePath = os.getenv("TMP_DIR")
 thePrefix = "TestPngFromAnim"
-thePath = os.path.join("/tmp", thePrefix)
+import tempfile
+thePath = os.path.join(tempfile.mkdtemp(), thePrefix)
 thePath += ".png"
 
 displayMng = DisplayManager()