"""Tests for {{ scope }} API endpoints.

This file is automatically @generated from the Meraki API specification.
Do not edit this file manually.

"""

from tests.generated.conftest import skip_on_unsupported

from meraki_client import MerakiClient

{% for endpoint in endpoints %}

def test_{{ endpoint.function_name }}(client: MerakiClient{% for param in endpoint.path_params %}{% if param == "serial" %}, device_serial: str{% else %}, {{ param }}: str{% endif %}{% endfor %}) -> None:
    """Test {{ endpoint.function_name }} endpoint."""
    {% if endpoint.is_paginated %}
    with skip_on_unsupported():
        result = client.{{ module_name }}.{{ endpoint.function_name }}({% for param in endpoint.path_params %}{{ param }}={% if param == "serial" %}device_serial{% else %}{{ param }}{% endif %}{% if not loop.last %}, {% endif %}{% endfor %}).collect()
    assert isinstance(result, list)
    {% else %}
    with skip_on_unsupported():
        client.{{ module_name }}.{{ endpoint.function_name }}({% for param in endpoint.path_params %}{{ param }}={% if param == "serial" %}device_serial{% else %}{{ param }}{% endif %}{% if not loop.last %}, {% endif %}{% endfor %})
    {% endif %}
{% endfor %}
