Skip to content

Commit

Permalink
Add dlp to CI
Browse files Browse the repository at this point in the history
  • Loading branch information
landrito committed Aug 22, 2017
1 parent 66ad48c commit 5166f26
Show file tree
Hide file tree
Showing 2 changed files with 12 additions and 1 deletion.
6 changes: 6 additions & 0 deletions .circleci/config.yml
Original file line number Diff line number Diff line change
Expand Up @@ -55,6 +55,12 @@ jobs:
if [[ -n $(grep datastore ~/target_packages) ]]; then
nox -f datastore/nox.py
fi
- run:
name: Run tests - google.cloud.dlp
command: |
if [[ -n $(grep dlp ~/target_packages) ]]; then
nox -f dlp/nox.py
fi
- run:
name: Run tests - google.cloud.dns
command: |
Expand Down
7 changes: 6 additions & 1 deletion dlp/nox.py
Original file line number Diff line number Diff line change
Expand Up @@ -15,6 +15,7 @@
from __future__ import absolute_import

import nox
import os


@nox.session
Expand All @@ -25,12 +26,16 @@ def unit_tests(session, python_version):
# Run unit tests against all supported versions of Python.
session.interpreter = 'python{}'.format(python_version)

# Set the virtualenv dirname.
session.virtualenv_dirname = 'unit-' + python_version

# Install all test dependencies, then install this package in-place.
session.install('mock', 'pytest', 'pytest-cov')
session.install('-e', '.')

# Run py.test against the unit tests.
session.run('py.test', '--quiet', 'tests/')
session.run('py.test', '--quiet', 'tests/unit/')


@nox.session
def lint_setup_py(session):
Expand Down

0 comments on commit 5166f26

Please sign in to comment.