Skip to content

Commit 24762b7

Browse files
committed
#759 Fix order-dependent unit test
1 parent 33be25b commit 24762b7

File tree

1 file changed

+2
-3
lines changed

1 file changed

+2
-3
lines changed

spark-cobol/src/test/scala/za/co/absa/cobrix/spark/cobol/source/integration/Test39RecordExtractorSelfCheck.scala

+2-3
Original file line numberDiff line numberDiff line change
@@ -40,7 +40,7 @@ class Test39RecordExtractorSelfCheck extends AnyWordSpec with SparkTestBase with
4040
"input_split_records" -> "2")
4141
)
4242

43-
val actual = df.toJSON.collect().mkString("[", ",", "]")
43+
val actual = df.orderBy("A").toJSON.collect().mkString("[", ",", "]")
4444

4545
assert(actual == expected)
4646
}
@@ -117,7 +117,7 @@ class Test39RecordExtractorSelfCheck extends AnyWordSpec with SparkTestBase with
117117
"enable_indexes" -> "false")
118118
)
119119

120-
val actual = df.toJSON.collect().mkString("[", ",", "]")
120+
val actual = df.orderBy("A").toJSON.collect().mkString("[", ",", "]")
121121

122122
assert(actual == expected)
123123
}
@@ -133,5 +133,4 @@ class Test39RecordExtractorSelfCheck extends AnyWordSpec with SparkTestBase with
133133
.options(extraOptions)
134134
.load(inputPath)
135135
}
136-
137136
}

0 commit comments

Comments
 (0)