Back to index

python-biopython  1.60
Public Member Functions | Public Attributes
test_Crystal.CrystalTestCase Class Reference

List of all members.

Public Member Functions

def setUp
def testLen
def testGetItem
def testSetItem
def testDelItem
def testClear
def testKeys
def testValues
def testItems
def testKeys
def testHasKey

Public Attributes

 crystal

Detailed Description

Definition at line 429 of file test_Crystal.py.


Member Function Documentation

Definition at line 431 of file test_Crystal.py.

00431 
00432     def setUp(self):
00433 
00434         self.crystal = Crystal({ 'a' : 'T T G A C T C T C T T A A', \
00435                              'b' : Chain('G A G A G T C A'), \
00436                              'c' : 'T T G A C T C T C T T A A', \
00437                              'd' : Chain('G A G A G T C A')
00438                             })

Definition at line 461 of file test_Crystal.py.

00461 
00462     def testClear(self):
00463         target = copy.deepcopy(self.crystal)
00464         target.clear()
00465         self.assertEqual(len(target.data), 0)

Definition at line 454 of file test_Crystal.py.

00454 
00455     def testDelItem(self):
00456         target = copy.deepcopy(self.crystal)
00457         del target[ 'b' ]
00458         self.assertFalse('b' in target.data)
00459         self.assertTrue('a' in target.data)
00460         self.assertTrue('c' in target.data)

Definition at line 442 of file test_Crystal.py.

00442 
00443     def testGetItem(self):
00444         self.assertEqual(self.crystal[ 'a' ], self.crystal.data[ 'a' ])

Definition at line 478 of file test_Crystal.py.

00478 
00479     def testHasKey(self):
00480         self.assertTrue('b' in self.crystal)
00481         self.assertTrue('c' in self.crystal)
00482         self.assertFalse('z' in self.crystal)
00483 

Definition at line 472 of file test_Crystal.py.

00472 
00473     def testItems(self):
00474         self.assertEqual(self.crystal.items(), self.crystal.data.items())

Definition at line 466 of file test_Crystal.py.

00466 
00467     def testKeys(self):
00468         self.assertEqual(self.crystal.keys(), self.crystal.data.keys())

Here is the caller graph for this function:

Definition at line 475 of file test_Crystal.py.

00475 
00476     def testKeys(self):
00477         self.assertEqual(self.crystal.keys(), self.crystal.data.keys())

Here is the call graph for this function:

Definition at line 439 of file test_Crystal.py.

00439 
00440     def testLen(self):
00441         self.assertEqual(len(self.crystal), len(self.crystal.data))

Definition at line 445 of file test_Crystal.py.

00445 
00446     def testSetItem(self):
00447         target = copy.deepcopy(self.crystal)
00448         e = 'MET ALA LEU THR ASN ALA GLN ILE LEU ALA VAL ILE ASP SER'
00449         f = 'LEU GLY GLY GLY LEU GLN GLY THR LEU HIS CYS TYR GLU ILE PRO LEU'
00450         target[ 'e' ] = e
00451         target[ 'f' ] = Chain(f)
00452         self.assertEqual(Chain(e), target[ 'e' ])
00453         self.assertEqual(Chain(f), target[ 'f' ])

Definition at line 469 of file test_Crystal.py.

00469 
00470     def testValues(self):
00471         self.assertEqual(self.crystal.values(), self.crystal.data.values())


Member Data Documentation

Definition at line 433 of file test_Crystal.py.


The documentation for this class was generated from the following file: