Add tests for SparkCoreAdaptor's postToSpark