mirror of
https://github.com/blender/blender
synced 2026-11-22 03:45:13 +03:00
This commit bumps the `ios` branch from 5.0.0 alpha to 5.1.2 release. I merged v5.0-release first then v5.1-release. So it was a sequential merge. I'm just waiting to the approval of continuing development. The stuff that are missing (those are so close to implement): - #145484 iOS: Keyboard Input Support: https://projects.blender.org/blender/blender/pulls/145484 - #145702 iOS: Add clipboard Image: https://projects.blender.org/blender/blender/pulls/145702 - Fix QOS threading - Expose Downloads - UIScene Migration `make deps` needs to run two times. (still hacky....) OSL occurs racing conditions. Disclaimer: I used AI for searching in Documentation of Deps. So the implementation is by hand. **SACRED PINKY FINGER PROMISE** Pull Request: https://projects.blender.org/blender/blender/pulls/161073
39 lines
1.3 KiB
Python
39 lines
1.3 KiB
Python
# SPDX-FileCopyrightText: 2025 Blender Authors
|
|
#
|
|
# SPDX-License-Identifier: GPL-2.0-or-later
|
|
|
|
|
|
import unittest
|
|
import bpy
|
|
import sys
|
|
|
|
|
|
class TestObjectEdit(unittest.TestCase):
|
|
|
|
def setUp(self):
|
|
if bpy.context.object and bpy.context.object.mode != 'OBJECT':
|
|
bpy.ops.object.mode_set(mode='OBJECT')
|
|
for mesh in [mesh for mesh in bpy.data.meshes]:
|
|
bpy.data.meshes.remove(mesh)
|
|
for ob in [ob for ob in bpy.data.objects]:
|
|
bpy.data.objects.remove(ob)
|
|
|
|
def test_auto_smooth_detection(self):
|
|
bpy.ops.mesh.primitive_cube_add()
|
|
ob = bpy.context.object
|
|
bpy.ops.object.shade_auto_smooth(use_auto_smooth=True)
|
|
bpy.ops.object.shade_auto_smooth(use_auto_smooth=True)
|
|
bpy.ops.object.shade_auto_smooth(use_auto_smooth=True)
|
|
bpy.ops.object.shade_auto_smooth(use_auto_smooth=True)
|
|
self.assertEqual(len(ob.modifiers), 1)
|
|
bpy.ops.object.shade_flat()
|
|
self.assertEqual(len(ob.modifiers), 0)
|
|
bpy.ops.object.shade_auto_smooth(use_auto_smooth=True)
|
|
bpy.ops.object.shade_smooth()
|
|
self.assertEqual(len(ob.modifiers), 0)
|
|
|
|
|
|
if __name__ == '__main__':
|
|
import sys
|
|
sys.argv = [__file__] + (sys.argv[sys.argv.index("--") + 1:] if "--" in sys.argv else [])
|
|
unittest.main()
|