zhedoubushishi commented on a change in pull request #2833:
URL: https://github.com/apache/hudi/pull/2833#discussion_r631578916
##########
File path:
hudi-spark-datasource/hudi-spark/src/test/scala/org/apache/hudi/functional/HoodieSparkSqlWriterSuite.scala
##########
@@ -55,13 +55,13 @@ class HoodieSparkSqlWriterSuite extends FunSuite with
Matchers {
val originals = HoodieWriterUtils.parametersWithWriteDefaults(Map.empty)
val rhsKey = "hoodie.right.hand.side.key"
val rhsVal = "hoodie.right.hand.side.val"
- val modifier = Map(OPERATION_OPT_KEY -> INSERT_OPERATION_OPT_VAL,
TABLE_TYPE_OPT_KEY -> MOR_TABLE_TYPE_OPT_VAL, rhsKey -> rhsVal)
+ val modifier = Map(OPERATION_OPT_KEY.key -> INSERT_OPERATION_OPT_VAL,
TABLE_TYPE_OPT_KEY.key -> MOR_TABLE_TYPE_OPT_VAL, rhsKey -> rhsVal)
val modified = HoodieWriterUtils.parametersWithWriteDefaults(modifier)
val matcher = (k: String, v: String) => modified(k) should be(v)
originals foreach {
- case (OPERATION_OPT_KEY, _) => matcher(OPERATION_OPT_KEY,
INSERT_OPERATION_OPT_VAL)
- case (TABLE_TYPE_OPT_KEY, _) => matcher(TABLE_TYPE_OPT_KEY,
MOR_TABLE_TYPE_OPT_VAL)
+ case ("hoodie.datasource.write.operation", _) =>
matcher("hoodie.datasource.write.operation", INSERT_OPERATION_OPT_VAL)
+ case ("hoodie.datasource.write.table.type", _) =>
matcher("hoodie.datasource.write.table.type", MOR_TABLE_TYPE_OPT_VAL)
Review comment:
I changed other places, however, here scala only accepts stable
identifier which means it does not allow passing ```xxx.key()```
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
For queries about this service, please contact Infrastructure at:
[email protected]