Fix (unreported) missing updates in scripts/docs after scene.update() removal.

This should really have been done together with API changes, simple
usage of grep does the trick to catch most places needing updates.
This commit is contained in:
2019-06-04 14:36:53 +02:00
parent 1d2e4c44bd
commit 33e8db94b1
25 changed files with 41 additions and 40 deletions

View File

@@ -25,7 +25,7 @@ class UnitTesting(ViewLayerTesting):
bpy.context.window.scene = main_scene
# Update depsgraph.
main_scene.update()
bpy.context.view_layer.update()
# Safety check, there should be no objects in thew newly created scene.
self.assertEqual(0, len(bpy.context.depsgraph.objects))
@@ -35,7 +35,7 @@ class UnitTesting(ViewLayerTesting):
background_scene.objects[0].parent = background_scene.objects[1]
# Update depsgraph.
main_scene.update()
bpy.context.view_layer.update()
# Test if objects were properly added to depsgraph.
self.assertEqual(3, len(bpy.context.depsgraph.objects))
@@ -50,7 +50,7 @@ class UnitTesting(ViewLayerTesting):
main_scene.background_set = None
# Update depsgraph.
main_scene.update()
bpy.context.view_layer.update()
self.assertEqual(0, len(bpy.context.depsgraph.objects))