summaryrefslogtreecommitdiffstats
path: root/test/test_configuration_example.py
blob: 3a2c9b74d051b78de578f9f8e1c29e20c054f7bf (plain)
1
2
3
4
5
6
7
8
9
10
11
12
"""Sample usage of AnsibleConfig."""
from ansible_compat.config import AnsibleConfig


def test_example_config() -> None:
    """Test basic functionality of AnsibleConfig."""
    cfg = AnsibleConfig()
    assert isinstance(cfg.ACTION_WARNINGS, bool)
    # you can also use lowercase:
    assert isinstance(cfg.action_warnings, bool)
    # you can also use it as dictionary
    assert cfg["action_warnings"] == cfg.action_warnings