Fix deprecation warnings in TestDatasetSink.