Browse Source

Merge pull request #293 from jd/jd-tox

Use tox for testing
main
Lakshmi 9 years ago
parent
commit
ee048e7f39
3 changed files with 44 additions and 28 deletions
  1. +2
    -5
      .travis.yml
  2. +23
    -23
      setup.py
  3. +19
    -0
      tox.ini

+ 2
- 5
.travis.yml View File

@@ -16,13 +16,10 @@ install:
- sudo npm install -g sass@0.5.0 requirejs@2.1 stylus@0.51 uglify-js@2.4.23 less@2.5.1

# Python test requirements
- pip install -r dev-req.txt
- pip install tox

before_script:
- export PYTHONPATH=$PYTHONPATH:/usr/share/asciidoc/

script:
# Source code sanity check
- flake8 hyde
# Run Python tests and generate coverage statistics
- nosetests
- tox

+ 23
- 23
setup.py View File

@@ -128,13 +128,13 @@ setup(name=PROJECT,
'Jinja2==2.7.3'
),
tests_require=(
'nose==1.3.6',
'mock==1.0.1',
'pyquery==1.2.9',
'docutils==0.12',
'Pillow==2.7.0',
'pyScss==1.3.4',
'flake8==2.4.1'
'nose==1.3.6',
'mock==1.0.1',
'pyquery==1.2.9',
'docutils==0.12',
'Pillow==2.7.0',
'pyScss==1.3.4',
'flake8==2.4.1'
),
test_suite='nose.collector',
include_package_data=True,
@@ -152,21 +152,21 @@ setup(name=PROJECT,
},
license='MIT',
classifiers=[
'Development Status :: 4 - Beta',
'Environment :: Console',
'Intended Audience :: End Users/Desktop',
'Intended Audience :: Developers',
'Intended Audience :: System Administrators',
'License :: OSI Approved :: MIT License',
'Operating System :: MacOS :: MacOS X',
'Operating System :: Unix',
'Operating System :: POSIX',
'Operating System :: Microsoft :: Windows',
'Programming Language :: Python',
'Topic :: Software Development',
'Topic :: Software Development :: Build Tools',
'Topic :: Software Development :: Code Generators',
'Topic :: Internet',
'Topic :: Internet :: WWW/HTTP :: Site Management',
'Development Status :: 4 - Beta',
'Environment :: Console',
'Intended Audience :: End Users/Desktop',
'Intended Audience :: Developers',
'Intended Audience :: System Administrators',
'License :: OSI Approved :: MIT License',
'Operating System :: MacOS :: MacOS X',
'Operating System :: Unix',
'Operating System :: POSIX',
'Operating System :: Microsoft :: Windows',
'Programming Language :: Python',
'Topic :: Software Development',
'Topic :: Software Development :: Build Tools',
'Topic :: Software Development :: Code Generators',
'Topic :: Internet',
'Topic :: Internet :: WWW/HTTP :: Site Management',
],
zip_safe=False,)

+ 19
- 0
tox.ini View File

@@ -0,0 +1,19 @@
[tox]
envlist = py27,pep8

[testenv]
usedevelop = True
# Needed for asciidoc
sitepackages = True
# Needed for asciidoc
passenv = PYTHONPATH
deps = -r{toxinidir}/dev-req.txt
commands = nosetests

[testenv:pep8]
deps = flake8
commands = flake8

[flake8]
exclude = .tox
show-source = true

Loading…
Cancel
Save