mirror of
https://github.com/simonw/sqlite-utils.git
synced 2026-11-19 16:48:42 +01:00
Run mypy against tests/ too, refs #37
This commit is contained in:
parent
7479933bc4
commit
c62363ebdc
4 changed files with 5 additions and 5 deletions
2
.github/workflows/test.yml
vendored
2
.github/workflows/test.yml
vendored
|
|
@ -33,7 +33,7 @@ jobs:
|
||||||
run: |
|
run: |
|
||||||
pytest
|
pytest
|
||||||
- name: run mypy
|
- name: run mypy
|
||||||
run: mypy sqlite_utils
|
run: mypy sqlite_utils tests
|
||||||
- name: run flake8
|
- name: run flake8
|
||||||
run: flake8
|
run: flake8
|
||||||
- name: Check formatting
|
- name: Check formatting
|
||||||
|
|
|
||||||
2
setup.py
2
setup.py
|
|
@ -33,7 +33,7 @@ setup(
|
||||||
extras_require={
|
extras_require={
|
||||||
"test": ["pytest", "black", "hypothesis"],
|
"test": ["pytest", "black", "hypothesis"],
|
||||||
"docs": ["sphinx_rtd_theme", "sphinx-autobuild", "codespell"],
|
"docs": ["sphinx_rtd_theme", "sphinx-autobuild", "codespell"],
|
||||||
"mypy": ["mypy", "types-click", "types-tabulate", "types-python-dateutil"],
|
"mypy": ["mypy", "types-click", "types-tabulate", "types-python-dateutil", "data-science-types"],
|
||||||
"flake8": ["flake8"],
|
"flake8": ["flake8"],
|
||||||
},
|
},
|
||||||
entry_points="""
|
entry_points="""
|
||||||
|
|
|
||||||
|
|
@ -197,7 +197,7 @@ if np:
|
||||||
|
|
||||||
# If pandas is available, add more types
|
# If pandas is available, add more types
|
||||||
if pd:
|
if pd:
|
||||||
COLUMN_TYPE_MAPPING.update({pd.Timestamp: "TEXT"})
|
COLUMN_TYPE_MAPPING.update({pd.Timestamp: "TEXT"}) # type: ignore
|
||||||
|
|
||||||
|
|
||||||
class AlterError(Exception):
|
class AlterError(Exception):
|
||||||
|
|
|
||||||
|
|
@ -20,9 +20,9 @@ import uuid
|
||||||
from .utils import collapse_whitespace
|
from .utils import collapse_whitespace
|
||||||
|
|
||||||
try:
|
try:
|
||||||
import pandas as pd
|
import pandas as pd # type: ignore
|
||||||
except ImportError:
|
except ImportError:
|
||||||
pd = None
|
pd = None # type: ignore
|
||||||
|
|
||||||
|
|
||||||
def test_create_table(fresh_db):
|
def test_create_table(fresh_db):
|
||||||
|
|
|
||||||
Loading…
Add table
Add a link
Reference in a new issue