openflexure-microscope-server/tests/shared_utils/__init__.py
2026-02-16 21:37:05 +00:00

10 lines
288 B
Python

"""Shared utilities for all test suites."""
import functools
def get_method_name(method):
"""Reliably get a methods name even if wrapped."""
while isinstance(method, functools.partial):
method = method.func
return getattr(method, "__name__", type(method).__name__)