Skip to content

Commit 4bb76ba

Browse files
Fix MySQL and remove MyPy from PyPy job
1 parent 8a3b4d6 commit 4bb76ba

File tree

2 files changed

+7
-4
lines changed

2 files changed

+7
-4
lines changed

tests/test_functional.py

Lines changed: 4 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1206,12 +1206,14 @@ class GeometryWkt(Geometry):
12061206
as_binary = "ST_AsText"
12071207
ElementType = WKTElement
12081208

1209+
dialects_with_srid = ["geopackage", "mysql", "mariadb"]
1210+
12091211
# Define the table
12101212
cols = [
12111213
Column("id", Integer, primary_key=True),
12121214
]
12131215
cols.append(Column("geom_with_srid", GeometryWkt(geometry_type="LINESTRING", srid=4326)))
1214-
if dialect_name not in ["geopackage", "mariadb"]:
1216+
if dialect_name not in dialects_with_srid:
12151217
cols.append(Column("geom", GeometryWkt(geometry_type="LINESTRING")))
12161218
t = Table("use_wkt", MetaData(), *cols)
12171219

@@ -1229,7 +1231,7 @@ class GeometryWkt(Geometry):
12291231
from_shape(LineString([[0, 0], [4, 4]]), srid=4326),
12301232
]
12311233
]
1232-
if dialect_name not in ["geopackage", "mariadb"]:
1234+
if dialect_name not in dialects_with_srid:
12331235
for i, v in zip(
12341236
inserted_values,
12351237
[

tox.ini

Lines changed: 3 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -27,7 +27,9 @@ setenv=
2727
COVERAGE_FILE = {env:COVERAGE_FILE:.coverage-{envname}}
2828
EXPECTED_COV = 93
2929
pypy3: EXPECTED_COV = 85
30-
sqla14: PYTEST_ADDOPTS = {env:PYTEST_ADDOPTS:} --mypy-ignore-missing-imports
30+
sqla14: PYTEST_ADDOPTS = {env:PYTEST_ADDOPTS:} --mypy --mypy-ignore-missing-imports
31+
sqlalatest: PYTEST_ADDOPTS = {env:PYTEST_ADDOPTS:} --mypy
32+
pypy3: PYTEST_ADDOPTS = {env:PYTEST_ADDOPTS:}
3133
deps=
3234
sqla14: SQLAlchemy==1.4.*
3335
sqlalatest: SQLAlchemy
@@ -54,7 +56,6 @@ commands=
5456
--self-contained-html \
5557
--durations 10 \
5658
--durations-min=2.0 \
57-
--mypy \
5859
{posargs}
5960

6061
[testenv:coverage]

0 commit comments

Comments
 (0)