Example #1
0
 def test_obtain_all_bond_lengths(self):
     self.assertDictEqual(obtain_all_bond_lengths('C', 'C'),
                          {1.0: 1.54, 2.0: 1.34, 3.0: 1.2})
     self.assertRaises(ValueError, obtain_all_bond_lengths,
                       'Br', Element('C'))
     self.assertDictEqual(obtain_all_bond_lengths(
         'C', Element('Br'), 1.76), {1: 1.76})
     bond_lengths_dict = obtain_all_bond_lengths('C', 'N')
     bond_lengths_dict[4] = 999
     self.assertDictEqual(obtain_all_bond_lengths('C', 'N'),
                          {1.0: 1.47, 2.0: 1.3, 3.0: 1.16})
Example #2
0
 def test_obtain_all_bond_lengths(self):
     self.assertDictEqual(
         obtain_all_bond_lengths("C", "C"), {1.0: 1.54, 2.0: 1.34, 3.0: 1.2}
     )
     self.assertRaises(ValueError, obtain_all_bond_lengths, "Br", Element("C"))
     self.assertDictEqual(
         obtain_all_bond_lengths("C", Element("Br"), 1.76), {1: 1.76}
     )
     bond_lengths_dict = obtain_all_bond_lengths("C", "N")
     bond_lengths_dict[4] = 999
     self.assertDictEqual(
         obtain_all_bond_lengths("C", "N"), {1.0: 1.47, 2.0: 1.3, 3.0: 1.16}
     )
Example #3
0
 def test_obtain_all_bond_lengths(self):
     self.assertDictEqual(obtain_all_bond_lengths('C', 'C'), {
         1.0: 1.54,
         2.0: 1.34,
         3.0: 1.2
     })
     self.assertRaises(ValueError, obtain_all_bond_lengths, 'Br',
                       Element('C'))
     self.assertDictEqual(obtain_all_bond_lengths('C', Element('Br'), 1.76),
                          {1: 1.76})
     bond_lengths_dict = obtain_all_bond_lengths('C', 'N')
     bond_lengths_dict[4] = 999
     self.assertDictEqual(obtain_all_bond_lengths('C', 'N'), {
         1.0: 1.47,
         2.0: 1.3,
         3.0: 1.16
     })