Skip to content

Commit

Permalink
fix test
Browse files Browse the repository at this point in the history
  • Loading branch information
Jacob-Eliat-Eliat committed Nov 27, 2024
1 parent 880a6aa commit 996c0da
Show file tree
Hide file tree
Showing 2 changed files with 2 additions and 2 deletions.
2 changes: 1 addition & 1 deletion src/main/scala/cognite/spark/v1/FileContentRelation.scala
Original file line number Diff line number Diff line change
Expand Up @@ -122,7 +122,7 @@ class FileContentRelation(config: RelationConfig, fileExternalId: String, inferS
.handleErrorWith {
case e: fs2.text.LineTooLongException =>
throw new CdfSparkException(
s"""Line too long in file with external id: "$fileExternalId" SizeLimit in characters: $e.max, but $e.length characters accumulated""",
s"""Line too long in file with external id: "$fileExternalId" SizeLimit in characters: ${e.max}, but ${e.length} characters accumulated""",
e)
case other =>
throw other
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -251,7 +251,7 @@ class FileContentRelationTest extends FlatSpec with Matchers with SparkTest wit
override val lineSizeLimitCharacters: Int = 5
}

val expectedMessage = "Line too long in file with external id: \"fileContentTransformationFile\" SizeLimit in characters: 5"
val expectedMessage = "Line too long in file with external id: \"fileContentTransformationFile\" SizeLimit in characters: 5, but 47 characters accumulated"
val exception = sparkIntercept {
relation.createDataFrame
}
Expand Down

0 comments on commit 996c0da

Please sign in to comment.