mirror of
https://github.com/graphql-python/graphene.git
synced 2025-06-20 13:33:10 +03:00
* refactor: replace @deprecated decorator with upcoming native support (via typing-extensions) * chore: fix tests * chore: ruff fmt
14 lines
357 B
Python
14 lines
357 B
Python
from .. import deprecated
|
|
from ..resolve_only_args import resolve_only_args
|
|
|
|
|
|
def test_resolve_only_args(mocker):
|
|
mocker.patch.object(deprecated, "warn_deprecation")
|
|
|
|
def resolver(root, **args):
|
|
return root, args
|
|
|
|
wrapped_resolver = resolve_only_args(resolver)
|
|
result = wrapped_resolver(1, 2, a=3)
|
|
assert result == (1, {"a": 3})
|