Show More
@@ -1,35 +1,35 b'' | |||
|
1 | 1 | #!/usr/bin/env python |
|
2 | 2 | from __future__ import absolute_import, print_function |
|
3 | 3 | |
|
4 | 4 | from mercurial import ( |
|
5 | 5 | commands, |
|
6 | 6 | localrepo, |
|
7 | 7 | ui as uimod, |
|
8 | 8 | ) |
|
9 | 9 | |
|
10 | 10 | u = uimod.ui.load() |
|
11 | 11 | |
|
12 | 12 | print('% creating repo') |
|
13 | repo = localrepo.localrepository(u, '.', create=True) | |
|
13 | repo = localrepo.localrepository(u, b'.', create=True) | |
|
14 | 14 | |
|
15 | 15 | f = open('test.py', 'w') |
|
16 | 16 | try: |
|
17 | 17 | f.write('foo\n') |
|
18 | 18 | finally: |
|
19 | 19 | f.close |
|
20 | 20 | |
|
21 | 21 | print('% add and commit') |
|
22 | commands.add(u, repo, 'test.py') | |
|
23 | commands.commit(u, repo, message='*') | |
|
22 | commands.add(u, repo, b'test.py') | |
|
23 | commands.commit(u, repo, message=b'*') | |
|
24 | 24 | commands.status(u, repo, clean=True) |
|
25 | 25 | |
|
26 | 26 | |
|
27 | 27 | print('% change') |
|
28 | 28 | f = open('test.py', 'w') |
|
29 | 29 | try: |
|
30 | 30 | f.write('bar\n') |
|
31 | 31 | finally: |
|
32 | 32 | f.close() |
|
33 | 33 | |
|
34 | 34 | # this would return clean instead of changed before the fix |
|
35 | 35 | commands.status(u, repo, clean=True, modified=True) |
General Comments 0
You need to be logged in to leave comments.
Login now