[erlang-questions] ct:require and ct:get_config
JD Bothma
jbothma@REDACTED
Fri Oct 19 13:31:45 CEST 2012
It looks like a clause is missing or documented incorrectly for common
test external config:
It says you can require and get config paths up to 3-tuples like
require(Required)...
where Required = Key | {Key, SubKeys} | {Key, SubKey, SubKeys}
but in R15B01, only 2-tuples are implemented (ct_config):
require(Key) when is_atom(Key) ->
require({Key,[]});
require({Key,SubKeys}) when is_atom(Key) ->
allocate('_UNDEF',Key,to_list(SubKeys));
require(Key) ->
{error,{invalid,Key}}.
Is there a specific reason for stopping at 2? Would a patch to fix the
documentation or to fix ct_config be preferred? If the latter, any
reason for not recursing down arbitrary depth of config tuple trees?
More information about the erlang-questions
mailing list