'Test secrets config checking method.'

def test_secrets(self):

    files = {get_test_config_dir('secret.yaml'): (BASE_CONFIG + 'http:\n        api_password:    !secret    http_pw'), 'secrets.yaml': 'logger:    debug\nhttp_pw:    abc123'}
    self.maxDiff = None
    with patch_yaml_files(files):
        config_path = get_test_config_dir('secret.yaml')
        secrets_path = get_test_config_dir('secrets.yaml')
        res = check_config.check(config_path)
        change_yaml_files(res)
        for (key, val) in res['secret_cache'].items():
            res['secret_cache'][key] = dict(val)
        self.assertDictEqual({'components': {'http': {'api_password': 'abc123', 'cors_allowed_origins': [], 'development': '0', 'ip_ban_enabled': True, 'login_attempts_threshold': (-1), 'server_host': '0.0.0.0', 'server_port': 8123, 'ssl_certificate': None, 'ssl_key': None, 'trusted_networks': [], 'use_x_forwarded_for': False}}, 'except': {}, 'secret_cache': {secrets_path: {'http_pw': 'abc123'}}, 'secrets': {'http_pw': 'abc123'}, 'yaml_files': ['.../secret.yaml', '.../secrets.yaml']}, res)
