added YAML support, methods and tests