Add tests for yaml2sqlite; fix bugs in it.