improve test coverage for YamlRepository
minor code cleanup