[Bf-blender-cvs] [977e7b68cb6] master: Cycles: add denoising tests, keep new image even if no reference exists.

Brecht Van Lommel noreply at git.blender.org
Fri Aug 11 01:11:22 CEST 2017


Commit: 977e7b68cb6e27d23d97485adad1eeb7ae5fe226
Author: Brecht Van Lommel
Date:   Fri Aug 11 00:38:39 2017 +0200
Branches: master
https://developer.blender.org/rB977e7b68cb6e27d23d97485adad1eeb7ae5fe226

Cycles: add denoising tests, keep new image even if no reference exists.

===================================================================

M	tests/python/CMakeLists.txt
M	tests/python/cycles_render_tests.py

===================================================================

diff --git a/tests/python/CMakeLists.txt b/tests/python/CMakeLists.txt
index ca752993c79..5335987d19d 100644
--- a/tests/python/CMakeLists.txt
+++ b/tests/python/CMakeLists.txt
@@ -534,6 +534,7 @@ if(WITH_CYCLES)
 		if(WITH_OPENGL_TESTS)
 			add_cycles_render_test(opengl)
 		endif()
+		add_cycles_render_test(denoise)
 		add_cycles_render_test(displacement)
 		add_cycles_render_test(image_data_types)
 		add_cycles_render_test(image_mapping)
diff --git a/tests/python/cycles_render_tests.py b/tests/python/cycles_render_tests.py
index ea84f27ab7e..ffd8627dbf2 100755
--- a/tests/python/cycles_render_tests.py
+++ b/tests/python/cycles_render_tests.py
@@ -222,6 +222,14 @@ class Report:
 
 def verify_output(report, filepath):
     ref_img, new_img, diff_img = test_get_images(filepath)
+
+    # copy new image
+    if os.path.exists(new_img):
+        os.remove(new_img)
+    if os.path.exists(TEMP_FILE):
+        shutil.copy(TEMP_FILE, new_img)
+
+
     if not os.path.exists(ref_img):
         return False
 
@@ -256,12 +264,6 @@ def verify_output(report, filepath):
         if VERBOSE:
             print_message(e.output.decode("utf-8"))
 
-    # copy new image
-    if os.path.exists(new_img):
-        os.remove(new_img)
-    if os.path.exists(TEMP_FILE):
-        shutil.copy(TEMP_FILE, new_img)
-
     return not failed




More information about the Bf-blender-cvs mailing list