13 lines
363 B
Python
13 lines
363 B
Python
from magicli.magicli import get_config
|
|
|
|
|
|
def function_to_call(name, amount=1): ...
|
|
|
|
def command(): ...
|
|
|
|
def test_basic_config():
|
|
config = get_config(function_to_call, [command])
|
|
assert config['arguments'] == {'name': {}}
|
|
assert config['options']['amount'] == {'default': 1, 'type': int}
|
|
assert config['commands']['command'] == {'docstring': None}
|