# HG changeset patch # User Augie Fackler # Date 1489902476 14400 # Node ID aea8ec3f7dd1967a05ecce8f779e16f7ad14fdee # Parent 0b3eb280564b7dbbc6e6adc1c34b295c80b01ba2 py3: prove `hg {add,addremove,commit} all work We can't do a second commit in a repo yet, because pure-Python bdiff is broken on Python 3. That is probably a good next step. diff -r 0b3eb280564b -r aea8ec3f7dd1 tests/test-check-py3-commands.t --- a/tests/test-check-py3-commands.t Thu Mar 23 10:46:50 2017 -0400 +++ b/tests/test-check-py3-commands.t Sun Mar 19 01:47:56 2017 -0400 @@ -122,4 +122,44 @@ `hg init` can create empty repos - $ $PYTHON3 `which hg` init emptyrepo + $ $PYTHON3 `which hg` init py3repo + $ cd py3repo + $ echo "This is the file 'iota'." > iota + $ $PYTHON3 $HGBIN status + ? iota + $ $PYTHON3 $HGBIN add iota + $ $PYTHON3 $HGBIN status + A iota + $ $PYTHON3 $HGBIN commit --message 'commit performed in Python 3' + $ $PYTHON3 $HGBIN status + +TODO: bdiff is broken on Python 3 so we can't do a second commit yet, +when that works remove this rollback command. + $ hg rollback + repository tip rolled back to revision -1 (undo commit) + working directory now based on revision -1 + + $ mkdir A + $ echo "This is the file 'mu'." > A/mu + $ $PYTHON3 $HGBIN addremove + adding A/mu + $ $PYTHON3 $HGBIN status + A A/mu + A iota + $ HGEDITOR='echo message > ' $PYTHON3 $HGBIN commit + $ $PYTHON3 $HGBIN status + +Prove the repo is valid using the Python 2 `hg`: + $ hg verify + checking changesets + checking manifests + crosschecking files in changesets and manifests + checking files + 2 files, 1 changesets, 2 total revisions + $ hg log + changeset: 0:e825505ba339 + tag: tip + user: test + date: Thu Jan 01 00:00:00 1970 +0000 + summary: message +