- Notifications
You must be signed in to change notification settings - Fork126
Commitaf1a49e
Jesse Whitehouse
Stop skipping StringTest
I've found that test_dont_truncate_rightside test is flaky because sometimesDBR returns the correct data but in the wrong order. It's supposed to checkthat a query returns ["AB", "BC"] but sometimes it returns ["BC", "AB"]which is the right data in the wrong order.Python list comparison doesn't evaluate that ["AB", "BC"] == ["BC", "AB"].We could reimplement the test using collections.Counter in stdlib orcheck with DBR team about why this order is sometimes different.Signed-off-by: Jesse Whitehouse <jesse.whitehouse@databricks.com>---Also, we had to break with SQLAlchemy's advice to never implement theTypeDecorator.literal_processor method because otherwise our stringsend up double-escaped and raise a syntax error.test_suite.py::StringTest_databricks+databricks::test_concatenate_binary PASSEDtest_suite.py::StringTest_databricks+databricks::test_concatenate_clauselist PASSEDtest_suite.py::StringTest_databricks+databricks::test_dont_truncate_rightside[%B%-expected0] PASSEDtest_suite.py::StringTest_databricks+databricks::test_dont_truncate_rightside[A%C%Z-expected2] PASSEDtest_suite.py::StringTest_databricks+databricks::test_dont_truncate_rightside[A%C-expected1] PASSEDtest_suite.py::StringTest_databricks+databricks::test_literal PASSEDtest_suite.py::StringTest_databricks+databricks::test_literal_backslashes PASSEDtest_suite.py::StringTest_databricks+databricks::test_literal_non_ascii PASSEDtest_suite.py::StringTest_databricks+databricks::test_literal_quoting PASSEDtest_suite.py::StringTest_databricks+databricks::test_nolength_string PASSED1 parentab8e28f commitaf1a49e
File tree
3 files changed
+63
-19
lines changed- src/databricks/sqlalchemy
- test
3 files changed
+63
-19
lines changed| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
51 | 51 | | |
52 | 52 | | |
53 | 53 | | |
| 54 | + | |
54 | 55 | | |
55 | 56 | | |
56 | 57 | | |
| |||
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
5 | 5 | | |
6 | 6 | | |
7 | 7 | | |
| 8 | + | |
| 9 | + | |
| 10 | + | |
8 | 11 | | |
9 | 12 | | |
10 | 13 | | |
| |||
132 | 135 | | |
133 | 136 | | |
134 | 137 | | |
| 138 | + | |
| 139 | + | |
| 140 | + | |
| 141 | + | |
| 142 | + | |
| 143 | + | |
| 144 | + | |
| 145 | + | |
| 146 | + | |
| 147 | + | |
| 148 | + | |
| 149 | + | |
| 150 | + | |
| 151 | + | |
| 152 | + | |
| 153 | + | |
| 154 | + | |
| 155 | + | |
| 156 | + | |
| 157 | + | |
| 158 | + | |
| 159 | + | |
| 160 | + | |
| 161 | + | |
| 162 | + | |
| 163 | + | |
| 164 | + | |
| 165 | + | |
| 166 | + | |
| 167 | + | |
| 168 | + | |
| 169 | + | |
| 170 | + | |
| 171 | + | |
| 172 | + | |
| 173 | + | |
| 174 | + | |
| 175 | + | |
| 176 | + | |
| 177 | + | |
| 178 | + | |
| 179 | + | |
| 180 | + | |
| 181 | + | |
| 182 | + | |
| 183 | + | |
| 184 | + | |
| 185 | + | |
| 186 | + | |
| 187 | + | |
| 188 | + | |
| 189 | + | |
| 190 | + | |
| 191 | + | |
| 192 | + | |
| 193 | + | |
| 194 | + | |
| 195 | + | |
| 196 | + | |
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
236 | 236 | | |
237 | 237 | | |
238 | 238 | | |
239 | | - | |
240 | | - | |
241 | | - | |
242 | | - | |
243 | | - | |
244 | | - | |
245 | | - | |
246 | | - | |
247 | | - | |
248 | | - | |
249 | | - | |
250 | | - | |
251 | | - | |
252 | | - | |
253 | | - | |
254 | | - | |
255 | | - | |
256 | | - | |
257 | | - | |
258 | 239 | | |
259 | 240 | | |
260 | 241 | | |
| |||
0 commit comments
Comments
(0)