Logo Search packages:      
Sourcecode: python-biopython version File versions  Download package

def test_PopGen_GenePop::UtilsTest::test_utils (   self )
Basic operation of GenePop Utils.

Definition at line 81 of file test_PopGen_GenePop.py.

                        :
        """Basic operation of GenePop Utils.
        """
        for index in range(len(self.handles)):
            handle = self.handles[index]
            rec = GenePop.parse(handle)
        initial_pops = len(rec.populations)
        initial_loci = len(rec.loci_list)
        first_loci = rec.loci_list[0]
        rec.remove_population(0)
        assert len(rec.populations) == initial_pops - 1
        rec.remove_locus_by_name(first_loci)
        assert len(rec.loci_list) == initial_loci - 1
        assert rec.loci_list[0] != first_loci
        rec.remove_locus_by_position(0)
        assert len(rec.loci_list) == initial_loci - 2


Generated by  Doxygen 1.6.0   Back to index