Beispiel #1
0
 def testNewCopy(self):
     vgd0ptr = self._newReadBcmk()
     vgd1ptr = vgd.vgd_copy(vgd0ptr)
     ok = vgd.vgd_cmp(vgd0ptr,vgd1ptr)
     self.assertTrue(ok)
     vgd.vgd_put(vgd1ptr, 'RFLD', 'PRES')
     ok = vgd.vgd_cmp(vgd0ptr,vgd1ptr)
     self.assertFalse(ok)
Beispiel #2
0
    def testWriteDesc(self):
        vgd0ptr = self._newReadBcmk()

        self._erase_testfile()
        fileName = self.fname
        fileId = rmn.fstopenall(fileName, rmn.FST_RW)
        vgd.vgd_write(vgd0ptr,fileId)
        rmn.fstcloseall(fileId)

        fileId = rmn.fstopenall(fileName, rmn.FST_RO)
        vgd1ptr = vgd.vgd_read(fileId)
        rmn.fstcloseall(fileId)
        self._erase_testfile()
        ok = vgd.vgd_cmp(vgd0ptr,vgd1ptr)
        self.assertTrue(ok)
Beispiel #3
0
    def testWriteDesc(self):
        vgd0ptr = self._newReadBcmk()

        self._erase_testfile()
        fileName = self.fname
        fileId = rmn.fstopenall(fileName, rmn.FST_RW)
        vgd.vgd_write(vgd0ptr,fileId)
        rmn.fstcloseall(fileId)

        fileId = rmn.fstopenall(fileName, rmn.FST_RO)
        vgd1ptr = vgd.vgd_read(fileId)
        rmn.fstcloseall(fileId)
        self._erase_testfile()
        ok = vgd.vgd_cmp(vgd0ptr,vgd1ptr)
        self.assertTrue(ok)
Beispiel #4
0
 def testNewCopy(self): 
     vgd0ptr = self._newReadBcmk()
     vgd1ptr = vgd.vgd_copy(vgd0ptr)
     ok = vgd.vgd_cmp(vgd0ptr,vgd1ptr)
     self.assertTrue(ok)
Beispiel #5
0
 def testNewFromTable(self):
     vgd0ptr = self._newReadBcmk()
     vgdtbl  = vgd.vgd_tolist(vgd0ptr)
     vgd1ptr = vgd.vgd_fromlist(vgdtbl)
     ok = vgd.vgd_cmp(vgd0ptr,vgd1ptr)
     self.assertTrue(ok)
Beispiel #6
0
    def testCmp(self):
        vgd0ptr = self._newReadBcmk()
        vgd1ptr = self._newReadBcmk()

        ok = vgd.vgd_cmp(vgd0ptr,vgd1ptr)
        self.assertTrue(ok)
Beispiel #7
0
 def testNewFromTable(self):
     vgd0ptr = self._newReadBcmk()
     vgdtbl  = vgd.vgd_tolist(vgd0ptr)
     vgd1ptr = vgd.vgd_fromlist(vgdtbl)
     ok = vgd.vgd_cmp(vgd0ptr,vgd1ptr)
     self.assertTrue(ok)