Fix gate-watcher-python27-ubuntu-xenial FAILURE

There is no exc.HTTPUnauthorized in monascaclient now.

Change-Id: I1942b32d4581d1770819aa083a640f394c17d25a
Closes-Bug: #1706858
This commit is contained in:
licanwei 2017-07-27 15:20:51 +08:00
parent 67754102c8
commit 5817f6833c
1 changed files with 1 additions and 3 deletions

View File

@ -15,7 +15,6 @@
# limitations under the License.
import mock
from monascaclient import exc
from oslo_config import cfg
from oslo_utils import timeutils
@ -94,8 +93,7 @@ class TestMonascaHelper(base.BaseTestCase):
['2016-07-29T12:55:36.000Z', 0.8, {}]],
'name': 'cpu.percent'}]
monasca.metrics.list_measurements.side_effect = [
exc.HTTPUnauthorized, expected_result]
monasca.metrics.list_measurements.side_effect = [expected_result]
mock_monasca.return_value = monasca
helper = monasca_helper.MonascaHelper()
val = helper.statistics_list(meter_name="cpu.percent", dimensions={})