plesty.lib.test.grouped_param_keys

Tests for grouped parameter key resolution in ConfigSystem.

The three test_* functions are collected by pytest when imported into a suite, but the module itself imports nothing from pytest: it ships in plesty-lib, where pytest is a dev-group dependency (#19).

Functions

_assert_key_error(→ None)

Assert that looking up key raises KeyError.

_build_config_system(...)

test_default_param_uses_bare_key_only(→ None)

Verify default-group params are accessible only by bare key, not prefixed key.

test_grouped_param_requires_full_key(→ None)

Verify grouped params require the full prefix.key form.

test_get_config_list_returns_full_keys_for_grouped_params(→ None)

Verify get_config_list returns full keys for grouped params and bare keys for defaults.

Module Contents

plesty.lib.test.grouped_param_keys._assert_key_error(call: collections.abc.Callable[[], Any], key: str) None

Assert that looking up key raises KeyError.

Parameters:
  • call (collections.abc.Callable[[], Any])

  • key (str)

Return type:

None

plesty.lib.test.grouped_param_keys._build_config_system() plesty.lib.device.params.ConfigSystem
Return type:

plesty.lib.device.params.ConfigSystem

plesty.lib.test.grouped_param_keys.test_default_param_uses_bare_key_only() None

Verify default-group params are accessible only by bare key, not prefixed key.

Return type:

None

plesty.lib.test.grouped_param_keys.test_grouped_param_requires_full_key() None

Verify grouped params require the full prefix.key form.

Return type:

None

plesty.lib.test.grouped_param_keys.test_get_config_list_returns_full_keys_for_grouped_params() None

Verify get_config_list returns full keys for grouped params and bare keys for defaults.

Return type:

None