E570 Use new Nox (#6175) · googleapis/google-cloud-python@e3a38c2 · GitHub
[go: up one dir, main page]

Skip to content

Commit e3a38c2

Browse files
busunkim96theacodes
authored andcommitted
Use new Nox (#6175)
1 parent af35f5e commit e3a38c2

File tree

1 file changed

+5
-19
lines changed

1 file changed

+5
-19
lines changed

packages/google-cloud-texttospeech/nox.py renamed to packages/google-cloud-texttospeech/noxfile.py

Lines changed: 5 additions & 19 deletions
Original file line numberDiff line numberDiff line change
@@ -17,36 +17,22 @@
1717

1818
import nox
1919

20-
21-
@nox.session
2220
def default(session):
23-
return unit(session, 'default')
24-
25-
26-
@nox.session
27-
@nox.parametrize('py', ['2.7', '3.5', '3.6', '3.7'])
28-
def unit(session, py):
29-
"""Run the unit test suite."""
30-
31-
# Run unit tests against all supported versions of Python.
32-
if py != 'default':
33-
session.interpreter = 'python{}'.format(py)
34-
35-
# Set the virtualenv directory name.
36-
session.virtualenv_dirname = 'unit-' + py
37-
3821
# Install all test dependencies, then install this package in-place.
3922
session.install('pytest')
4023
session.install('-e', '.')
4124

4225
# Run py.test against the unit tests.
4326
session.run('py.test', '--quiet', os.path.join('tests', 'unit'))
4427

28+
@nox.session(python=['2.7', '3.5', '3.6', '3.7'])
29+
def unit(session):
30+
"""Run the unit test suite."""
31+
default(session)
4532

46-
@nox.session
33+
@nox.session(python='3.6')
4734
def lint_setup_py(session):
4835
"""Verify that setup.py is valid (including RST check)."""
49-
session.interpreter = 'python3.6'
5036
session.install('docutils', 'pygments')
5137
session.run('python', 'setup.py', 'check', '--restructuredtext',
5238
'--strict')

0 commit comments

Comments
 (0)
0