Add DeprecationWarning in test environments

Many deprecations are triggered early (on imports, for example)
before the warnings are enabled by the WarningsFixture in the
base test class.
To make sure all DeprecationWarning messages are emitted we
enable them via the PYTHONWARNINGS environment variable.

This copy from 1be35ff039d67c50866f2556ef847b048cbf3578

Change-Id: Ibe67b6b57494d731b49e76c590ac2681ae786c33
This commit is contained in:
jiansong 2016-10-21 01:32:00 -07:00 committed by jian.song
parent 77fd7014c0
commit 60d3617db2
1 changed files with 1 additions and 0 deletions

View File

@ -5,6 +5,7 @@ skipsdist = True
[testenv]
setenv = VIRTUAL_ENV={envdir}
PYTHONWARNINGS=default::DeprecationWarning
usedevelop = True
install_command = pip install \
-c{env:UPPER_CONSTRAINTS_FILE:https://git.openstack.org/cgit/openstack/requirements/plain/upper-constraints.txt} \