[MERGE] New option --author for commit
Aaron Bentley
aaron.bentley at utoronto.ca
Tue Aug 7 22:07:08 BST 2007
-----BEGIN PGP SIGNED MESSAGE-----
Hash: SHA1
!tweak
Lukáš Lalinský wrote:
> On Ut, 2007-08-07 at 14:09 -0400, Aaron Bentley wrote:
> I know I shouldn't do unrelated changed, but I couldn't resist changed
> all these in log_revision.
Well, it's more of a guideline than a rule.
> + def test_commit_author_conflict(self):
> + """Passing both author kwarg and 'author' key in revprops should
> + raise AssertionError.
> + """
> + tree = self.make_branch_and_tree('foo')
> + self.assertRaises(AssertionError, tree.commit, 'commit 1',
> + author='John Doe <jdoe at example.com>',
> + revprops={'author': ''})
We want our test suite to pass when run with python -O. This is why we
use assertTrue, assertEqual etc., instead of 'assert x == y'.
This test case will fail when run with python -O, because it will skip
the assert. Because it's a programming error, you don't have to test
this case, but if you want to, then MutableTree.commit must not use
'assert'.
Sorry if I lead you astray.
Aaron
-----BEGIN PGP SIGNATURE-----
Version: GnuPG v1.4.6 (GNU/Linux)
Comment: Using GnuPG with Mozilla - http://enigmail.mozdev.org
iD8DBQFGuN780F+nu1YWqI0RAiTYAJ4+8GSsETv0ECr8bTEPUVuj630LQACeN28o
ovDb8ji6QAJF2Wv0SjTM+Ow=
=fxwS
-----END PGP SIGNATURE-----
More information about the bazaar
mailing list