[Bf-blender-cvs] [910f16576d] render-layers: Unittest: refresh blender between tests

Dalai Felinto noreply at git.blender.org
Tue Jan 31 10:46:17 CET 2017


Commit: 910f16576d71f9a3fc9db4c66b573bfa84baf8b9
Author: Dalai Felinto
Date:   Tue Jan 31 10:14:46 2017 +0100
Branches: render-layers
https://developer.blender.org/rB910f16576d71f9a3fc9db4c66b573bfa84baf8b9

Unittest: refresh blender between tests

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

M	tests/python/bl_render_layer.py

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

diff --git a/tests/python/bl_render_layer.py b/tests/python/bl_render_layer.py
index 93318d6eb3..e0b1711c9d 100644
--- a/tests/python/bl_render_layer.py
+++ b/tests/python/bl_render_layer.py
@@ -198,9 +198,16 @@ class UnitsTesting(unittest.TestCase):
 
     @classmethod
     def setUpClass(cls):
+        """Runs once"""
         cls.pretest_import_blendfile()
         cls.pretest_parsing()
 
+    @classmethod
+    def setUp(cls):
+        """Runs once per test"""
+        import bpy
+        bpy.ops.wm.read_factory_settings()
+
     def path_exists(self, filepath):
         import os
         self.assertTrue(




More information about the Bf-blender-cvs mailing list