-
Notifications
You must be signed in to change notification settings - Fork 3
/
Copy pathpyproject.toml
125 lines (115 loc) · 3.19 KB
/
pyproject.toml
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
[build-system]
requires = ["hatchling", "hatch-vcs"]
build-backend = "hatchling.build"
[project]
name = "db-testtools"
dynamic = ["version"]
readme = "README.rst"
license = "Apache-2.0"
requires-python = ">=3.8"
authors = [
{ name = "Julian Edwards", email = "[email protected]" },
]
maintainers = [
{ name = "Julian Edwards", email = "[email protected]" },
]
classifiers = [
"Development Status :: 5 - Production/Stable",
"Environment :: Console",
"Framework :: Hatch",
"Intended Audience :: Developers",
"Intended Audience :: Information Technology",
"Natural Language :: English",
"Operating System :: POSIX :: Linux",
"Programming Language :: Python :: 3",
"Programming Language :: Python :: 3.8",
"Programming Language :: Python :: 3.9",
"Programming Language :: Python :: 3.10",
"Programming Language :: Python :: 3.11",
"Programming Language :: Python :: 3.12",
"Topic :: Utilities",
]
urls.Source = "https://github.com/juledwar/db-testtools"
dependencies = [
"docker>=5.0.2",
"fixtures>=3.0.0",
"psycopg2-binary>=2.9.1",
"retry>=0.9.2",
"sqlalchemy>=1.4.23",
"testresources>=2.0.1",
]
[project.optional-dependencies]
test = [
"build>=0.7.0",
"coverage[toml]>=6.0.2",
"ipython>=7.28.0",
"pdbpp>=0.10.3",
"ruff>=0.5.3",
"sqlalchemy",
"stestr>=3.2.1",
"testresources",
"testscenarios>=0.5.0",
"testtools>=2.5.0",
"twine>=3.4.2",
]
[tool.hatch.version]
source = "vcs"
[tool.hatch.build.hooks.vcs]
version-file = "dbtesttools/_version.py"
[tool.hatch.build.targets.wheel]
packages = ["dbtesttools"]
[tool.hatch.build.targets.sdist]
include = ["dbtesttools"]
exclude = ["tests"]
[tool.hatch.envs.default]
path = ".hatch"
features = ["test"]
scripts.debug = ["python -m testtools.run discover -v -s dbtesttools/tests -t {root} -p test*.py {args}"]
# Concurrency explicitly set to two because:
# 1. Want to make sure that 1 DB resource is brought up per thread
# 2. Want to make sure that tests will re-use the same DB resource
scripts.py3 = ["stestr run --concurrency 2 -t dbtesttools/tests --top-dir {root} {args}"]
scripts.formatcheck = [
"ruff format --check dbtesttools",
"ruff check --select I --show-fixes dbtesttools",
"hatch build",
"twine check dist/*",
]
scripts.format = [
"ruff check --select I --fix-only --show-fixes dbtesttools",
"ruff format dbtesttools",
]
scripts.ci = ["py3", "formatcheck"]
scripts.testpypi = ["twine upload --repository testpypi {args}"]
scripts.pypi = ["twine upload --repository pypi {args}"]
[tool.coverage.run]
omit = [
'*dbtesttools/tests*',
'*dbtesttools/testing*',
'dbtesttools/__init__.py',
]
[tool.ruff]
line-length = 79
output-format = "full"
target-version = 'py37'
exclude = [
".git",
".tox",
"__pycache__",
"alembic",
"bin",
"lib",
"build",
"dist",
".eggs",
]
[tool.ruff.format]
quote-style = 'preserve'
[tool.ruff.lint]
select = ["B", "C9", "D", "E", "F", "I", "S", "W"]
ignore = [
"D10", # ignore missing docstrings (for now)
"D203", # Allow One Blank Line Before Class
"D213", # Allow "Multi-line docstring summary should start at the second line"
]
mccabe.max-complexity = 13