Exemplo n.º 1
0
    def test_single_name(self):
        u = make_Universe(trajectory=True)

        w = XYZWriter(self.outfile, atoms='ABC')
        w.write(u.trajectory.ts)
        w.close()

        u2 = mda.Universe(self.outfile)
        assert_(all(u2.atoms.names == 'ABC'))
Exemplo n.º 2
0
    def test_no_names(self, outfile):
        u = make_Universe(trajectory=True)

        w = XYZWriter(outfile)
        w.write(u.trajectory.ts)
        w.close()

        u2 = mda.Universe(outfile)
        assert all(u2.atoms.names == 'X')
Exemplo n.º 3
0
    def test_single_name(self):
        u = make_Universe(trajectory=True)

        w = XYZWriter(self.outfile, atoms='ABC')
        w.write(u.trajectory.ts)
        w.close()

        u2 = mda.Universe(self.outfile)
        assert_(all(u2.atoms.names == 'ABC'))
Exemplo n.º 4
0
    def test_list_names(self):
        u = make_Universe(trajectory=True)

        names = ['A', 'B', 'C', 'D', 'E'] * 25

        w = XYZWriter(self.outfile, atoms=names)
        w.write(u.trajectory.ts)
        w.close()

        u2 = mda.Universe(self.outfile)
        assert_(all(u2.atoms.names == names))
Exemplo n.º 5
0
    def test_list_names(self):
        u = make_Universe(trajectory=True)

        names = ['A', 'B', 'C', 'D', 'E'] * 25

        w = XYZWriter(self.outfile, atoms=names)
        w.write(u.trajectory.ts)
        w.close()

        u2 = mda.Universe(self.outfile)
        assert_(all(u2.atoms.names == names))