Details
Details
- Reviewers
- None
- Group Reviewers
hg-reviewers - Commits
- rHG2f40bcebad30: py3: suppress the return value from .write() call
Diff Detail
Diff Detail
- Repository
- rHG Mercurial
- Lint
Lint Skipped - Unit
Unit Tests Skipped
( )
hg-reviewers |
Lint Skipped |
Unit Tests Skipped |
Path | Packages | |||
---|---|---|---|---|
M | tests/test-convert-mtn.t (6 lines) | |||
M | tests/test-diff-color.t (2 lines) |
Commit | Parents | Author | Summary | Date |
---|---|---|---|---|
Pulkit Goyal | Sep 14 2018, 5:01 PM |
$ mtn db init --db=repo.mtn | $ mtn db init --db=repo.mtn | ||||
$ mtn --db=repo.mtn --branch=com.selenic.test setup workingdir | $ mtn --db=repo.mtn --branch=com.selenic.test setup workingdir | ||||
$ cd workingdir | $ cd workingdir | ||||
$ echo a > a | $ echo a > a | ||||
$ mkdir dir | $ mkdir dir | ||||
$ echo b > dir/b | $ echo b > dir/b | ||||
$ echo d > dir/d | $ echo d > dir/d | ||||
$ $PYTHON -c 'open("bin", "wb").write(b"a\\x00b")' | $ $PYTHON -c 'open("bin", "wb").write(b"a\\x00b") and None' | ||||
$ echo c > c | $ echo c > c | ||||
$ mtn add a dir/b dir/d c bin | $ mtn add a dir/b dir/d c bin | ||||
mtn: adding 'a' to workspace manifest | mtn: adding 'a' to workspace manifest | ||||
mtn: adding 'bin' to workspace manifest | mtn: adding 'bin' to workspace manifest | ||||
mtn: adding 'c' to workspace manifest | mtn: adding 'c' to workspace manifest | ||||
mtn: adding 'dir' to workspace manifest | mtn: adding 'dir' to workspace manifest | ||||
mtn: adding 'dir/b' to workspace manifest | mtn: adding 'dir/b' to workspace manifest | ||||
mtn: adding 'dir/d' to workspace manifest | mtn: adding 'dir/d' to workspace manifest | ||||
$ mtn ci -m initialize | $ mtn ci -m initialize | ||||
mtn: beginning commit on branch 'com.selenic.test' | mtn: beginning commit on branch 'com.selenic.test' | ||||
mtn: committed revision 0f6e5e4f2e7d2a8ef312408f57618abf026afd90 | mtn: committed revision 0f6e5e4f2e7d2a8ef312408f57618abf026afd90 | ||||
update monotone working directory | update monotone working directory | ||||
$ mtn mv a dir/a | $ mtn mv a dir/a | ||||
mtn: skipping 'dir', already accounted for in workspace | mtn: skipping 'dir', already accounted for in workspace | ||||
mtn: renaming 'a' to 'dir/a' in workspace manifest | mtn: renaming 'a' to 'dir/a' in workspace manifest | ||||
$ echo a >> dir/a | $ echo a >> dir/a | ||||
$ echo b >> dir/b | $ echo b >> dir/b | ||||
$ mtn drop c | $ mtn drop c | ||||
mtn: dropping 'c' from workspace manifest | mtn: dropping 'c' from workspace manifest | ||||
$ $PYTHON -c 'open("bin", "wb").write(b"b\\x00c")' | $ $PYTHON -c 'open("bin", "wb").write(b"b\\x00c") and None' | ||||
$ mtn ci -m update1 | $ mtn ci -m update1 | ||||
mtn: beginning commit on branch 'com.selenic.test' | mtn: beginning commit on branch 'com.selenic.test' | ||||
mtn: committed revision 51d0a982464573a2a2cf5ee2c9219c652aaebeff | mtn: committed revision 51d0a982464573a2a2cf5ee2c9219c652aaebeff | ||||
$ cd .. | $ cd .. | ||||
convert once | convert once | ||||
$ hg convert -s mtn repo.mtn | $ hg convert -s mtn repo.mtn | ||||
mtn: renaming 'dir9-2/dir8' to 'dir8-2' in workspace manifest | mtn: renaming 'dir9-2/dir8' to 'dir8-2' in workspace manifest | ||||
$ mtn ci -m divergentdirmove2 | $ mtn ci -m divergentdirmove2 | ||||
mtn: beginning commit on branch 'com.selenic.test' | mtn: beginning commit on branch 'com.selenic.test' | ||||
mtn: committed revision 4a736634505795f17786fffdf2c9cbf5b11df6f6 | mtn: committed revision 4a736634505795f17786fffdf2c9cbf5b11df6f6 | ||||
test large file support (> 32kB) | test large file support (> 32kB) | ||||
>>> fp = open('large-file', 'wb') | >>> fp = open('large-file', 'wb') | ||||
>>> for x in range(10000): fp.write(b'%d\n' % x) | >>> for x in range(10000): fp.write(b'%d\n' % x) and None | ||||
>>> fp.close() | >>> fp.close() | ||||
$ md5sum.py large-file | $ md5sum.py large-file | ||||
5d6de8a95c3b6bf9e0ffb808ba5299c1 large-file | 5d6de8a95c3b6bf9e0ffb808ba5299c1 large-file | ||||
$ mtn add large-file | $ mtn add large-file | ||||
mtn: adding 'large-file' to workspace manifest | mtn: adding 'large-file' to workspace manifest | ||||
$ mtn ci -m largefile | $ mtn ci -m largefile | ||||
mtn: beginning commit on branch 'com.selenic.test' | mtn: beginning commit on branch 'com.selenic.test' | ||||
mtn: committed revision f0a20fecd10dc4392d18fe69a03f1f4919d3387b | mtn: committed revision f0a20fecd10dc4392d18fe69a03f1f4919d3387b |
c | c | ||||
trailing whitespace | trailing whitespace | ||||
$ cp a a.orig | $ cp a a.orig | ||||
>>> with open('a', 'rb') as f: | >>> with open('a', 'rb') as f: | ||||
... data = f.read() | ... data = f.read() | ||||
>>> with open('a', 'wb') as f: | >>> with open('a', 'wb') as f: | ||||
... f.write(data.replace(b'dd', b'dd \r')) | ... f.write(data.replace(b'dd', b'dd \r')) and None | ||||
$ hg diff --nodates | $ hg diff --nodates | ||||
\x1b[0;1mdiff -r cf9f4ba66af2 a\x1b[0m (esc) | \x1b[0;1mdiff -r cf9f4ba66af2 a\x1b[0m (esc) | ||||
\x1b[0;31;1m--- a/a\x1b[0m (esc) | \x1b[0;31;1m--- a/a\x1b[0m (esc) | ||||
\x1b[0;32;1m+++ b/a\x1b[0m (esc) | \x1b[0;32;1m+++ b/a\x1b[0m (esc) | ||||
\x1b[0;35m@@ -2,7 +2,7 @@\x1b[0m (esc) | \x1b[0;35m@@ -2,7 +2,7 @@\x1b[0m (esc) | ||||
c | c | ||||
a | a | ||||
a | a |