Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Graphql mnesia #3725

Merged
merged 12 commits into from
Aug 23, 2022
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
1 change: 1 addition & 0 deletions big_tests/default.spec
Original file line number Diff line number Diff line change
Expand Up @@ -40,6 +40,7 @@
{suites, "tests", graphql_stats_SUITE}.
{suites, "tests", graphql_gdpr_SUITE}.
{suites, "tests", graphql_token_SUITE}.
{suites, "tests", graphql_mnesia_SUITE}.
{suites, "tests", graphql_vcard_SUITE}.
{suites, "tests", graphql_http_upload_SUITE}.
{suites, "tests", graphql_metric_SUITE}.
Expand Down
1 change: 1 addition & 0 deletions big_tests/dynamic_domains.spec
Original file line number Diff line number Diff line change
Expand Up @@ -57,6 +57,7 @@
{suites, "tests", graphql_stats_SUITE}.
{suites, "tests", graphql_gdpr_SUITE}.
{suites, "tests", graphql_token_SUITE}.
{suites, "tests", graphql_mnesia_SUITE}.
{suites, "tests", graphql_http_upload_SUITE}.
{suites, "tests", graphql_metric_SUITE}.

Expand Down
3 changes: 2 additions & 1 deletion big_tests/tests/graphql_helper.erl
Original file line number Diff line number Diff line change
Expand Up @@ -30,7 +30,7 @@ execute_command(Category, Command, Args, Config) ->
execute_command(Category, Command, Args, Config, Protocol).

execute_domain_admin_command(Category, Command, Args, Config) ->
#{Category := #{Command := #{doc := Doc}}} = get_specs(),
#{Category := #{commands := #{Command := #{doc := Doc}}}} = get_specs(),
execute_domain_auth(#{query => Doc, variables => Args}, Config).

%% Admin commands can be executed as GraphQL over HTTP or with CLI (mongooseimctl)
Expand All @@ -54,6 +54,7 @@ arg_name_to_binary(Name) when is_atom(Name) -> atom_to_binary(Name);
arg_name_to_binary(Name) when is_binary(Name) -> Name.

arg_value_to_binary(Value) when is_integer(Value) -> integer_to_binary(Value);
arg_value_to_binary(Value) when is_atom(Value) -> atom_to_binary(Value);
arg_value_to_binary(Value) when is_binary(Value) -> Value;
arg_value_to_binary(Value) when is_list(Value);
is_map(Value) -> iolist_to_binary(jiffy:encode(Value)).
Expand Down
Loading