MCPcopy Create free account
hub / github.com/celery/celery / test_classmethod

Method test_classmethod

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

Source from the content-addressed store, hash-verified

439 g(a=1, b=2, c=3)
440
441 def test_classmethod(self):
442 class A:
443 @classmethod
444 def f(cls, x):
445 return x
446
447 fun = head_from_fun(A.f, bound=False)
448 assert fun(A, 1) == 1
449
450 fun = head_from_fun(A.f, bound=True)
451 assert fun(1) == 1
452
453 def test_kwonly_required_args(self):
454 local = {}

Callers

nothing calls this directly

Calls 2

head_from_funFunction · 0.90
funFunction · 0.85

Tested by

no test coverage detected