def test_fraccoords(self): '''Fractional coordinates''' infile = self.get_input('gaas-frac.gen') reffile = self.get_input('gaas-frac.cif') outfile = self.get_output('gaas-frac.cif') cmdargs = ['-o', outfile, infile] gen2cif.main(cmdargs) self.assertTrue(common.cif_file_equals(outfile, reffile))
def test_customcell(self): '''Absolute coordinates with custom size cubic cell''' infile = self.get_input('h2o.234.gen') reffile = self.get_input('h2o.234-customcell.cif') outfile = self.get_output('h2o.234-customcell.cif') cmdargs = ['-o', outfile, '-c', '10', infile] gen2cif.main(cmdargs) self.assertTrue(common.cif_file_equals(outfile, reffile))
def test_periodic(self): '''Absolute coordinates with periodic geometry''' infile = self.get_input('h2o.gen') reffile = self.get_input('h2o.cif') outfile = self.get_output('h2o.cif') cmdargs = ['-o', outfile, infile] gen2cif.main(cmdargs) self.assertTrue(common.cif_file_equals(outfile, reffile))
def test_cluster(self): '''Absolute coordinates with a default size cubic cell''' infile = self.get_input('h2o.234.gen') reffile = self.get_input('h2o.234.cif') outfile = self.get_output('h2o.234.cif') cmdargs = ['-o', outfile, infile] gen2cif.main(cmdargs) self.assertTrue(common.cif_file_equals(outfile, reffile))