Mercurial > public > mercurial-scm > python-hglib
diff tests/test-log.py @ 193:32e8d51ec16c
util: make cmdbuilder() robust for faulty parsing of early options
Also fixed handling of positional arguments.
author | Yuya Nishihara <yuya@tcha.org> |
---|---|
date | Sat, 11 Nov 2017 19:52:48 +0900 |
parents | c1b966866ed7 |
children | 2d0ec6097d78 |
line wrap: on
line diff
--- a/tests/test-log.py Sat Nov 11 20:21:26 2017 +0900 +++ b/tests/test-log.py Sat Nov 11 19:52:48 2017 +0900 @@ -20,6 +20,13 @@ self.assertEquals(self.client.log(), self.client.log(hidden=True)) + def test_dash_in_filename(self): + self.append('-a', '-a') + self.client.commit(b('first'), addremove=True) + revs = self.client.log(files=[b('-a')]) + self.assertTrue(len(revs) == 1) + self.assertEquals(revs[0].rev, b('0')) + # def test_errors(self): # self.assertRaisesRegexp(CommandError, 'abort: unknown revision', # self.client.log, 'foo')