Skip to content

Commit

Permalink
Add a tox env to make dists and test them
Browse files Browse the repository at this point in the history
  • Loading branch information
tkf committed May 12, 2019
1 parent bba6c6f commit 496ff53
Show file tree
Hide file tree
Showing 2 changed files with 21 additions and 4 deletions.
11 changes: 7 additions & 4 deletions .travis.yml
Original file line number Diff line number Diff line change
Expand Up @@ -30,17 +30,20 @@ notifications:
jobs:
include:

- language: python
- &check
language: python
env:
- TOXENV=style
os: linux
python: "3.7"

- language: python
- <<: *check
env:
- TOXENV=type
os: linux
python: "3.7"

- <<: *check
env:
- TOXENV=packaging

# Upload the package to `test.pypi.org` when there is a push to
# `release/test` branch:
Expand Down
14 changes: 14 additions & 0 deletions tox.ini
Original file line number Diff line number Diff line change
Expand Up @@ -36,6 +36,20 @@ source =
.tox/*/lib/python*/site-packages/tkfplaygroundpy
# https://coverage.readthedocs.io/en/coverage-4.5.1/config.html#paths

[testenv:packaging]
commands_pre =
rm -rf dist
rm -rf src/tkfplaygroundpy.egg-info
commands =
python setup.py sdist
python setup.py bdist_wheel
commands_post =
sh -c "tar tf dist/tkfplaygroundpy-*.tar.gz | grep LICENSE"
sh -c "unzip -l dist/tkfplaygroundpy-*.whl | grep LICENSE"
whitelist_externals =
rm
sh

[testenv:style]
deps =
black == 19.3b0
Expand Down

0 comments on commit 496ff53

Please sign in to comment.