mirror of
https://github.com/wassname/flask-security.git
synced 2026-06-27 16:10:11 +08:00
4508c717fb
- Add Python 3.5 support on travis - pytest-cache has been merged into pytest [0] and is no longer separately maintained, so pytest-cache-related requirements are being updated. - Flask-Mongoengine latest stable is broken on Python 2.6 (but fixed in master [1]), so its version is being restricted for now. [0] http://pytest.org/latest/changelog.html#id3 [1] https://github.com/MongoEngine/flask-mongoengine/pull/174
72 lines
1.8 KiB
Python
72 lines
1.8 KiB
Python
"""
|
|
Flask-Security
|
|
==============
|
|
"""
|
|
|
|
import multiprocessing # pragma: no flakes
|
|
import sys
|
|
|
|
from setuptools import setup, find_packages
|
|
from setuptools.command.test import test as TestCommand
|
|
|
|
|
|
def get_requirements(suffix=''):
|
|
with open('requirements%s.txt' % suffix) as f:
|
|
rv = f.read().splitlines()
|
|
return rv
|
|
|
|
|
|
def get_long_description():
|
|
with open('README.rst') as f:
|
|
rv = f.read()
|
|
return rv
|
|
|
|
|
|
class PyTest(TestCommand):
|
|
|
|
def finalize_options(self):
|
|
TestCommand.finalize_options(self)
|
|
self.test_args = [
|
|
'-xrs',
|
|
'--cov', 'flask_security',
|
|
'--cov-report', 'term-missing',
|
|
'--pep8',
|
|
'--flakes',
|
|
'--cache-clear'
|
|
]
|
|
self.test_suite = True
|
|
|
|
def run_tests(self):
|
|
import pytest
|
|
errno = pytest.main(self.test_args)
|
|
sys.exit(errno)
|
|
|
|
|
|
setup(
|
|
name='Flask-Security',
|
|
version='1.7.4',
|
|
url='https://github.com/mattupstate/flask-security',
|
|
license='MIT',
|
|
author='Matt Wright',
|
|
author_email='matt@nobien.net',
|
|
description='Simple security for Flask apps',
|
|
long_description=get_long_description(),
|
|
packages=find_packages(),
|
|
zip_safe=False,
|
|
include_package_data=True,
|
|
platforms='any',
|
|
install_requires=get_requirements(),
|
|
tests_require=get_requirements('-dev'),
|
|
cmdclass={'test': PyTest},
|
|
classifiers=[
|
|
'Development Status :: 4 - Beta',
|
|
'Environment :: Web Environment',
|
|
'Intended Audience :: Developers',
|
|
'License :: OSI Approved :: MIT License',
|
|
'Operating System :: OS Independent',
|
|
'Programming Language :: Python',
|
|
'Topic :: Internet :: WWW/HTTP :: Dynamic Content',
|
|
'Topic :: Software Development :: Libraries :: Python Modules'
|
|
]
|
|
)
|