added Status field to SQL "SHOW TABLES" result.

This commit is contained in:
James Gorlick 2016-10-27 17:31:41 -07:00 committed by Brett Hazen
parent 37a868c226
commit cb91ce4506
2 changed files with 8 additions and 6 deletions

View File

@ -752,11 +752,11 @@ with_security_when_user_is_given_permissions_user_can_show_tables_test(Ctx) ->
{ok, {Columns, Rows}} = riakc_ts:query(Pid, "SHOW TABLES"),
{_Saver, TableList} = ?config(saved_config, Ctx),
?assertEqual(
[<<"Table">>],
[<<"Table">>, <<"Status">>],
Columns
),
?assertEqual(
lists:sort(Rows),
lists:sort(TableList)
),
ActualRows = lists:sort(Rows),
ExpectedRows = [{TableName, <<"Active">>} ||
{TableName} <- lists:sort(TableList) ],
?assertEqual(ExpectedRows, ActualRows),
add_no_table_to_list(Ctx).

View File

@ -50,8 +50,10 @@ confirm() ->
end,
Tables),
Got1 = ts_ops:query(Cluster, "SHOW TABLES"),
ExpectedRows = [{TableName, <<"Active">>} ||
{TableName} <- lists:sort(Tables) ],
?assertEqual(
{ok, {[<<"Table">>], lists:usort(Tables)}},
{ok, {[<<"Table">>, <<"Status">>], ExpectedRows}},
Got1
),
pass.