[cycles/ctest] fix failing tests when output folder doesn't exist yet.
authorRay Molenkamp <github@lazydodo.com>
Fri, 25 Aug 2017 23:17:49 +0000 (17:17 -0600)
committerRay Molenkamp <github@lazydodo.com>
Fri, 25 Aug 2017 23:17:49 +0000 (17:17 -0600)
tests/python/cycles_render_tests.py

index d4e796f35ae6afb2fb636f993d0e79ba66e65936..ba4c04f7cf306db9b33b8aade6276d9b15f4368f 100755 (executable)
@@ -154,6 +154,9 @@ class Report:
     def output(self):
         # write intermediate data for single test
         outdir = os.path.join(OUTDIR, self.testname)
+        if not os.path.exists(outdir):
+            os.makedirs(outdir)
+
         f = open(os.path.join(outdir, "failed.data"), "w")
         f.write(self.failed_tests)
         f.close()