From 64b637e70bd6eeb67314e041021339fa9fb10454 Mon Sep 17 00:00:00 2001 From: Patryk Czajka Date: Tue, 5 Mar 2024 16:16:53 +0100 Subject: [PATCH] Add snow --help to test_help_messages (#821) * Add snow --help to test_help_messages * update snapshot --- tests/__snapshots__/test_help_messages.ambr | 29 +++++++++++++++++++++ tests/test_help_messages.py | 1 + 2 files changed, 30 insertions(+) diff --git a/tests/__snapshots__/test_help_messages.ambr b/tests/__snapshots__/test_help_messages.ambr index 42b385f329..42f4795802 100644 --- a/tests/__snapshots__/test_help_messages.ambr +++ b/tests/__snapshots__/test_help_messages.ambr @@ -1,4 +1,33 @@ # serializer version: 1 +# name: test_help_messages[] + ''' + + Usage: default [OPTIONS] COMMAND [ARGS]... + + Snowflake CLI tool for developers. + + ╭─ Options ────────────────────────────────────────────────────────────────────╮ + │ --version Shows version of the Snowflake CLI │ + │ --info Shows information about the Snowflake CLI │ + │ --config-file FILE Specifies Snowflake CLI configuration file that │ + │ should be used │ + │ [default: None] │ + │ --help -h Show this message and exit. │ + ╰──────────────────────────────────────────────────────────────────────────────╯ + ╭─ Commands ───────────────────────────────────────────────────────────────────╮ + │ app Manages a Snowflake Native App │ + │ connection Manages connections to Snowflake. │ + │ object Manages Snowflake objects like warehouses and stages │ + │ snowpark Manages procedures and functions. │ + │ spcs Manages Snowpark Container Services compute pools, services, │ + │ image registries, and image repositories. │ + │ sql Executes Snowflake query. │ + │ streamlit Manages Streamlit in Snowflake. │ + ╰──────────────────────────────────────────────────────────────────────────────╯ + + + ''' +# --- # name: test_help_messages[app.bundle] ''' diff --git a/tests/test_help_messages.py b/tests/test_help_messages.py index fcafaae5b3..477679b622 100644 --- a/tests/test_help_messages.py +++ b/tests/test_help_messages.py @@ -18,6 +18,7 @@ def _iter_through_commands(command, path): yield from _iter_through_commands(subcommand, path) path.pop() + yield [] # "snow" with no commands builtin_plugins = load_only_builtin_command_plugins() for plugin in builtin_plugins: spec = plugin.command_spec