2015-12-05 05:11:53 +08:00
|
|
|
"""
|
2016-07-24 06:51:59 +08:00
|
|
|
The setup package to install SeleniumBase dependencies and plugins
|
2019-07-14 12:53:51 +08:00
|
|
|
(Uses selenium 3.x and is compatible with Python 2.7+ and Python 3.5+)
|
2015-12-05 05:11:53 +08:00
|
|
|
"""
|
|
|
|
|
2017-03-12 06:12:50 +08:00
|
|
|
from setuptools import setup, find_packages # noqa
|
2019-09-09 22:05:06 +08:00
|
|
|
import os
|
|
|
|
import sys
|
2018-08-28 10:21:10 +08:00
|
|
|
|
|
|
|
|
2020-10-14 13:23:06 +08:00
|
|
|
this_dir = os.path.abspath(os.path.dirname(__file__))
|
2018-08-28 10:21:10 +08:00
|
|
|
long_description = None
|
2020-05-18 13:21:24 +08:00
|
|
|
total_description = None
|
2018-08-28 10:21:10 +08:00
|
|
|
try:
|
2020-10-14 13:23:06 +08:00
|
|
|
with open(os.path.join(this_dir, 'README.md'), 'rb') as f:
|
2020-05-18 13:21:24 +08:00
|
|
|
total_description = f.read().decode('utf-8')
|
|
|
|
description_lines = total_description.split('\n')
|
|
|
|
long_description_lines = []
|
|
|
|
for line in description_lines:
|
|
|
|
if not line.startswith("<meta ") and not line.startswith("<link "):
|
|
|
|
long_description_lines.append(line)
|
|
|
|
long_description = "\n".join(long_description_lines)
|
2018-08-28 10:21:10 +08:00
|
|
|
except IOError:
|
2020-10-22 21:35:39 +08:00
|
|
|
long_description = 'The complete web automation library.'
|
2020-10-14 13:23:06 +08:00
|
|
|
about = {}
|
|
|
|
# Get the package version from the seleniumbase/__version__.py file
|
|
|
|
with open(os.path.join(
|
|
|
|
this_dir, 'seleniumbase', '__version__.py'), 'rb') as f:
|
|
|
|
exec(f.read().decode('utf-8'), about)
|
2015-12-05 05:11:53 +08:00
|
|
|
|
2019-09-09 22:05:06 +08:00
|
|
|
if sys.argv[-1] == 'publish':
|
|
|
|
reply = None
|
|
|
|
input_method = input
|
|
|
|
if not sys.version_info[0] >= 3:
|
|
|
|
input_method = raw_input # noqa
|
|
|
|
reply = str(input_method(
|
|
|
|
'>>> Confirm release PUBLISH to PyPI? (yes/no): ')).lower().strip()
|
|
|
|
if reply == 'yes':
|
|
|
|
print("\n*** Checking code health with flake8:\n")
|
|
|
|
flake8_status = os.system("flake8 --exclude=temp")
|
|
|
|
if flake8_status != 0:
|
|
|
|
print("\nWARNING! Fix flake8 issues before publishing to PyPI!\n")
|
|
|
|
sys.exit()
|
|
|
|
else:
|
|
|
|
print("*** No flake8 issues detected. Continuing...")
|
|
|
|
print("\n*** Rebuilding distribution packages: ***\n")
|
|
|
|
os.system('rm -f dist/*.egg; rm -f dist/*.tar.gz; rm -f dist/*.whl')
|
|
|
|
os.system('python setup.py sdist bdist_wheel') # Create new tar/wheel
|
|
|
|
print("\n*** Installing twine: *** (Required for PyPI uploads)\n")
|
2020-07-20 02:19:05 +08:00
|
|
|
os.system("python -m pip install --upgrade 'twine>=1.15.0'")
|
2020-05-03 10:47:59 +08:00
|
|
|
print("\n*** Installing tqdm: *** (Required for PyPI uploads)\n")
|
2020-11-18 08:17:58 +08:00
|
|
|
os.system("python -m pip install --upgrade 'tqdm>=4.52.0'")
|
2019-09-09 22:05:06 +08:00
|
|
|
print("\n*** Publishing The Release to PyPI: ***\n")
|
|
|
|
os.system('python -m twine upload dist/*') # Requires ~/.pypirc Keys
|
|
|
|
print("\n*** The Release was PUBLISHED SUCCESSFULLY to PyPI! :) ***\n")
|
|
|
|
else:
|
|
|
|
print("\n>>> The Release was NOT PUBLISHED to PyPI! <<<\n")
|
|
|
|
sys.exit()
|
|
|
|
|
2015-12-05 05:11:53 +08:00
|
|
|
setup(
|
|
|
|
name='seleniumbase',
|
2020-10-14 13:23:06 +08:00
|
|
|
version=about['__version__'],
|
2020-10-22 21:35:39 +08:00
|
|
|
description='The complete web automation library for end-to-end testing.',
|
2018-08-28 10:21:10 +08:00
|
|
|
long_description=long_description,
|
2018-08-28 10:40:27 +08:00
|
|
|
long_description_content_type='text/markdown',
|
2018-08-28 06:36:52 +08:00
|
|
|
url='https://github.com/seleniumbase/SeleniumBase',
|
2020-05-03 10:30:18 +08:00
|
|
|
platforms=["Windows", "Linux", "Mac OS-X"],
|
2015-12-05 05:11:53 +08:00
|
|
|
author='Michael Mintz',
|
2017-07-19 14:12:17 +08:00
|
|
|
author_email='mdmintz@gmail.com',
|
2015-12-05 05:11:53 +08:00
|
|
|
maintainer='Michael Mintz',
|
2018-08-28 06:36:52 +08:00
|
|
|
license="MIT",
|
|
|
|
classifiers=[
|
|
|
|
"Development Status :: 5 - Production/Stable",
|
2020-10-14 13:24:16 +08:00
|
|
|
"Environment :: Console",
|
|
|
|
"Environment :: MacOS X",
|
|
|
|
"Environment :: Win32 (MS Windows)",
|
|
|
|
"Environment :: Web Environment",
|
2020-05-03 10:30:18 +08:00
|
|
|
"Framework :: Pytest",
|
2019-06-26 15:31:45 +08:00
|
|
|
"Intended Audience :: Developers",
|
|
|
|
"Intended Audience :: Information Technology",
|
2020-05-03 10:30:18 +08:00
|
|
|
"License :: OSI Approved :: MIT License",
|
|
|
|
"Operating System :: MacOS :: MacOS X",
|
2018-08-28 06:36:52 +08:00
|
|
|
"Operating System :: Microsoft :: Windows",
|
2020-05-03 10:30:18 +08:00
|
|
|
"Operating System :: POSIX :: Linux",
|
2018-08-28 06:36:52 +08:00
|
|
|
"Programming Language :: Python",
|
2020-09-24 00:53:38 +08:00
|
|
|
"Programming Language :: Python :: 3",
|
2018-08-28 06:36:52 +08:00
|
|
|
"Programming Language :: Python :: 2.7",
|
|
|
|
"Programming Language :: Python :: 3.5",
|
|
|
|
"Programming Language :: Python :: 3.6",
|
|
|
|
"Programming Language :: Python :: 3.7",
|
2019-10-04 13:14:37 +08:00
|
|
|
"Programming Language :: Python :: 3.8",
|
2020-09-24 00:53:38 +08:00
|
|
|
"Programming Language :: Python :: 3.9",
|
2020-05-03 10:30:18 +08:00
|
|
|
"Topic :: Internet",
|
|
|
|
"Topic :: Scientific/Engineering",
|
|
|
|
"Topic :: Software Development",
|
|
|
|
"Topic :: Software Development :: Quality Assurance",
|
|
|
|
"Topic :: Software Development :: Libraries",
|
|
|
|
"Topic :: Software Development :: Testing",
|
|
|
|
"Topic :: Software Development :: Testing :: Acceptance",
|
|
|
|
"Topic :: Software Development :: Testing :: Traffic Generation",
|
|
|
|
"Topic :: Utilities",
|
2018-08-28 06:36:52 +08:00
|
|
|
],
|
2020-10-14 13:26:30 +08:00
|
|
|
python_requires='>=2.7, !=3.0.*, !=3.1.*, !=3.2.*, !=3.3.*, !=3.4.*',
|
2015-12-05 07:34:48 +08:00
|
|
|
install_requires=[
|
2020-10-22 21:37:10 +08:00
|
|
|
'pip>=20.2.4',
|
2020-05-23 05:05:56 +08:00
|
|
|
'packaging>=20.4',
|
2020-06-16 10:18:45 +08:00
|
|
|
'setuptools>=44.1.1;python_version<"3.5"',
|
2020-10-22 21:37:10 +08:00
|
|
|
'setuptools>=50.3.2;python_version>="3.5"',
|
2019-10-15 12:30:38 +08:00
|
|
|
'setuptools-scm',
|
2020-08-15 08:31:26 +08:00
|
|
|
'wheel>=0.35.1',
|
2020-11-12 13:55:20 +08:00
|
|
|
'attrs>=20.3.0',
|
|
|
|
'certifi>=2020.11.8',
|
2018-10-19 07:00:46 +08:00
|
|
|
'six',
|
|
|
|
'nose',
|
|
|
|
'ipdb',
|
2020-07-26 23:28:23 +08:00
|
|
|
'parso==0.7.1', # The last version for Python 2 and 3.5
|
2020-07-20 02:19:28 +08:00
|
|
|
'jedi==0.17.2', # The last version for Python 2 and 3.5
|
2020-06-29 11:42:50 +08:00
|
|
|
'idna==2.10', # Must stay in sync with "requests"
|
2019-05-09 13:58:48 +08:00
|
|
|
'chardet==3.0.4', # Must stay in sync with "requests"
|
2020-11-14 06:55:02 +08:00
|
|
|
'urllib3==1.26.2', # Must stay in sync with "requests"
|
2020-11-12 13:55:20 +08:00
|
|
|
'requests==2.25.0',
|
2019-05-09 13:58:48 +08:00
|
|
|
'selenium==3.141.0',
|
2020-08-09 01:30:25 +08:00
|
|
|
'msedge-selenium-tools==3.141.2',
|
2020-08-30 09:38:36 +08:00
|
|
|
'more-itertools==5.0.0;python_version<"3.5"',
|
2020-10-31 02:06:39 +08:00
|
|
|
'more-itertools==8.6.0;python_version>="3.5"',
|
2020-09-05 10:37:48 +08:00
|
|
|
'cssselect==1.1.0',
|
2020-03-18 11:42:55 +08:00
|
|
|
'pluggy==0.13.1',
|
2020-07-30 22:55:37 +08:00
|
|
|
'py==1.8.1;python_version<"3.5"',
|
|
|
|
'py==1.9.0;python_version>="3.5"',
|
2020-06-08 10:30:44 +08:00
|
|
|
'pytest==4.6.11;python_version<"3.5"',
|
2020-10-31 02:06:39 +08:00
|
|
|
'pytest==6.1.2;python_version>="3.5"',
|
2020-08-15 08:31:26 +08:00
|
|
|
'pytest-cov==2.10.1',
|
2020-07-28 14:54:49 +08:00
|
|
|
'pytest-forked==1.3.0',
|
2019-11-29 13:38:05 +08:00
|
|
|
'pytest-html==1.22.1;python_version<"3.6"',
|
2020-03-15 07:54:17 +08:00
|
|
|
'pytest-html==2.0.1;python_version>="3.6"',
|
2020-05-08 00:39:00 +08:00
|
|
|
'pytest-metadata==1.8.0;python_version<"3.6"',
|
2020-06-26 06:12:09 +08:00
|
|
|
'pytest-metadata==1.10.0;python_version>="3.6"',
|
2020-03-15 07:34:51 +08:00
|
|
|
'pytest-ordering==0.6',
|
2020-08-27 06:03:46 +08:00
|
|
|
'pytest-rerunfailures==8.0;python_version<"3.5"',
|
2020-09-30 07:46:55 +08:00
|
|
|
'pytest-rerunfailures==9.1.1;python_version>="3.5"',
|
2020-08-15 08:31:26 +08:00
|
|
|
'pytest-xdist==1.34.0;python_version<"3.5"',
|
2020-08-26 12:33:17 +08:00
|
|
|
'pytest-xdist==2.1.0;python_version>="3.5"',
|
2020-04-15 12:33:51 +08:00
|
|
|
'parameterized==0.7.4',
|
2020-05-18 11:48:23 +08:00
|
|
|
'soupsieve==1.9.6;python_version<"3.5"',
|
|
|
|
'soupsieve==2.0.1;python_version>="3.5"',
|
2020-10-05 09:40:00 +08:00
|
|
|
'beautifulsoup4==4.9.3',
|
2020-08-28 13:33:52 +08:00
|
|
|
'cryptography==3.0;python_version<"3.6"',
|
2020-10-31 02:06:39 +08:00
|
|
|
'cryptography==3.2.1;python_version>="3.6"',
|
2019-12-07 14:53:46 +08:00
|
|
|
'pyopenssl==19.1.0',
|
2020-03-15 07:34:51 +08:00
|
|
|
'pygments==2.5.2;python_version<"3.5"',
|
2020-10-27 09:56:30 +08:00
|
|
|
'pygments==2.7.2;python_version>="3.5"',
|
2020-09-01 02:09:09 +08:00
|
|
|
'traitlets==4.3.3;python_version<"3.7"',
|
2020-10-22 21:37:10 +08:00
|
|
|
'traitlets==5.0.5;python_version>="3.7"',
|
2020-08-05 09:27:50 +08:00
|
|
|
'ipython==5.10.0;python_version<"3.5"',
|
2020-09-01 03:03:00 +08:00
|
|
|
'prompt-toolkit==1.0.18;python_version<"3.6"',
|
2020-10-14 13:37:55 +08:00
|
|
|
'prompt-toolkit==3.0.8;python_version>="3.6"',
|
2020-09-01 02:09:09 +08:00
|
|
|
'ipython==6.5.0;python_version>="3.5" and python_version<"3.6"',
|
|
|
|
'ipython==7.16.1;python_version>="3.6" and python_version<"3.7"',
|
2020-10-31 05:56:29 +08:00
|
|
|
'ipython==7.19.0;python_version>="3.7"',
|
2020-10-14 13:37:55 +08:00
|
|
|
'colorama==0.4.4',
|
2020-10-02 15:43:13 +08:00
|
|
|
'pathlib2==2.3.5;python_version<"3.5"', # Sync with "virtualenv"
|
|
|
|
'importlib-metadata==2.0.0', # Sync with "virtualenv"
|
2020-10-27 09:56:30 +08:00
|
|
|
'virtualenv>=20.1.0', # Sync with importlib-metadata and pathlib2
|
2020-09-11 02:58:24 +08:00
|
|
|
'pymysql==0.10.1',
|
2020-09-16 05:18:43 +08:00
|
|
|
'coverage==5.3',
|
2020-10-07 01:02:59 +08:00
|
|
|
'brython==3.9.0',
|
2020-10-22 21:37:10 +08:00
|
|
|
'pyotp==2.4.1',
|
2019-12-07 14:53:46 +08:00
|
|
|
'boto==2.49.0',
|
2020-09-22 22:26:53 +08:00
|
|
|
'cffi==1.14.3',
|
2020-11-12 13:55:20 +08:00
|
|
|
'toml==0.10.2',
|
|
|
|
'rich==9.2.0;python_version>="3.6" and python_version<"4.0"',
|
2020-09-24 00:51:36 +08:00
|
|
|
'zipp==1.2.0;python_version<"3.6"',
|
2020-10-27 09:56:30 +08:00
|
|
|
'zipp==3.4.0;python_version>="3.6"',
|
2020-05-15 16:05:47 +08:00
|
|
|
'flake8==3.7.9;python_version<"3.5"',
|
2020-10-05 09:40:00 +08:00
|
|
|
'flake8==3.8.4;python_version>="3.5"',
|
2020-05-15 16:05:47 +08:00
|
|
|
'pyflakes==2.1.1;python_version<"3.5"',
|
|
|
|
'pyflakes==2.2.0;python_version>="3.5"',
|
2020-10-31 05:56:29 +08:00
|
|
|
'tornado==5.1.1;python_version<"3.5"',
|
|
|
|
'tornado==6.1;python_version>="3.5"',
|
2020-10-31 02:06:39 +08:00
|
|
|
'allure-pytest==2.8.19',
|
2020-01-05 07:57:49 +08:00
|
|
|
'pdfminer.six==20191110;python_version<"3.5"',
|
2020-10-22 21:37:10 +08:00
|
|
|
'pdfminer.six==20201018;python_version>="3.5"',
|
2018-08-30 13:57:40 +08:00
|
|
|
],
|
|
|
|
packages=[
|
|
|
|
'seleniumbase',
|
|
|
|
'seleniumbase.common',
|
|
|
|
'seleniumbase.config',
|
|
|
|
'seleniumbase.console_scripts',
|
|
|
|
'seleniumbase.core',
|
|
|
|
'seleniumbase.drivers',
|
2019-03-19 12:55:27 +08:00
|
|
|
'seleniumbase.extensions',
|
2018-08-30 13:57:40 +08:00
|
|
|
'seleniumbase.fixtures',
|
|
|
|
'seleniumbase.masterqa',
|
|
|
|
'seleniumbase.plugins',
|
2020-03-16 12:41:24 +08:00
|
|
|
'seleniumbase.translate',
|
2018-08-30 13:57:40 +08:00
|
|
|
'seleniumbase.utilities',
|
|
|
|
'seleniumbase.utilities.selenium_grid',
|
|
|
|
'seleniumbase.utilities.selenium_ide',
|
2019-07-30 14:53:38 +08:00
|
|
|
'seleniumbase.virtual_display',
|
2018-08-30 13:57:40 +08:00
|
|
|
],
|
2019-03-19 12:55:27 +08:00
|
|
|
include_package_data=True,
|
2015-12-05 05:11:53 +08:00
|
|
|
entry_points={
|
2018-07-25 14:15:12 +08:00
|
|
|
'console_scripts': [
|
2018-08-14 13:58:59 +08:00
|
|
|
'seleniumbase = seleniumbase.console_scripts.run:main',
|
2020-05-25 16:18:49 +08:00
|
|
|
'sbase = seleniumbase.console_scripts.run:main', # Simplified name
|
2018-07-25 14:15:12 +08:00
|
|
|
],
|
2015-12-05 05:11:53 +08:00
|
|
|
'nose.plugins': [
|
|
|
|
'base_plugin = seleniumbase.plugins.base_plugin:Base',
|
|
|
|
'selenium = seleniumbase.plugins.selenium_plugin:SeleniumBrowser',
|
|
|
|
'page_source = seleniumbase.plugins.page_source:PageSource',
|
|
|
|
'screen_shots = seleniumbase.plugins.screen_shots:ScreenShots',
|
|
|
|
'test_info = seleniumbase.plugins.basic_test_info:BasicTestInfo',
|
2015-12-09 05:33:44 +08:00
|
|
|
('db_reporting = '
|
|
|
|
'seleniumbase.plugins.db_reporting_plugin:DBReporting'),
|
2015-12-05 05:11:53 +08:00
|
|
|
's3_logging = seleniumbase.plugins.s3_logging_plugin:S3Logging',
|
2018-08-30 13:57:40 +08:00
|
|
|
],
|
2017-04-27 22:35:33 +08:00
|
|
|
'pytest11': ['seleniumbase = seleniumbase.plugins.pytest_plugin']
|
2018-08-30 13:57:40 +08:00
|
|
|
}
|
|
|
|
)
|
2017-03-12 06:12:50 +08:00
|
|
|
|
2018-03-20 04:55:06 +08:00
|
|
|
# print(os.system("cat seleniumbase.egg-info/PKG-INFO"))
|
2017-03-12 06:12:50 +08:00
|
|
|
print("\n*** SeleniumBase Installation Complete! ***\n")
|