Skip to content

Commit

Permalink
test: add setup.py integration cases
Browse files Browse the repository at this point in the history
Signed-off-by: Alfredo Deza <[email protected]>
  • Loading branch information
Alfredo Deza committed Aug 17, 2020
1 parent 9c4024d commit 861806f
Show file tree
Hide file tree
Showing 2 changed files with 51 additions and 1 deletion.
10 changes: 9 additions & 1 deletion test/integration/pkg_cases.go
Original file line number Diff line number Diff line change
Expand Up @@ -77,13 +77,21 @@ var cases = []struct {
},
},
{
name: "find python packages",
name: "find python requirements.txt packages",
pkgType: pkg.PythonRequirementsPkg,
pkgLanguage: pkg.Python,
pkgInfo: map[string]string{
"flask": "4.0.0",
},
},
{
name: "find python setup.py packages",
pkgType: pkg.PythonSetupPkg,
pkgLanguage: pkg.Python,
pkgInfo: map[string]string{
"mypy": "v0.770",
},
},
{
name: "find bundler packages",
pkgType: pkg.BundlerPkg,
Expand Down
Original file line number Diff line number Diff line change
@@ -0,0 +1,42 @@
from setuptools import setup

# TODO: if py gets upgrade to >=1.6,
# remove _width_of_current_line in terminal.py
INSTALL_REQUIRES = [
"py>=1.5.0",
"packaging",
"attrs>=17.4.0", # should match oldattrs tox env.
"more-itertools>=4.0.0",
'atomicwrites>=1.0;sys_platform=="win32"',
'pathlib2>=2.2.0;python_version<"3.6"',
'colorama;sys_platform=="win32"',
"pluggy>=0.12,<1.0",
'importlib-metadata>=0.12;python_version<"3.8"',
"wcwidth",
]


def main():
setup(
use_scm_version={"write_to": "src/_pytest/_version.py"},
setup_requires=["setuptools-scm", "setuptools>=40.0"],
package_dir={"": "src"},
extras_require={
"testing": [
"argcomplete",
"hypothesis>=3.56",
"mock",
"nose",
"requests",
"xmlschema",
],
"checkqa-mypy": [
"mypy==v0.770", # keep this in sync with .pre-commit-config.yaml.
],
},
install_requires=INSTALL_REQUIRES,
)


if __name__ == "__main__":
main()

0 comments on commit 861806f

Please sign in to comment.