Example #1
0
 def testPermittedClustersOnly(self):
     """
     All cluster numbers must be in {1, 2, 3, 4, 5}.
     """
     for propertiesDict in PROPERTY_CLUSTERS.values():
         for clusterNr in propertiesDict.values():
             self.assertIn(clusterNr, {1, 2, 3, 4, 5})
Example #2
0
 def testPermittedClustersOnly(self):
     """
     All cluster numbers must be in {1, 2, 3, 4, 5}.
     """
     for propertiesDict in PROPERTY_CLUSTERS.values():
         for clusterNr in propertiesDict.values():
             self.assertIn(clusterNr, {1, 2, 3, 4, 5})
Example #3
0
 def testNumberOfValues(self):
     """
     Each key in PROPERTY_CLUSTERS must have a dict with 10 elements in it
     as the value.
     """
     for propertyNames in PROPERTY_CLUSTERS.values():
         self.assertEqual([
             'aliphaticity', 'aromaticity', 'composition', 'hydrogenation',
             'hydropathy', 'hydroxythiolation', 'iep', 'polar requirement',
             'polarity', 'volume'
         ], sorted(propertyNames.keys()))
Example #4
0
 def testNumberOfValues(self):
     """
     Each key in PROPERTY_CLUSTERS must have a dict with 10 elements in it
     as the value.
     """
     for propertyNames in PROPERTY_CLUSTERS.values():
         self.assertEqual([
             'aliphaticity', 'aromaticity', 'composition',
             'hydrogenation', 'hydropathy', 'hydroxythiolation',
             'iep', 'polar requirement', 'polarity', 'volume'],
             sorted(propertyNames.keys()))
Example #5
0
 def testAliphaticity(self):
     """
     Aliphaticity must always be in cluster 1.
     """
     for propertiesDict in PROPERTY_CLUSTERS.values():
         self.assertEqual(1, propertiesDict['aliphaticity'])
Example #6
0
 def testPropertyClusterKeys(self):
     """
     The PROPERTY_CLUSTERS dict must contain the right keys.
     """
     self.assertEqual(AA_LETTERS, sorted(PROPERTY_CLUSTERS.keys()))
Example #7
0
 def testAliphaticity(self):
     """
     Aliphaticity must always be in cluster 1.
     """
     for propertiesDict in PROPERTY_CLUSTERS.values():
         self.assertEqual(1, propertiesDict['aliphaticity'])
Example #8
0
 def testPropertyClusterKeys(self):
     """
     The PROPERTY_CLUSTERS dict must contain the right keys.
     """
     self.assertEqual(AA_LETTERS, sorted(PROPERTY_CLUSTERS.keys()))