def setUp(cls): cls.hypervisor_json = ('{"hypervisors": [{' '"id": 1, ' '"hypervisor_hostname": "hypervisor_test", ' '"servers": [{' '"uuid": ' '"b1ea4f1b-201c-47c5-95b9-c6fe2df39af0", ' '"name": "server_one"}, ' '{"uuid": ' '"9327b134-b1f5-43ec-a8f1-2b6eb153c739", ' '"name": "server_two"}]}]}') cls.hypervisor = Hypervisor.deserialize(cls.hypervisor_json, "json")
def setUp(cls): cls.hypervisor_xml = ('<?xml version="1.0" encoding="UTF-8"?>' '<hypervisors>' '<hypervisor ' 'id="1" ' 'hypervisor_hostname="hypervisor_test">' '<servers>' '<server name="server_one" ' 'uuid="b1ea4f1b-201c-47c5-95b9-c6fe2df39af0"/>' '<server name="server_two" ' 'uuid="9327b134-b1f5-43ec-a8f1-2b6eb153c739"/>' '</servers></hypervisor></hypervisors>') cls.hypervisor = Hypervisor.deserialize(cls.hypervisor_xml, "xml")
def setUp(cls): cls.hypervisor_xml = ('<?xml version="1.0" encoding="UTF-8"?>' '<hypervisors><hypervisor id="1" ' 'hypervisor_hostname="hypervisor_test"/>' '</hypervisors>') cls.hypervisor = Hypervisor.deserialize(cls.hypervisor_xml, "xml")
def setUp(cls): cls.hypervisor_json = ('{"hypervisors": [{' '"id": "1", ' '"hypervisor_hostname": "hypervisor_test"}]}') cls.hypervisor = Hypervisor.deserialize(cls.hypervisor_json, "json")