Bug fixes and Datasource unit tests.