~bzr-pqm/bzr/bzr.dev

« back to all changes in this revision

Viewing changes to testknit.py

  • Committer: Martin Pool
  • Date: 2005-06-27 02:47:42 UTC
  • mto: This revision was merged to the branch mainline in revision 852.
  • Revision ID: mbp@sourcefrog.net-20050627024742-8ea432c52c066a0d
Start indexing knits by both integer and version string.

Use index when inserting and checking text.

Show diffs side-by-side

added added

removed removed

Lines of Context:
39
39
    """Store and retrieve a simple text."""
40
40
    def runTest(self):
41
41
        k = Knit()
42
 
        k.add(TEXT_0)
43
 
        self.assertEqual(k.get(), TEXT_0)
 
42
        idx = k.add(TEXT_0)
 
43
        self.assertEqual(k.get(idx), TEXT_0)
 
44
        self.assertEqual(idx, 0)
44
45
 
45
46
 
46
47
def testknit():