Sync tempest code from ceilometer
* https://review.openstack.org/530891 and https://review.openstack.org/527960 are synced into telemetry-tempest-plugin Change-Id: I6e099890aa03c9bd9b0039ce1e55a182886193e7
This commit is contained in:
parent
d9a10fe680
commit
bc03a059f9
@ -7,5 +7,4 @@ oslo.config>=5.1.0 # Apache-2.0
|
||||
oslo.utils>=3.31.0 # Apache-2.0
|
||||
six>=1.10.0 # MIT
|
||||
tempest>=17.1.0 # Apache-2.0
|
||||
ujson
|
||||
gabbi>=1.30.0 # Apache-2.0
|
||||
|
@ -13,11 +13,12 @@
|
||||
# License for the specific language governing permissions and limitations
|
||||
# under the License.
|
||||
|
||||
import json
|
||||
|
||||
from six.moves.urllib import parse as urllib
|
||||
from tempest import config
|
||||
from tempest.lib.common import rest_client
|
||||
from tempest import manager
|
||||
import ujson
|
||||
|
||||
CONF = config.CONF
|
||||
|
||||
@ -28,10 +29,10 @@ class AlarmingClient(rest_client.RestClient):
|
||||
uri_prefix = "v2"
|
||||
|
||||
def deserialize(self, body):
|
||||
return ujson.loads(body.replace("\n", ""))
|
||||
return json.loads(body.replace("\n", ""))
|
||||
|
||||
def serialize(self, body):
|
||||
return ujson.dumps(body)
|
||||
return json.dumps(body)
|
||||
|
||||
def list_alarms(self, query=None):
|
||||
uri = '%s/alarms' % self.uri_prefix
|
||||
|
Loading…
Reference in New Issue
Block a user