Skip to content

Commit 84214be

Browse files
committed
Add an extra column which isn't part of the sort
1 parent ae1896b commit 84214be

File tree

1 file changed

+5
-5
lines changed

1 file changed

+5
-5
lines changed

sql/core/src/test/scala/org/apache/spark/sql/execution/SortSuite.scala

Lines changed: 5 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -24,18 +24,18 @@ class SortSuite extends SparkPlanTest {
2424
test("basic sorting using ExternalSort") {
2525

2626
val input = Seq(
27-
("Hello", 4),
28-
("Hello", 1),
29-
("World", 8)
27+
("Hello", 4, 2.0),
28+
("Hello", 1, 1.0),
29+
("World", 8, 3.0)
3030
)
3131

3232
checkAnswer(
33-
input.toDF("a", "b"),
33+
input.toDF("a", "b", "c"),
3434
ExternalSort('a.asc :: 'b.asc :: Nil, global = false, _: SparkPlan),
3535
input.sorted)
3636

3737
checkAnswer(
38-
input.toDF("a", "b"),
38+
input.toDF("a", "b", "c"),
3939
ExternalSort('b.asc :: 'a.asc :: Nil, global = false, _: SparkPlan),
4040
input.sortBy(t => (t._2, t._1)))
4141
}

0 commit comments

Comments
 (0)