def test_DictionaryBadIndex(self): primaryRef = "122" secondaryRef = "1" originalValue = 'This object is used to report the current value of a security statistic. See 11.9.10 for a description of a Security Statistic Point Type. See 7.5.2.2 for details of the point indexes permitted for this object and when the statistics are incremented. Variation 1 objects contain a 32-bit- unsigned integer count value. ' dictionary = TypeLookup.buildDict() testValue = dictionary[primaryRef][secondaryRef] assert testValue["description"] != originalValue
def test_DictionaryMidIndex(self): primaryRef = "0" secondaryRef = "242" originalValue = [('Attribute data type code ', 'UNIT8'), ('Length ', 'UNIT8'), ("Manufacturer's software version string. ", 'VSTRn')] dictionary = TypeLookup.buildDict() testValue = dictionary[primaryRef][secondaryRef] #print('\n\n') #print(originalValue) #print(testValue) assert testValue["attributes"] == originalValue
def test_DictionaryFirstIndex(self): primaryRef = "0" secondaryRef = "209" originalValue = 'This attribute provides the secure authentication version supported by the outstation. ' dictionary = TypeLookup.buildDict() testValue = dictionary[primaryRef][secondaryRef] #print('\n\n') #print(originalValue) #print(testValue) assert testValue["description"] == originalValue
def test_DictionaryLastIndex(self): primaryRef = "0" secondaryRef = "255" originalValue = 'This is a special attribute that is used to retrieve a list of all of the device attribute variation numbers supported by the outstation at a specified index- and the properties of those attributes. This object has a variable length that depends on the count of attribute variations supported by the outstation. ' dictionary = TypeLookup.buildDict() testValue = dictionary[primaryRef][secondaryRef] #print('\n\n') #print(originalValue) #print('\n\n') #print(testValue["description"]) assert testValue["description"] == originalValue