mirror of
https://github.com/graphql-python/graphene.git
synced 2025-02-17 03:50:44 +03:00
Make assertion message use same var as test
Ensure that the assertion message correctly shows the value used by the assertion test.
This commit is contained in:
parent
94d46f7960
commit
f232e433e6
|
@ -32,7 +32,7 @@ def to_arguments(args, extra_args):
|
||||||
raise ValueError('Unknown argument "{}".'.format(default_name))
|
raise ValueError('Unknown argument "{}".'.format(default_name))
|
||||||
|
|
||||||
arg_name = default_name or arg.name
|
arg_name = default_name or arg.name
|
||||||
assert arg_name not in arguments, 'More than one Argument have same name "{}".'.format(arg.name)
|
assert arg_name not in arguments, 'More than one Argument have same name "{}".'.format(arg_name)
|
||||||
arguments[arg_name] = arg
|
arguments[arg_name] = arg
|
||||||
|
|
||||||
return arguments
|
return arguments
|
||||||
|
|
Loading…
Reference in New Issue
Block a user