We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent 395609d commit 4f2433eCopy full SHA for 4f2433e
tests/integ/test_df_sort.py
@@ -4,7 +4,7 @@
4
#
5
6
import pytest
7
-
+from unittest import mock
8
from snowflake.snowpark import Column
9
10
@@ -72,3 +72,14 @@ def test_sort_invalid_inputs(session):
72
"sort() only accepts str and Column objects,"
73
" or a list containing str and Column objects" in str(ex_info)
74
)
75
+
76
+ with mock.patch(
77
+ "snowflake.snowpark.context._is_snowpark_connect_compatible_mode", True
78
+ ):
79
+ # empty
80
+ with pytest.raises(ValueError) as ex_info:
81
+ df.sort()
82
+ assert "sort() needs at least one sort expression" in str(ex_info)
83
84
+ df.sort([])
85
0 commit comments