def test_small_system_EXAFS(self): exafs_settings = MPEXAFSSet(self.absorbing_atom, self.structure) self.assertFalse(exafs_settings.small_system) self.assertTrue('RECIPROCAL' not in exafs_settings.tags) user_tag_settings = {"RECIPROCAL": ""} exafs_settings_2 = MPEXAFSSet(self.absorbing_atom, self.structure, nkpts=1000, user_tag_settings=user_tag_settings) self.assertFalse(exafs_settings_2.small_system) self.assertTrue('RECIPROCAL' not in exafs_settings_2.tags)
def test_write_paths_task(self): exafs = MPEXAFSSet(0, self.struct, edge="K", radius=10) t = WriteEXAFSPaths(feff_input_set=exafs, paths=[[249, 0], [85, 0]]) paths = Paths(exafs.atoms, [[249, 0], [85, 0]]) paths.write_file("paths_ans.dat") t.run_task({}) with open("paths_ans.dat") as ans, open("paths.dat") as tmp: self.assertEqual(ans.readlines(), tmp.readlines())