Skip to content

Commit 947e271

Browse files
committed
[SPARK-39612][SQL][TESTS] DataFrame.exceptAll followed by count should work
### What changes were proposed in this pull request? This PR adds a test case broken by 4b93435 which was reverted in 161c596. ### Why are the changes needed? To prevent a regression in the future. This was a regression in Apache Spark 3.3 that used to work in Apache Spark 3.2. ### Does this PR introduce _any_ user-facing change? Yes, it makes `DataFrame.exceptAll` followed by `count` working. ### How was this patch tested? The unit test was added. Closes #37084 from HyukjinKwon/SPARK-39612. Authored-by: Hyukjin Kwon <[email protected]> Signed-off-by: Hyukjin Kwon <[email protected]>
1 parent 1269862 commit 947e271

File tree

1 file changed

+5
-0
lines changed

1 file changed

+5
-0
lines changed

sql/core/src/test/scala/org/apache/spark/sql/DataFrameSuite.scala

Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -3239,6 +3239,11 @@ class DataFrameSuite extends QueryTest
32393239
}
32403240
}
32413241
}
3242+
3243+
test("SPARK-39612: exceptAll with following count should work") {
3244+
val d1 = Seq("a").toDF
3245+
assert(d1.exceptAll(d1).count() === 0)
3246+
}
32423247
}
32433248

32443249
case class GroupByKey(a: Int, b: Int)

0 commit comments

Comments
 (0)