From bcd36fbde6ff762b9783b53f8aeec7b141e3e554 Mon Sep 17 00:00:00 2001 From: Franck Nijhof Date: Sat, 10 Oct 2026 12:09:38 +0000 Subject: [PATCH] Check the CLI group against Typer, not click --- tests/cli/test_cli.py | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/tests/cli/test_cli.py b/tests/cli/test_cli.py index 43e0b3a2..b4a9ecbb 100644 --- a/tests/cli/test_cli.py +++ b/tests/cli/test_cli.py @@ -9,8 +9,8 @@ from typing import TYPE_CHECKING from unittest.mock import AsyncMock, MagicMock, patch -import click import pytest +from typer.core import TyperGroup from typer.main import get_command from typer.testing import CliRunner @@ -135,10 +135,10 @@ def routes_data() -> DeviceRoutes: def test_cli_structure(snapshot: SnapshotAssertion) -> None: """The CLI exposes the expected commands and options.""" group = get_command(cli) - assert isinstance(group, click.Group) + assert isinstance(group, TyperGroup) structure = {} for name, subcommand in sorted(group.commands.items()): - if isinstance(subcommand, click.Group): + if isinstance(subcommand, TyperGroup): structure[name] = { sub_name: sorted(param.name for param in sub_cmd.params) for sub_name, sub_cmd in sorted(subcommand.commands.items())