annotate tests/test-clone.py @ 97:705e601e6085

client: fix import --import-branch flag
author Idan Kamara <idankk86@gmail.com>
date Mon, 16 Jan 2012 12:53:14 +0200
parents a4fcece7dd8e
children 4359cabcb0cc
Ignore whitespace changes - Everywhere: Within whitespace: At end of lines:
rev   line source
93
a4fcece7dd8e hglib: add top level clone method
Idan Kamara <idankk86@gmail.com>
parents:
diff changeset
1 import os
a4fcece7dd8e hglib: add top level clone method
Idan Kamara <idankk86@gmail.com>
parents:
diff changeset
2 import common
a4fcece7dd8e hglib: add top level clone method
Idan Kamara <idankk86@gmail.com>
parents:
diff changeset
3 import hglib
a4fcece7dd8e hglib: add top level clone method
Idan Kamara <idankk86@gmail.com>
parents:
diff changeset
4
a4fcece7dd8e hglib: add top level clone method
Idan Kamara <idankk86@gmail.com>
parents:
diff changeset
5 class test_clone(common.basetest):
a4fcece7dd8e hglib: add top level clone method
Idan Kamara <idankk86@gmail.com>
parents:
diff changeset
6 def test_basic(self):
a4fcece7dd8e hglib: add top level clone method
Idan Kamara <idankk86@gmail.com>
parents:
diff changeset
7 self.append('a', 'a')
a4fcece7dd8e hglib: add top level clone method
Idan Kamara <idankk86@gmail.com>
parents:
diff changeset
8 self.client.commit('first', addremove=True)
a4fcece7dd8e hglib: add top level clone method
Idan Kamara <idankk86@gmail.com>
parents:
diff changeset
9 cloned = hglib.clone('.', 'cloned')
a4fcece7dd8e hglib: add top level clone method
Idan Kamara <idankk86@gmail.com>
parents:
diff changeset
10 self.assertRaises(ValueError, cloned.log)
a4fcece7dd8e hglib: add top level clone method
Idan Kamara <idankk86@gmail.com>
parents:
diff changeset
11 cloned.open()
a4fcece7dd8e hglib: add top level clone method
Idan Kamara <idankk86@gmail.com>
parents:
diff changeset
12 self.assertEquals(self.client.log(), cloned.log())