annotate tests/test-hglib.py @ 123:cdde1656346f

client: add 'hidden' property to show hidden changesets. This enables interactions with the obsolete changesets in the repository: - add the attribute in client class - add the keyword to the relevant commands - enable log without hidden changesets even when self.hidden is True - add a few tests with the hidden keyword This changeset mirrors the behavior of the mercurial global command --hidden: an attribute is added to the client library. If set at True, adds the hidden keyword to all command which can use it to show hidden changesets. The alternative would be to add the keyword in rawcommand, but the hidden flag is not relevant for commands such as add or branch.
author Paul Tonelli <paul.tonelli@logilab.fr>
date Thu, 22 May 2014 15:23:12 +0200
parents d1f57f162274
children 1b47146a4a2c
Ignore whitespace changes - Everywhere: Within whitespace: At end of lines:
rev   line source
62
d1f57f162274 closefds on posix when using subprocess
Idan Kamara <idankk86@gmail.com>
parents:
diff changeset
1 import common, hglib
d1f57f162274 closefds on posix when using subprocess
Idan Kamara <idankk86@gmail.com>
parents:
diff changeset
2
d1f57f162274 closefds on posix when using subprocess
Idan Kamara <idankk86@gmail.com>
parents:
diff changeset
3 class test_hglib(common.basetest):
d1f57f162274 closefds on posix when using subprocess
Idan Kamara <idankk86@gmail.com>
parents:
diff changeset
4 def setUp(self):
d1f57f162274 closefds on posix when using subprocess
Idan Kamara <idankk86@gmail.com>
parents:
diff changeset
5 pass
d1f57f162274 closefds on posix when using subprocess
Idan Kamara <idankk86@gmail.com>
parents:
diff changeset
6
d1f57f162274 closefds on posix when using subprocess
Idan Kamara <idankk86@gmail.com>
parents:
diff changeset
7 def test_close_fds(self):
d1f57f162274 closefds on posix when using subprocess
Idan Kamara <idankk86@gmail.com>
parents:
diff changeset
8 """
d1f57f162274 closefds on posix when using subprocess
Idan Kamara <idankk86@gmail.com>
parents:
diff changeset
9 A weird Python bug that has something to do to inherited file descriptors,
d1f57f162274 closefds on posix when using subprocess
Idan Kamara <idankk86@gmail.com>
parents:
diff changeset
10 see http://bugs.python.org/issue12786
d1f57f162274 closefds on posix when using subprocess
Idan Kamara <idankk86@gmail.com>
parents:
diff changeset
11 """
d1f57f162274 closefds on posix when using subprocess
Idan Kamara <idankk86@gmail.com>
parents:
diff changeset
12 common.basetest.setUp(self)
d1f57f162274 closefds on posix when using subprocess
Idan Kamara <idankk86@gmail.com>
parents:
diff changeset
13 client2 = hglib.open()
d1f57f162274 closefds on posix when using subprocess
Idan Kamara <idankk86@gmail.com>
parents:
diff changeset
14 self.client.close()