def test_default_lvl_2():
    """Tests if the default works properly with one nested level.

    Uses different values for the default and the environment variable.
    """
    VAR_NAME = "nested.test"
    ENV = "DYNATESTRUN_NESTED__TEST"
    settings = Dynaconf(
        environments=False,
        envvar_prefix="DYNATESTRUN",
        validators=[
            Validator(
                VAR_NAME,
                default=True,
                is_type_of=bool,
            ),
        ],
    )
    os.environ[ENV] = "false"
    assert settings.nested.test is False
    del os.environ[ENV]
Tests if the default works properly with one nested level.

    Uses different values for the default and the environment variable.
    
tests/test_validators.py