Exemplo n.º 1
0
 def checkout(self, filename, revision):
     # FIXME: RCS should do keyword substitution, not CVS!
     cvs = CVS(join(dirname(__file__), 'data', 'greek'), None)
     cvs.localid = 'OpenBSD'
     f = RCSFile(join(dirname(__file__), 'data', filename))
     c = f.change(revision)
     blob = f.blob(revision)
     return cvs.expand_keywords(blob, c, f, revision)
Exemplo n.º 2
0
 def test_rcsfilename(self):
     """Find the RCS file for a working copy path.
     """
     cvs = CVS(join(dirname(__file__), 'data', 'zombie'), None)
     c = Change(timestamp='',
                author='',
                log='',
                filestatus='',
                filename='patches/patch-Makefile',
                revision='',
                state='',
                mode='')
     expected = join(cvs.root, 'patches/Attic/patch-Makefile,v')
     actual = cvs.rcsfilename(c)
     self.assertEqual(expected, actual)
Exemplo n.º 3
0
 def checkout(self, rcsfile, revision):
     change = rcsfile.change(revision)
     blob = rcsfile.blob(revision)
     cvs = CVS(os.path.join(os.path.dirname(rcsfile.filename)), None)
     print cvs.expand_keywords(blob, change, rcsfile, revision)