bzr branch
http://gegoxaren.bato24.eu/bzr/brz/remove-bazaar
|
7414.3.1
by Jelmer Vernooij
Fix the credits command. |
1 |
from ...tests import TestCaseWithTransport |
2 |
||
3 |
||
4 |
class TestBlackbox(TestCaseWithTransport): |
|
5 |
||
6 |
def setUp(self): |
|
7 |
super(TestBlackbox, self).setUp() |
|
8 |
wt = self.make_branch_and_tree('.') |
|
9 |
self.build_tree_contents([('foo.c', '#include <stdio.h>\n')]) |
|
10 |
wt.add('foo.c') |
|
11 |
wt.commit(message='1', committer='Fero <fero@example.com>', rev_id=b'1') |
|
12 |
wt.commit(message='2', committer='Fero <fero@example.com>', rev_id=b'2') |
|
13 |
wt.commit(message='3', committer='Jano <jano@example.com>', rev_id=b'3') |
|
14 |
wt.commit(message='4', committer='Jano <jano@example.com>', |
|
15 |
authors=['Vinco <vinco@example.com>'], rev_id=b'4') |
|
16 |
wt.commit(message='5', committer='Ferko <fero@example.com>', rev_id=b'5') |
|
17 |
||
18 |
def test_stats(self): |
|
19 |
(out, err) = self.run_bzr('stats') |
|
20 |
self.assertEqual(out, """\ |
|
21 |
3 Fero <fero@example.com>
|
|
22 |
Other names:
|
|
23 |
2 Fero
|
|
24 |
1 Ferko
|
|
25 |
1 Vinco <vinco@example.com>
|
|
26 |
1 Jano <jano@example.com>
|
|
27 |
""") |
|
28 |
||
29 |
def test_credits(self): |
|
30 |
(out, err) = self.run_bzr('credits') |
|
31 |
self.assertEqual(out, """\ |
|
32 |
Code:
|
|
33 |
Fero <fero@example.com>
|
|
34 |
||
35 |
""") |