Skip to content

Commit

Permalink
check error message
Browse files Browse the repository at this point in the history
  • Loading branch information
gengliangwang committed Aug 12, 2019
1 parent b64f9c1 commit 621ee0e
Showing 1 changed file with 3 additions and 2 deletions.
Expand Up @@ -227,13 +227,14 @@ class AvroCatalystDataConversionSuite extends SparkFunSuite
jsonFormatSchema,
options = Map.empty),
data.eval())
intercept[SparkException] {
val message = intercept[SparkException] {
AvroDataToCatalyst(
CatalystDataToAvro(
data,
None),
jsonFormatSchema,
options = Map.empty).eval()
}
}.getMessage
assert(message.contains("Malformed records are detected in record parsing."))
}
}

0 comments on commit 621ee0e

Please sign in to comment.