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

def test_BioSQL::DupLoadTest::test_duplicate_id_load (   self )
Make sure can't import records with same ID (in one go).

Definition at line 437 of file test_BioSQL.py.

        """Make sure can't import records with same ID (in one go)."""
        record1 = SeqRecord(Seq("ATGCTATGACTAT", Alphabet.generic_dna),id="TestA")
        record2 = SeqRecord(Seq("GGGATGCGACTAT", Alphabet.generic_dna),id="TestA")
            count = self.db.load([record1,record2])
        except Exception, err:
            self.assertEqual("IntegrityError", err.__class__.__name__)
        raise Exception("Should have failed! Loaded %i records" % count)

Generated by  Doxygen 1.6.0   Back to index