def test_02_Import(self): l_obj = familyUtil()._build_one_family_data(self.m_pyhouse_obj, 'UPB') _l_mod = familyUtil()._do_import(l_obj, 'UPB_xml') # print(PrettyFormatAny.form(l_mod, 'B1-02-A - Module')) self.assertEqual(l_obj.Name, 'UPB') self.assertEqual(l_obj.Key, 0) self.assertEqual(l_obj.Active, True) self.assertEqual(l_obj.FamilyDevice_ModuleName, 'UPB_device') self.assertEqual(l_obj.FamilyPackageName, 'Modules.Families.UPB') self.assertEqual(l_obj.FamilyXml_ModuleName, 'UPB_xml')
def test_01_Import(self): """ """ l_obj = familyUtil()._build_one_family_data(self.m_pyhouse_obj, 'Insteon') print(PrettyFormatAny.form(l_obj, 'B1-01-A - Module')) _l_mod = familyUtil()._do_import(l_obj, 'Insteon_xml') self.assertEqual(l_obj.Name, 'Insteon') self.assertEqual(l_obj.Key, 0) self.assertEqual(l_obj.Active, True) self.assertEqual(l_obj.FamilyDevice_ModuleName, 'Insteon_device') self.assertEqual(l_obj.FamilyPackageName, 'Modules.Families.Insteon') self.assertEqual(l_obj.FamilyXml_ModuleName, 'Insteon_xml')
def test_06_UPB(self): l_obj = familyUtil()._build_one_family_data(self.m_pyhouse_obj, 'UPB') # print(PrettyFormatAny.form(l_obj, 'A1-06-A - UPB')) self.assertEqual(l_obj.Name, TESTING_FAMILY_NAME_2) self.assertEqual(l_obj.FamilyDevice_ModuleName, 'UPB_device') self.assertEqual(l_obj.FamilyPackageName, 'Modules.Families.UPB') self.assertEqual(l_obj.FamilyXml_ModuleName, 'UPB_xml')
def test_01_Import(self): l_mod_name = 'Insteon_device' l_mod_ref = None l_obj = familyUtil()._create_api_instance(self.m_pyhouse_obj, l_mod_name, l_mod_ref) print(PrettyFormatAny.form(l_obj, 'C2-01-A - Module')) self.assertNotEqual(l_obj, None)
def test_01_Import(self): l_family_obj = self.createFamilyObj() l_mod = 'Insteon_device' # print(PrettyFormatAny.form(l_family_obj, 'C1-01-A - Module')) l_obj = familyUtil()._do_import(l_family_obj, l_mod) # print(PrettyFormatAny.form(l_obj, 'C1-01-B - Module')) self.assertNotEqual(l_obj, None)
def test_07_X10(self): l_obj = familyUtil()._build_one_family_data(self.m_pyhouse_obj, 'X10') # print(PrettyFormatAny.form(l_obj, 'A1-07-A - X10')) self.assertEqual(l_obj.Name, TESTING_FAMILY_NAME_3) self.assertEqual(l_obj.FamilyDevice_ModuleName, 'X10_device') self.assertEqual(l_obj.FamilyPackageName, 'Modules.Families.X10') self.assertEqual(l_obj.FamilyXml_ModuleName, 'X10_xml')
def test_05_Insteon(self): l_obj = familyUtil()._build_one_family_data(self.m_pyhouse_obj, 'Insteon') # print(PrettyFormatAny.form(l_obj, 'A1-05-A- Insteon')) self.assertEqual(l_obj.Name, TESTING_FAMILY_NAME_1) self.assertEqual(l_obj.FamilyDevice_ModuleName, 'Insteon_device') self.assertEqual(l_obj.FamilyPackageName, 'Modules.Families.Insteon') self.assertEqual(l_obj.FamilyXml_ModuleName, 'Insteon_xml')
def test_02_Insteon(self): l_mod_name = 'Insteon' l_family_obj = familyUtil()._build_one_family_data( self.m_pyhouse_obj, l_mod_name) # print(PrettyFormatAny.form(l_family_obj, 'D1-02-A - Family')) self.assertEqual(l_family_obj.Name, l_mod_name)
def setUp(self): SetupMixin.setUp(self, ET.fromstring(XML_LONG)) self.m_family_obj = familyUtil()._build_one_family_data( self.m_pyhouse_obj, 'Insteon')
def test_01_Import(self): l_obj = familyUtil()._init_family_component_apis(self.m_pyhouse_obj) # print(PrettyFormatAny.form(l_obj, 'B3-01-A - Module')) self.assertNotEqual(l_obj, None)
def test_02_ImportOneMod(self): _l_module = familyUtil()._init_family_component_apis( self.m_pyhouse_obj) # print(PrettyFormatAny.form(_l_module, 'B2-02-A - Module')) pass