Geometry Nodes: enable closure regression tests

Some special care had to be taken because these tests require an experimental
feature to be turned on to work.

Pull Request: https://projects.blender.org/blender/blender/pulls/137414
This commit is contained in:
Jacques Lucke
2025-04-13 13:55:23 +02:00
parent 223412b6d5
commit c11055c1cf
3 changed files with 10 additions and 1 deletions

View File

@@ -1021,6 +1021,7 @@ endif()
if(TEST_SRC_DIR_EXISTS)
set(geo_node_tests
attributes
closure
curve_primitives
curves
curves/interpolate_curves

View File

@@ -5,10 +5,18 @@
import os
import sys
import bpy
sys.path.append(os.path.dirname(os.path.realpath(__file__)))
from modules.mesh_test import BlendFileTest
if "closure" in bpy.data.filepath:
if bpy.app.version_cycle == "alpha":
bpy.context.preferences.experimental.use_bundle_and_closure_nodes = True
else:
print("Skipped because bundles and closures are still experimental.")
sys.exit(0)
geo_node_test = BlendFileTest("test_object", "expected_object", threshold=1e-4)
result = geo_node_test.run_test()