MCPcopy
hub / github.com/celery/celery / test_classmethod

Method test_classmethod

t/unit/utils/test_functional.py:338–348  ·  view source on GitHub ↗
(self)

Source from the content-addressed store, hash-verified

336 g(a=1, b=2, c=3)
337
338 def test_classmethod(self):
339 class A:
340 @classmethod
341 def f(cls, x):
342 return x
343
344 fun = head_from_fun(A.f, bound=False)
345 assert fun(A, 1) == 1
346
347 fun = head_from_fun(A.f, bound=True)
348 assert fun(1) == 1
349
350 def test_kwonly_required_args(self):
351 local = {}

Callers

nothing calls this directly

Calls 2

head_from_funFunction · 0.90
funFunction · 0.85

Tested by

no test coverage detected