def update_yaml(self, path: str) -> None: """Update metadata with static metadata from YAML file Args: path (str): Path to YAML dataset metadata Returns: None """ self.data = load_yaml_into_existing_dict(self.data, path)
def update_from_yaml(self, path: str) -> None: """Update metadata with static metadata from YAML file Args: path (str): Path to YAML dataset metadata Returns: None """ self.data = load_yaml_into_existing_dict(self.data, path)
def test_load_yaml_into_existing_dict(self, configfolder): existing_dict = load_yaml(join(configfolder, "hdx_config.yml")) result = load_yaml_into_existing_dict( existing_dict, join(configfolder, "project_configuration.yml") ) assert list(result.items()) == list(TestLoader.expected_yaml.items())
def test_load_yaml_into_existing_dict(self, configfolder): existing_dict = load_yaml(join(configfolder, 'hdx_config.yml')) result = load_yaml_into_existing_dict( existing_dict, join(configfolder, 'project_configuration.yml')) assert result == TestLoader.expected_yaml