Changeset View
Changeset View
Standalone View
Standalone View
tests/python/bl_alembic_io_test.py
| Show First 20 Lines • Show All 294 Lines • ▼ Show 20 Lines | def test_export_flattened(self): | ||||
| self.assertIsNone(objects[name].parent) | self.assertIsNone(objects[name].parent) | ||||
| def do_export_import_test(self, *, flatten: bool): | def do_export_import_test(self, *, flatten: bool): | ||||
| bpy.ops.wm.open_mainfile(filepath=str(args.testdir / "camera_transforms.blend")) | bpy.ops.wm.open_mainfile(filepath=str(args.testdir / "camera_transforms.blend")) | ||||
| abc_path = self.tempdir / "camera_transforms.abc" | abc_path = self.tempdir / "camera_transforms.abc" | ||||
| self.assertIn('FINISHED', bpy.ops.wm.alembic_export( | self.assertIn('FINISHED', bpy.ops.wm.alembic_export( | ||||
| filepath=str(abc_path), | filepath=str(abc_path), | ||||
| renderable_only=False, | |||||
| flatten=flatten, | flatten=flatten, | ||||
| )) | )) | ||||
| # Re-import what we just exported into an empty file. | # Re-import what we just exported into an empty file. | ||||
| bpy.ops.wm.open_mainfile(filepath=str(args.testdir / "empty.blend")) | bpy.ops.wm.open_mainfile(filepath=str(args.testdir / "empty.blend")) | ||||
| self.assertIn('FINISHED', bpy.ops.wm.alembic_import(filepath=str(abc_path))) | self.assertIn('FINISHED', bpy.ops.wm.alembic_import(filepath=str(abc_path))) | ||||
| # Test that the import was ok. | # Test that the import was ok. | ||||
| ▲ Show 20 Lines • Show All 67 Lines • Show Last 20 Lines | |||||