Skip to content

Commit

Permalink
Adding a tox and other configuration files needed in core subpackage.
Browse files Browse the repository at this point in the history
The coverage RC file for the core subpackage intentionally
leaves out google.cloud._testing. This is because the core tests
don't use the entire functionality of the _testing module, but
the umbrella package does.

By leaving the module in the google-cloud-core package, every
other package can depend on it and have the test helpers
ready to access.
  • Loading branch information
dhermes committed Sep 23, 2016
1 parent 8f9cca4 commit 9a70f16
Show file tree
Hide file tree
Showing 2 changed files with 42 additions and 0 deletions.
13 changes: 13 additions & 0 deletions core/.coveragerc
Original file line number Diff line number Diff line change
@@ -0,0 +1,13 @@
[run]
branch = True

[report]
omit =
*/google/cloud/_testing.py
fail_under = 100
show_missing = True
exclude_lines =
# Re-enable the standard pragma
pragma: NO COVER
# Ignore debug-only repr
def __repr__
29 changes: 29 additions & 0 deletions core/tox.ini
Original file line number Diff line number Diff line change
@@ -0,0 +1,29 @@
[tox]
envlist =
py27,py34,py35,cover

[testing]
deps =
pytest
covercmd =
py.test --quiet \
--cov=google.cloud \
--cov=unit_tests \
--cov-config {toxinidir}/.coveragerc \
unit_tests

[testenv]
commands =
py.test --quiet {posargs} unit_tests
deps =
{[testing]deps}

[testenv:cover]
basepython =
python2.7
commands =
{[testing]covercmd}
deps =
{[testenv]deps}
coverage
pytest-cov

0 comments on commit 9a70f16

Please sign in to comment.