diff options
author | Brecht Van Lommel <brechtvanlommel@pandora.be> | 2011-03-13 16:09:18 +0300 |
---|---|---|
committer | Brecht Van Lommel <brechtvanlommel@pandora.be> | 2011-03-13 16:09:18 +0300 |
commit | 5f7126c96f7a7abbcb70c6f8df3af9d6a1b347c6 (patch) | |
tree | 3e0a9f6c0587689115f7e49edc57c70c7a193fad /source | |
parent | 128bed8480ca65c79ecdb2cf279383e9d0f65a2c (diff) |
Fix "make test" on Mac, couldn't find executable.
Diffstat (limited to 'source')
-rw-r--r-- | source/tests/CMakeLists.txt | 61 |
1 files changed, 33 insertions, 28 deletions
diff --git a/source/tests/CMakeLists.txt b/source/tests/CMakeLists.txt index 27b4ea7a6bd..00278697764 100644 --- a/source/tests/CMakeLists.txt +++ b/source/tests/CMakeLists.txt @@ -33,31 +33,36 @@ set(TEST_OUT_DIR ${CMAKE_BINARY_DIR}/tests) #~ endif() # all calls to blender use this -set(GENERIC_ARGS --background --factory-startup --env-system-scripts ${CMAKE_SOURCE_DIR}/release/scripts) +if(APPLE) + set(TEST_BLENDER_EXE ${EXECUTABLE_OUTPUT_PATH}/blender.app/Contents/MacOS/blender) +else() + set(TEST_BLENDER_EXE ${EXECUTABLE_OUTPUT_PATH}/blender) +endif() +set(TEST_BLENDER_EXE ${TEST_BLENDER_EXE} --background --factory-startup --env-system-scripts ${CMAKE_SOURCE_DIR}/release/scripts) # OBJ Import tests -add_test(import_obj_cube ${EXECUTABLE_OUTPUT_PATH}/blender ${GENERIC_ARGS} +add_test(import_obj_cube ${TEST_BLENDER_EXE} --python ${CMAKE_CURRENT_LIST_DIR}/bl_test.py -- --run={'FINISHED'}&bpy.ops.import_scene.obj\(filepath='${TEST_SRC_DIR}/io_tests/obj/cube.obj'\) --md5=4d090508b812b5e08168aa2614746bda --md5_method=SCENE ) -add_test(import_obj_nurbs_cyclic ${EXECUTABLE_OUTPUT_PATH}/blender ${GENERIC_ARGS} +add_test(import_obj_nurbs_cyclic ${TEST_BLENDER_EXE} --python ${CMAKE_CURRENT_LIST_DIR}/bl_test.py -- --run={'FINISHED'}&bpy.ops.import_scene.obj\(filepath='${TEST_SRC_DIR}/io_tests/obj/nurbs_cyclic.obj'\) --md5=9e0da7b65b4c4f818a203d56af2d3a4b --md5_method=SCENE --write-blend=/root/foo99.blend ) -add_test(import_obj_makehuman ${EXECUTABLE_OUTPUT_PATH}/blender ${GENERIC_ARGS} +add_test(import_obj_makehuman ${TEST_BLENDER_EXE} --python ${CMAKE_CURRENT_LIST_DIR}/bl_test.py -- --run={'FINISHED'}&bpy.ops.import_scene.obj\(filepath='${TEST_SRC_DIR}/io_tests/obj/makehuman.obj'\) --md5=e0829dc078b0789e1d81f1071235bc4f --md5_method=SCENE ) # OBJ Export tests -add_test(export_obj_cube ${EXECUTABLE_OUTPUT_PATH}/blender ${GENERIC_ARGS} +add_test(export_obj_cube ${TEST_BLENDER_EXE} ${TEST_SRC_DIR}/io_tests/blend_geometry/all_quads.blend --python ${CMAKE_CURRENT_LIST_DIR}/bl_test.py -- --run={'FINISHED'}&bpy.ops.export_scene.obj\(filepath='${TEST_OUT_DIR}/export_obj_cube.obj',use_selection=False\) @@ -66,7 +71,7 @@ add_test(export_obj_cube ${EXECUTABLE_OUTPUT_PATH}/blender ${GENERIC_ARGS} --md5=70bdc394c2726203ad26c085176e3484 --md5_method=FILE ) -add_test(export_obj_nurbs ${EXECUTABLE_OUTPUT_PATH}/blender ${GENERIC_ARGS} +add_test(export_obj_nurbs ${TEST_BLENDER_EXE} ${TEST_SRC_DIR}/io_tests/blend_geometry/nurbs.blend --python ${CMAKE_CURRENT_LIST_DIR}/bl_test.py -- --run={'FINISHED'}&bpy.ops.export_scene.obj\(filepath='${TEST_OUT_DIR}/export_obj_nurbs.obj',use_selection=False,use_nurbs=True\) @@ -75,7 +80,7 @@ add_test(export_obj_nurbs ${EXECUTABLE_OUTPUT_PATH}/blender ${GENERIC_ARGS} --md5=a733ae4fa4a591ea9b0912da3af042de --md5_method=FILE ) -add_test(export_obj_all_objects ${EXECUTABLE_OUTPUT_PATH}/blender ${GENERIC_ARGS} +add_test(export_obj_all_objects ${TEST_BLENDER_EXE} ${TEST_SRC_DIR}/io_tests/blend_scene/all_objects.blend --python ${CMAKE_CURRENT_LIST_DIR}/bl_test.py -- --run={'FINISHED'}&bpy.ops.export_scene.obj\(filepath='${TEST_OUT_DIR}/export_obj_all_objects.obj',use_selection=False,use_nurbs=True\) @@ -87,19 +92,19 @@ add_test(export_obj_all_objects ${EXECUTABLE_OUTPUT_PATH}/blender ${GENERIC_ARGS # PLY Import tests -add_test(import_ply_cube ${EXECUTABLE_OUTPUT_PATH}/blender ${GENERIC_ARGS} +add_test(import_ply_cube ${TEST_BLENDER_EXE} --python ${CMAKE_CURRENT_LIST_DIR}/bl_test.py -- --run={'FINISHED'}&bpy.ops.import_mesh.ply\(filepath='${TEST_SRC_DIR}/io_tests/ply/cube_ascii.ply'\) --md5=527134343c27fc0ea73115b85fbfd3ac --md5_method=SCENE ) -add_test(import_ply_bunny ${EXECUTABLE_OUTPUT_PATH}/blender ${GENERIC_ARGS} +add_test(import_ply_bunny ${TEST_BLENDER_EXE} --python ${CMAKE_CURRENT_LIST_DIR}/bl_test.py -- --run={'FINISHED'}&bpy.ops.import_mesh.ply\(filepath='${TEST_SRC_DIR}/io_tests/ply/bunny2.ply'\) --md5=6ea5b8533400a17accf928b8fd024eaa --md5_method=SCENE ) -add_test(import_ply_small_holes ${EXECUTABLE_OUTPUT_PATH}/blender ${GENERIC_ARGS} +add_test(import_ply_small_holes ${TEST_BLENDER_EXE} --python ${CMAKE_CURRENT_LIST_DIR}/bl_test.py -- --run={'FINISHED'}&bpy.ops.import_mesh.ply\(filepath='${TEST_SRC_DIR}/io_tests/ply/many_small_holes.ply'\) --md5=c3093e26ecae5b6d59fbbcf2a0d0b39f --md5_method=SCENE @@ -110,19 +115,19 @@ add_test(import_ply_small_holes ${EXECUTABLE_OUTPUT_PATH}/blender ${GENERIC_ARGS # STL Import tests -add_test(import_stl_cube ${EXECUTABLE_OUTPUT_PATH}/blender ${GENERIC_ARGS} +add_test(import_stl_cube ${TEST_BLENDER_EXE} --python ${CMAKE_CURRENT_LIST_DIR}/bl_test.py -- --run={'FINISHED'}&bpy.ops.import_mesh.stl\(filepath='${TEST_SRC_DIR}/io_tests/stl/cube.stl'\) --md5=8ceb5bb7e1cb5f4342fa1669988c66b4 --md5_method=SCENE ) -add_test(import_stl_conrod ${EXECUTABLE_OUTPUT_PATH}/blender ${GENERIC_ARGS} +add_test(import_stl_conrod ${TEST_BLENDER_EXE} --python ${CMAKE_CURRENT_LIST_DIR}/bl_test.py -- --run={'FINISHED'}&bpy.ops.import_mesh.stl\(filepath='${TEST_SRC_DIR}/io_tests/stl/conrod.stl'\) --md5=690a4b8eb9002dcd8631c5a575ea7348 --md5_method=SCENE ) -add_test(import_stl_knot_max_simplified ${EXECUTABLE_OUTPUT_PATH}/blender ${GENERIC_ARGS} +add_test(import_stl_knot_max_simplified ${TEST_BLENDER_EXE} --python ${CMAKE_CURRENT_LIST_DIR}/bl_test.py -- --run={'FINISHED'}&bpy.ops.import_mesh.stl\(filepath='${TEST_SRC_DIR}/io_tests/stl/knot_max_simplified.stl'\) --md5=baf82803f45a84ec4ddbad9cef57dd3e --md5_method=SCENE @@ -133,27 +138,27 @@ add_test(import_stl_knot_max_simplified ${EXECUTABLE_OUTPUT_PATH}/blender ${GENE # X3D Import -add_test(import_x3d_cube ${EXECUTABLE_OUTPUT_PATH}/blender ${GENERIC_ARGS} +add_test(import_x3d_cube ${TEST_BLENDER_EXE} --python ${CMAKE_CURRENT_LIST_DIR}/bl_test.py -- --run={'FINISHED'}&bpy.ops.import_scene.x3d\(filepath='${TEST_SRC_DIR}/io_tests/x3d/color_cube.x3d'\) --md5=c80538e272812c9d765d43df269d8a9b --md5_method=SCENE ) -add_test(import_x3d_teapot ${EXECUTABLE_OUTPUT_PATH}/blender ${GENERIC_ARGS} +add_test(import_x3d_teapot ${TEST_BLENDER_EXE} --python ${CMAKE_CURRENT_LIST_DIR}/bl_test.py -- --run={'FINISHED'}&bpy.ops.import_scene.x3d\(filepath='${TEST_SRC_DIR}/io_tests/x3d/teapot.x3d'\) --md5=fa19713ff71d4b3893dcbe0ab3a73955 --md5_method=SCENE --write-blend=/root/foo99.blend ) -add_test(import_x3d_suzanne_material ${EXECUTABLE_OUTPUT_PATH}/blender ${GENERIC_ARGS} +add_test(import_x3d_suzanne_material ${TEST_BLENDER_EXE} --python ${CMAKE_CURRENT_LIST_DIR}/bl_test.py -- --run={'FINISHED'}&bpy.ops.import_scene.x3d\(filepath='${TEST_SRC_DIR}/io_tests/x3d/suzanne_material.x3d'\) --md5=52a59dcf731904ac49953dd82c020ae5 --md5_method=SCENE ) # X3D Export -add_test(export_x3d_cube ${EXECUTABLE_OUTPUT_PATH}/blender ${GENERIC_ARGS} +add_test(export_x3d_cube ${TEST_BLENDER_EXE} ${TEST_SRC_DIR}/io_tests/blend_geometry/all_quads.blend --python ${CMAKE_CURRENT_LIST_DIR}/bl_test.py -- --run={'FINISHED'}&bpy.ops.export_scene.x3d\(filepath='${TEST_OUT_DIR}/export_x3d_cube.x3d',use_selection=False\) @@ -161,7 +166,7 @@ add_test(export_x3d_cube ${EXECUTABLE_OUTPUT_PATH}/blender ${GENERIC_ARGS} --md5=560ba3762a6604669994f661235ef93c --md5_method=FILE ) -add_test(export_x3d_nurbs ${EXECUTABLE_OUTPUT_PATH}/blender ${GENERIC_ARGS} +add_test(export_x3d_nurbs ${TEST_BLENDER_EXE} ${TEST_SRC_DIR}/io_tests/blend_geometry/nurbs.blend --python ${CMAKE_CURRENT_LIST_DIR}/bl_test.py -- --run={'FINISHED'}&bpy.ops.export_scene.x3d\(filepath='${TEST_OUT_DIR}/export_x3d_nurbs.x3d',use_selection=False\) @@ -169,7 +174,7 @@ add_test(export_x3d_nurbs ${EXECUTABLE_OUTPUT_PATH}/blender ${GENERIC_ARGS} --md5=078c0ca5a08f123cd2cdac48afb54853 --md5_method=FILE ) -add_test(export_x3d_all_objects ${EXECUTABLE_OUTPUT_PATH}/blender ${GENERIC_ARGS} +add_test(export_x3d_all_objects ${TEST_BLENDER_EXE} ${TEST_SRC_DIR}/io_tests/blend_scene/all_objects.blend --python ${CMAKE_CURRENT_LIST_DIR}/bl_test.py -- --run={'FINISHED'}&bpy.ops.export_scene.x3d\(filepath='${TEST_OUT_DIR}/export_x3d_all_objects.x3d',use_selection=False\) @@ -180,27 +185,27 @@ add_test(export_x3d_all_objects ${EXECUTABLE_OUTPUT_PATH}/blender ${GENERIC_ARGS # 3DS Import -add_test(import_3ds_cube ${EXECUTABLE_OUTPUT_PATH}/blender ${GENERIC_ARGS} +add_test(import_3ds_cube ${TEST_BLENDER_EXE} --python ${CMAKE_CURRENT_LIST_DIR}/bl_test.py -- --run={'FINISHED'}&bpy.ops.import_scene.autodesk_3ds\(filepath='${TEST_SRC_DIR}/io_tests/3ds/cube.3ds'\) --md5=cb5a45c35a343c3f5beca2a918472951 --md5_method=SCENE ) -add_test(import_3ds_hierarchy_lara ${EXECUTABLE_OUTPUT_PATH}/blender ${GENERIC_ARGS} +add_test(import_3ds_hierarchy_lara ${TEST_BLENDER_EXE} --python ${CMAKE_CURRENT_LIST_DIR}/bl_test.py -- --run={'FINISHED'}&bpy.ops.import_scene.autodesk_3ds\(filepath='${TEST_SRC_DIR}/io_tests/3ds/hierarchy_lara.3ds'\) --md5=2e9812099b26ad607fdcf4c7be918c71 --md5_method=SCENE --write-blend=/root/foo99.blend ) -add_test(import_3ds_hierarchy_greek_trireme ${EXECUTABLE_OUTPUT_PATH}/blender ${GENERIC_ARGS} +add_test(import_3ds_hierarchy_greek_trireme ${TEST_BLENDER_EXE} --python ${CMAKE_CURRENT_LIST_DIR}/bl_test.py -- --run={'FINISHED'}&bpy.ops.import_scene.autodesk_3ds\(filepath='${TEST_SRC_DIR}/io_tests/3ds/hierarchy_greek_trireme.3ds'\) --md5=d05b922d7be20356d8409d1f768a3a9a --md5_method=SCENE ) # 3DS Export -add_test(export_3ds_cube ${EXECUTABLE_OUTPUT_PATH}/blender ${GENERIC_ARGS} +add_test(export_3ds_cube ${TEST_BLENDER_EXE} ${TEST_SRC_DIR}/io_tests/blend_geometry/all_quads.blend --python ${CMAKE_CURRENT_LIST_DIR}/bl_test.py -- --run={'FINISHED'}&bpy.ops.export_scene.autodesk_3ds\(filepath='${TEST_OUT_DIR}/export_3ds_cube.3ds',use_selection=False\) @@ -208,7 +213,7 @@ add_test(export_3ds_cube ${EXECUTABLE_OUTPUT_PATH}/blender ${GENERIC_ARGS} --md5=0df6cfb130052d01e31ef77d391d4cc0 --md5_method=FILE ) -add_test(export_3ds_nurbs ${EXECUTABLE_OUTPUT_PATH}/blender ${GENERIC_ARGS} +add_test(export_3ds_nurbs ${TEST_BLENDER_EXE} ${TEST_SRC_DIR}/io_tests/blend_geometry/nurbs.blend --python ${CMAKE_CURRENT_LIST_DIR}/bl_test.py -- --run={'FINISHED'}&bpy.ops.export_scene.autodesk_3ds\(filepath='${TEST_OUT_DIR}/export_3ds_nurbs.3ds',use_selection=False\) @@ -216,7 +221,7 @@ add_test(export_3ds_nurbs ${EXECUTABLE_OUTPUT_PATH}/blender ${GENERIC_ARGS} --md5=ba1a6d43346fee3bcadc7e30e3c95935 --md5_method=FILE ) -add_test(export_3ds_all_objects ${EXECUTABLE_OUTPUT_PATH}/blender ${GENERIC_ARGS} +add_test(export_3ds_all_objects ${TEST_BLENDER_EXE} ${TEST_SRC_DIR}/io_tests/blend_scene/all_objects.blend --python ${CMAKE_CURRENT_LIST_DIR}/bl_test.py -- --run={'FINISHED'}&bpy.ops.export_scene.autodesk_3ds\(filepath='${TEST_OUT_DIR}/export_3ds_all_objects.3ds',use_selection=False\) @@ -228,7 +233,7 @@ add_test(export_3ds_all_objects ${EXECUTABLE_OUTPUT_PATH}/blender ${GENERIC_ARGS # FBX Export # 'use_metadata=False' for reliable md5's -add_test(export_fbx_cube ${EXECUTABLE_OUTPUT_PATH}/blender ${GENERIC_ARGS} +add_test(export_fbx_cube ${TEST_BLENDER_EXE} ${TEST_SRC_DIR}/io_tests/blend_geometry/all_quads.blend --python ${CMAKE_CURRENT_LIST_DIR}/bl_test.py -- --run={'FINISHED'}&bpy.ops.export_scene.fbx\(filepath='${TEST_OUT_DIR}/export_fbx_cube.fbx',use_selection=False,use_metadata=False\) @@ -236,7 +241,7 @@ add_test(export_fbx_cube ${EXECUTABLE_OUTPUT_PATH}/blender ${GENERIC_ARGS} --md5=a0806dc974d814f338b821ab326a6be0 --md5_method=FILE ) -add_test(export_fbx_nurbs ${EXECUTABLE_OUTPUT_PATH}/blender ${GENERIC_ARGS} +add_test(export_fbx_nurbs ${TEST_BLENDER_EXE} ${TEST_SRC_DIR}/io_tests/blend_geometry/nurbs.blend --python ${CMAKE_CURRENT_LIST_DIR}/bl_test.py -- --run={'FINISHED'}&bpy.ops.export_scene.fbx\(filepath='${TEST_OUT_DIR}/export_fbx_nurbs.fbx',use_selection=False,use_metadata=False\) @@ -244,7 +249,7 @@ add_test(export_fbx_nurbs ${EXECUTABLE_OUTPUT_PATH}/blender ${GENERIC_ARGS} --md5=2cda2b37ee6698aff4129af48fce1291 --md5_method=FILE ) -add_test(export_fbx_all_objects ${EXECUTABLE_OUTPUT_PATH}/blender ${GENERIC_ARGS} +add_test(export_fbx_all_objects ${TEST_BLENDER_EXE} ${TEST_SRC_DIR}/io_tests/blend_scene/all_objects.blend --python ${CMAKE_CURRENT_LIST_DIR}/bl_test.py -- --run={'FINISHED'}&bpy.ops.export_scene.fbx\(filepath='${TEST_OUT_DIR}/export_fbx_all_objects.fbx',use_selection=False,use_metadata=False\) |