Add documentation and test for KeyValueDataSource.