Fix load_yaml default value (#5383)
This commit is contained in:
parent
0bbb16626c
commit
7511a5842d
2 changed files with 7 additions and 1 deletions
|
@ -74,6 +74,12 @@ class TestYaml(unittest.TestCase):
|
|||
doc = yaml.yaml.safe_load(file)
|
||||
assert doc["key"] == "value"
|
||||
|
||||
with patch_yaml_files({'test.yaml': None}):
|
||||
conf = 'key: !include test.yaml'
|
||||
with io.StringIO(conf) as file:
|
||||
doc = yaml.yaml.safe_load(file)
|
||||
assert doc["key"] == {}
|
||||
|
||||
@patch('homeassistant.util.yaml.os.walk')
|
||||
def test_include_dir_list(self, mock_walk):
|
||||
"""Test include dir list yaml."""
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue