Skip to content

Commit

Permalink
Merge ddbff09 into 10c26d8
Browse files Browse the repository at this point in the history
  • Loading branch information
chengs committed Oct 18, 2018
2 parents 10c26d8 + ddbff09 commit f89c97c
Show file tree
Hide file tree
Showing 4 changed files with 430 additions and 3 deletions.
4 changes: 4 additions & 0 deletions .travis.yml
Expand Up @@ -23,6 +23,10 @@ matrix:
env: TOXENV=flake8
- python: 2.7
env: TOXENV=perf
- python: 2.7
env: TOXENV=notebook27
- python: 3.6
env: TOXENV=notebook36
# use cache for big builds like pandas (to minimise build time).
# If issues, clear cache
# https://docs.travis-ci.com/user/caching/#Clearing-Caches
Expand Down
29 changes: 28 additions & 1 deletion tox.ini
Expand Up @@ -5,7 +5,7 @@

[tox]
# deprecation warning: py{26,32,33,34}
envlist = py{26,27,33,34,35,36,37,py,py3}, flake8, setup.py, perf
envlist = py{26,27,33,34,35,36,37,py,py3}, flake8, setup.py, perf, notebook{27,36}

[coverage]
deps =
Expand Down Expand Up @@ -86,3 +86,30 @@ deps =
commands =
python setup.py check --restructuredtext --metadata --strict
python setup.py make none

[testenv:notebook27]
passenv = CI TRAVIS TRAVIS_*
deps =
ipython<6
jupyter
pytest
nbval
pytest-cov
codecov
commands =
pytest --cov=tqdm --nbval --current-env ./tqdm/tests/tests_notebook.ipynb
codecov

[testenv:notebook36]
passenv = CI TRAVIS TRAVIS_*
deps =
ipython
jupyter
pytest
nbval
pytest-cov
codecov
commands =
pytest --cov=tqdm --nbval ./tqdm/tests/tests_notebook.ipynb
codecov

4 changes: 2 additions & 2 deletions tqdm/_tqdm_notebook.py
Expand Up @@ -105,7 +105,7 @@ def status_printer(_, total=None, desc=None, ncols=None):
pbar = IntProgress(min=0, max=1)
pbar.value = 1
pbar.bar_style = 'info'
except NameError:
except NameError: # pragma: no cover
# #187 #451 #558
raise ImportError(
"IntProgress not found. Please update jupyter and ipywidgets."
Expand Down Expand Up @@ -174,7 +174,7 @@ def print_status(s='', close=False, bar_style=None, desc=None):
if close and pbar.bar_style != 'danger': # hide only if no error
try:
container.close()
except AttributeError:
except AttributeError: # pragma: no cover
container.visible = False

# Update description
Expand Down

0 comments on commit f89c97c

Please sign in to comment.