databricks-sqlalchemy 1.0.2__py3-none-any.whl → 2.0.1__py3-none-any.whl

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (35) hide show
  1. CHANGELOG.md +271 -2
  2. databricks/sqlalchemy/__init__.py +4 -1
  3. databricks/sqlalchemy/_ddl.py +100 -0
  4. databricks/sqlalchemy/_parse.py +385 -0
  5. databricks/sqlalchemy/_types.py +323 -0
  6. databricks/sqlalchemy/base.py +436 -0
  7. databricks/sqlalchemy/dependency_test/test_dependency.py +22 -0
  8. databricks/sqlalchemy/py.typed +0 -0
  9. databricks/sqlalchemy/pytest.ini +4 -0
  10. databricks/sqlalchemy/requirements.py +249 -0
  11. databricks/sqlalchemy/setup.cfg +4 -0
  12. databricks/sqlalchemy/test/_extra.py +70 -0
  13. databricks/sqlalchemy/test/_future.py +331 -0
  14. databricks/sqlalchemy/test/_regression.py +311 -0
  15. databricks/sqlalchemy/test/_unsupported.py +450 -0
  16. databricks/sqlalchemy/test/conftest.py +13 -0
  17. databricks/sqlalchemy/test/overrides/_componentreflectiontest.py +189 -0
  18. databricks/sqlalchemy/test/overrides/_ctetest.py +33 -0
  19. databricks/sqlalchemy/test/test_suite.py +13 -0
  20. databricks/sqlalchemy/test_local/__init__.py +5 -0
  21. databricks/sqlalchemy/test_local/conftest.py +44 -0
  22. databricks/sqlalchemy/test_local/e2e/MOCK_DATA.xlsx +0 -0
  23. databricks/sqlalchemy/test_local/e2e/test_basic.py +543 -0
  24. databricks/sqlalchemy/test_local/test_ddl.py +96 -0
  25. databricks/sqlalchemy/test_local/test_parsing.py +160 -0
  26. databricks/sqlalchemy/test_local/test_types.py +161 -0
  27. {databricks_sqlalchemy-1.0.2.dist-info → databricks_sqlalchemy-2.0.1.dist-info}/METADATA +60 -39
  28. databricks_sqlalchemy-2.0.1.dist-info/RECORD +31 -0
  29. databricks/sqlalchemy/dialect/__init__.py +0 -340
  30. databricks/sqlalchemy/dialect/base.py +0 -17
  31. databricks/sqlalchemy/dialect/compiler.py +0 -38
  32. databricks_sqlalchemy-1.0.2.dist-info/RECORD +0 -10
  33. {databricks_sqlalchemy-1.0.2.dist-info → databricks_sqlalchemy-2.0.1.dist-info}/LICENSE +0 -0
  34. {databricks_sqlalchemy-1.0.2.dist-info → databricks_sqlalchemy-2.0.1.dist-info}/WHEEL +0 -0
  35. {databricks_sqlalchemy-1.0.2.dist-info → databricks_sqlalchemy-2.0.1.dist-info}/entry_points.txt +0 -0
@@ -0,0 +1,311 @@
1
+ # type: ignore
2
+
3
+ import pytest
4
+ from sqlalchemy.testing.suite import (
5
+ ArgSignatureTest,
6
+ BooleanTest,
7
+ CastTypeDecoratorTest,
8
+ ComponentReflectionTestExtra,
9
+ CompositeKeyReflectionTest,
10
+ CompoundSelectTest,
11
+ DateHistoricTest,
12
+ DateTest,
13
+ DateTimeCoercedToDateTimeTest,
14
+ DateTimeHistoricTest,
15
+ DateTimeMicrosecondsTest,
16
+ DateTimeTest,
17
+ DeprecatedCompoundSelectTest,
18
+ DistinctOnTest,
19
+ EscapingTest,
20
+ ExistsTest,
21
+ ExpandingBoundInTest,
22
+ FetchLimitOffsetTest,
23
+ FutureTableDDLTest,
24
+ HasTableTest,
25
+ IdentityAutoincrementTest,
26
+ InsertBehaviorTest,
27
+ IntegerTest,
28
+ IsOrIsNotDistinctFromTest,
29
+ JoinTest,
30
+ LikeFunctionsTest,
31
+ NormalizedNameTest,
32
+ NumericTest,
33
+ OrderByLabelTest,
34
+ PingTest,
35
+ PostCompileParamsTest,
36
+ ReturningGuardsTest,
37
+ RowFetchTest,
38
+ SameNamedSchemaTableTest,
39
+ StringTest,
40
+ TableDDLTest,
41
+ TableNoColumnsTest,
42
+ TextTest,
43
+ TimeMicrosecondsTest,
44
+ TimestampMicrosecondsTest,
45
+ TimeTest,
46
+ TimeTZTest,
47
+ TrueDivTest,
48
+ UnicodeTextTest,
49
+ UnicodeVarcharTest,
50
+ UuidTest,
51
+ ValuesExpressionTest,
52
+ )
53
+
54
+ from databricks.sqlalchemy.test.overrides._ctetest import CTETest
55
+ from databricks.sqlalchemy.test.overrides._componentreflectiontest import (
56
+ ComponentReflectionTest,
57
+ )
58
+
59
+
60
+ @pytest.mark.reviewed
61
+ class NumericTest(NumericTest):
62
+ pass
63
+
64
+
65
+ @pytest.mark.reviewed
66
+ class HasTableTest(HasTableTest):
67
+ pass
68
+
69
+
70
+ @pytest.mark.reviewed
71
+ class ComponentReflectionTestExtra(ComponentReflectionTestExtra):
72
+ pass
73
+
74
+
75
+ @pytest.mark.reviewed
76
+ class InsertBehaviorTest(InsertBehaviorTest):
77
+ pass
78
+
79
+
80
+ @pytest.mark.reviewed
81
+ class ComponentReflectionTest(ComponentReflectionTest):
82
+ """This test requires two schemas be present in the target Databricks workspace:
83
+ - The schema set in --dburi
84
+ - A second schema named "test_schema"
85
+
86
+ Note that test_get_multi_foreign keys is flaky because DBR does not guarantee the order of data returned in DESCRIBE TABLE EXTENDED
87
+
88
+ _Most_ of these tests pass if we manually override the bad test setup.
89
+ """
90
+
91
+ pass
92
+
93
+
94
+ @pytest.mark.reviewed
95
+ class TableDDLTest(TableDDLTest):
96
+ pass
97
+
98
+
99
+ @pytest.mark.reviewed
100
+ class FutureTableDDLTest(FutureTableDDLTest):
101
+ pass
102
+
103
+
104
+ @pytest.mark.reviewed
105
+ class FetchLimitOffsetTest(FetchLimitOffsetTest):
106
+ pass
107
+
108
+
109
+ @pytest.mark.reviewed
110
+ class UuidTest(UuidTest):
111
+ pass
112
+
113
+
114
+ @pytest.mark.reviewed
115
+ class ValuesExpressionTest(ValuesExpressionTest):
116
+ pass
117
+
118
+
119
+ @pytest.mark.reviewed
120
+ class BooleanTest(BooleanTest):
121
+ pass
122
+
123
+
124
+ @pytest.mark.reviewed
125
+ class PostCompileParamsTest(PostCompileParamsTest):
126
+ pass
127
+
128
+
129
+ @pytest.mark.reviewed
130
+ class TimeMicrosecondsTest(TimeMicrosecondsTest):
131
+ pass
132
+
133
+
134
+ @pytest.mark.reviewed
135
+ class TextTest(TextTest):
136
+ pass
137
+
138
+
139
+ @pytest.mark.reviewed
140
+ class StringTest(StringTest):
141
+ pass
142
+
143
+
144
+ @pytest.mark.reviewed
145
+ class DateTimeMicrosecondsTest(DateTimeMicrosecondsTest):
146
+ pass
147
+
148
+
149
+ @pytest.mark.reviewed
150
+ class TimestampMicrosecondsTest(TimestampMicrosecondsTest):
151
+ pass
152
+
153
+
154
+ @pytest.mark.reviewed
155
+ class DateTimeCoercedToDateTimeTest(DateTimeCoercedToDateTimeTest):
156
+ pass
157
+
158
+
159
+ @pytest.mark.reviewed
160
+ class TimeTest(TimeTest):
161
+ pass
162
+
163
+
164
+ @pytest.mark.reviewed
165
+ class DateTimeTest(DateTimeTest):
166
+ pass
167
+
168
+
169
+ @pytest.mark.reviewed
170
+ class DateTimeHistoricTest(DateTimeHistoricTest):
171
+ pass
172
+
173
+
174
+ @pytest.mark.reviewed
175
+ class DateTest(DateTest):
176
+ pass
177
+
178
+
179
+ @pytest.mark.reviewed
180
+ class DateHistoricTest(DateHistoricTest):
181
+ pass
182
+
183
+
184
+ @pytest.mark.reviewed
185
+ class RowFetchTest(RowFetchTest):
186
+ pass
187
+
188
+
189
+ @pytest.mark.reviewed
190
+ class CompositeKeyReflectionTest(CompositeKeyReflectionTest):
191
+ pass
192
+
193
+
194
+ @pytest.mark.reviewed
195
+ class TrueDivTest(TrueDivTest):
196
+ pass
197
+
198
+
199
+ @pytest.mark.reviewed
200
+ class ArgSignatureTest(ArgSignatureTest):
201
+ pass
202
+
203
+
204
+ @pytest.mark.reviewed
205
+ class CompoundSelectTest(CompoundSelectTest):
206
+ pass
207
+
208
+
209
+ @pytest.mark.reviewed
210
+ class DeprecatedCompoundSelectTest(DeprecatedCompoundSelectTest):
211
+ pass
212
+
213
+
214
+ @pytest.mark.reviewed
215
+ class CastTypeDecoratorTest(CastTypeDecoratorTest):
216
+ pass
217
+
218
+
219
+ @pytest.mark.reviewed
220
+ class DistinctOnTest(DistinctOnTest):
221
+ pass
222
+
223
+
224
+ @pytest.mark.reviewed
225
+ class EscapingTest(EscapingTest):
226
+ pass
227
+
228
+
229
+ @pytest.mark.reviewed
230
+ class ExistsTest(ExistsTest):
231
+ pass
232
+
233
+
234
+ @pytest.mark.reviewed
235
+ class IntegerTest(IntegerTest):
236
+ pass
237
+
238
+
239
+ @pytest.mark.reviewed
240
+ class IsOrIsNotDistinctFromTest(IsOrIsNotDistinctFromTest):
241
+ pass
242
+
243
+
244
+ @pytest.mark.reviewed
245
+ class JoinTest(JoinTest):
246
+ pass
247
+
248
+
249
+ @pytest.mark.reviewed
250
+ class OrderByLabelTest(OrderByLabelTest):
251
+ pass
252
+
253
+
254
+ @pytest.mark.reviewed
255
+ class PingTest(PingTest):
256
+ pass
257
+
258
+
259
+ @pytest.mark.reviewed
260
+ class ReturningGuardsTest(ReturningGuardsTest):
261
+ pass
262
+
263
+
264
+ @pytest.mark.reviewed
265
+ class SameNamedSchemaTableTest(SameNamedSchemaTableTest):
266
+ pass
267
+
268
+
269
+ @pytest.mark.reviewed
270
+ class UnicodeTextTest(UnicodeTextTest):
271
+ pass
272
+
273
+
274
+ @pytest.mark.reviewed
275
+ class UnicodeVarcharTest(UnicodeVarcharTest):
276
+ pass
277
+
278
+
279
+ @pytest.mark.reviewed
280
+ class TableNoColumnsTest(TableNoColumnsTest):
281
+ pass
282
+
283
+
284
+ @pytest.mark.reviewed
285
+ class ExpandingBoundInTest(ExpandingBoundInTest):
286
+ pass
287
+
288
+
289
+ @pytest.mark.reviewed
290
+ class CTETest(CTETest):
291
+ pass
292
+
293
+
294
+ @pytest.mark.reviewed
295
+ class NormalizedNameTest(NormalizedNameTest):
296
+ pass
297
+
298
+
299
+ @pytest.mark.reviewed
300
+ class IdentityAutoincrementTest(IdentityAutoincrementTest):
301
+ pass
302
+
303
+
304
+ @pytest.mark.reviewed
305
+ class LikeFunctionsTest(LikeFunctionsTest):
306
+ pass
307
+
308
+
309
+ @pytest.mark.reviewed
310
+ class TimeTZTest(TimeTZTest):
311
+ pass