Added Testing coverage to the client
parent
1265b2e20b
commit
b6e2a91ea2
@ -0,0 +1,3 @@
|
||||
[run]
|
||||
source = apitesting
|
||||
omit = test*
|
@ -1,3 +1,13 @@
|
||||
# apitesting
|
||||
|
||||
A sample project illustrating how to write tests against an external API
|
||||
|
||||
## Testing
|
||||
|
||||
To run the test suite with coverage first install the package in editable mode with it's testing requirements:
|
||||
|
||||
`pip install -e ".[testing]"`
|
||||
|
||||
To run the project's tests
|
||||
|
||||
`pytest --cov`
|
@ -0,0 +1,39 @@
|
||||
import os
|
||||
|
||||
from setuptools import setup, find_packages
|
||||
|
||||
here = os.path.abspath(os.path.dirname(__file__))
|
||||
with open(os.path.join(here, 'README.md')) as f:
|
||||
README = f.read()
|
||||
with open(os.path.join(here, 'CHANGES.txt')) as f:
|
||||
CHANGES = f.read()
|
||||
|
||||
requires = [
|
||||
'requests'
|
||||
]
|
||||
|
||||
tests_require = [
|
||||
'pytest',
|
||||
'pytest-cov',
|
||||
]
|
||||
|
||||
setup(
|
||||
name='apitesting',
|
||||
version='0.0',
|
||||
description='A toy API client with tests',
|
||||
long_description=README + '\n\n' + CHANGES,
|
||||
classifiers=[
|
||||
'Programming Language :: Python'
|
||||
],
|
||||
author='Androiddrew',
|
||||
author_email='drew@androiddrew.com',
|
||||
url='https://blog.androiddrew.com',
|
||||
keywords='API client testing',
|
||||
packages=find_packages(),
|
||||
include_package_data=True,
|
||||
zip_safe=False,
|
||||
extras_require={
|
||||
'testing': tests_require,
|
||||
},
|
||||
install_requires=requires,
|
||||
)
|
Loading…
Reference in New Issue