def test_create_outputvariabledictionary(self): pyidf.validation_level = ValidationLevel.error obj = OutputVariableDictionary() # alpha var_key_field = "IDF" obj.key_field = var_key_field # alpha var_sort_option = "Name" obj.sort_option = var_sort_option idf = IDF() idf.add(obj) idf.save(self.path, check=False) with open(self.path, mode='r') as f: for line in f: log.debug(line.strip()) idf2 = IDF(self.path) self.assertEqual(idf2.outputvariabledictionarys[0].key_field, var_key_field) self.assertEqual(idf2.outputvariabledictionarys[0].sort_option, var_sort_option)
obj43 = OutputVariable() obj43.key_value = "*" obj43.variable_name = "Zone Air Temperature" obj43.reporting_frequency = "Hourly" idf.add(obj43) obj44 = OutputMeter() obj44.name = "DistrictHeating:Facility" obj44.reporting_frequency = "Hourly" idf.add(obj44) obj45 = OutputMeter() obj45.name = "DistrictCooling:Facility" obj45.reporting_frequency = "Hourly" idf.add(obj45) obj46 = OutputSurfacesDrawing() obj46.report_type = "DXF" idf.add(obj46) obj47 = OutputConstructions() obj47.details_type_1 = "Constructions" idf.add(obj47) obj48 = OutputVariableDictionary() obj48.key_field = "Regular" idf.add(obj48) idf.save(idf_file_path)