annotate tests/test-remove.py @ 126:a7fe976b1931

context: add 'phase' getter This method must be dynamic as the phase can change during the lifetime of the changeset.
author Paul Tonelli <paul.tonelli@logilab.fr>
date Wed, 21 May 2014 12:25:30 +0200
parents b7042bb3dbfd
children 4359cabcb0cc
Ignore whitespace changes - Everywhere: Within whitespace: At end of lines:
rev   line source
30
b7042bb3dbfd client: add remove command
Idan Kamara <idankk86@gmail.com>
parents:
diff changeset
1 import common
b7042bb3dbfd client: add remove command
Idan Kamara <idankk86@gmail.com>
parents:
diff changeset
2
b7042bb3dbfd client: add remove command
Idan Kamara <idankk86@gmail.com>
parents:
diff changeset
3 class test_remove(common.basetest):
b7042bb3dbfd client: add remove command
Idan Kamara <idankk86@gmail.com>
parents:
diff changeset
4 def test_basic(self):
b7042bb3dbfd client: add remove command
Idan Kamara <idankk86@gmail.com>
parents:
diff changeset
5 self.append('a', 'a')
b7042bb3dbfd client: add remove command
Idan Kamara <idankk86@gmail.com>
parents:
diff changeset
6 self.client.commit('first', addremove=True)
b7042bb3dbfd client: add remove command
Idan Kamara <idankk86@gmail.com>
parents:
diff changeset
7 self.assertTrue(self.client.remove(['a']))
b7042bb3dbfd client: add remove command
Idan Kamara <idankk86@gmail.com>
parents:
diff changeset
8
b7042bb3dbfd client: add remove command
Idan Kamara <idankk86@gmail.com>
parents:
diff changeset
9 def test_warnings(self):
b7042bb3dbfd client: add remove command
Idan Kamara <idankk86@gmail.com>
parents:
diff changeset
10 self.append('a', 'a')
b7042bb3dbfd client: add remove command
Idan Kamara <idankk86@gmail.com>
parents:
diff changeset
11 self.client.commit('first', addremove=True)
b7042bb3dbfd client: add remove command
Idan Kamara <idankk86@gmail.com>
parents:
diff changeset
12 self.assertFalse(self.client.remove(['a', 'b']))