##// END OF EJS Templates
branching: merge default into stable...
branching: merge default into stable This mark the start of the 5.9 freeze.

File last commit:

r48054:40b51c28 default
r48559:d7515d29 merge 5.9rc0 stable
Show More
test-init.t
316 lines | 8.1 KiB | text/troff | Tads3Lexer
Matt Mackall
tests: fix a bunch of pointless #s in unified tests
r12328 This test tries to exercise the ssh functionality with a dummy script
Nicolas Dumazet
tests: unify test-init
r11786
$ checknewrepo()
> {
> name=$1
Mads Kiilerich
init: expand destination url as a configured paths...
r12584 > if [ -d "$name"/.hg/store ]; then
Nicolas Dumazet
tests: unify test-init
r11786 > echo store created
> fi
Mads Kiilerich
init: expand destination url as a configured paths...
r12584 > if [ -f "$name"/.hg/00changelog.i ]; then
Nicolas Dumazet
tests: unify test-init
r11786 > echo 00changelog.i created
> fi
Mads Kiilerich
init: expand destination url as a configured paths...
r12584 > cat "$name"/.hg/requires
Nicolas Dumazet
tests: unify test-init
r11786 > }
creating 'local'
$ hg init local
$ checknewrepo local
store created
00changelog.i created
Mads Kiilerich
localrepo: store requirements sorted
r18356 dotencode
Simon Sapin
dirstate-v2: Update the expected output of some tests for new requirement...
r48054 exp-dirstate-v2 (dirstate-v2 !)
Andrew Pritchard
localrepo: make requirements attribute of newly-created repos contain a set...
r14905 fncache
Pierre-Yves David
tests: test generaldelta configuration in test-init.t...
r26921 generaldelta
persistent-nodemap: enable the feature by default when using Rust...
r47646 persistent-nodemap (rust !)
revlog-compression: use zstd by default (if available)...
r47636 revlog-compression-zstd (zstd !)
Mads Kiilerich
localrepo: store requirements sorted
r18356 revlogv1
Boris Feld
test: enable sparse-revlog for test-init.t...
r40930 sparserevlog
Nicolas Dumazet
tests: unify test-init
r11786 store
Gregory Szorc
simplestore: use a custom store for the simple store repo...
r37433 testonly-simplestore (reposimplestore !)
Nicolas Dumazet
tests: unify test-init
r11786 $ echo this > local/foo
Martin Geisler
tests: remove unneeded -d flags...
r12156 $ hg ci --cwd local -A -m "init"
Nicolas Dumazet
tests: unify test-init
r11786 adding foo
Brodie Rao
revlog: allow tuning of the chunk cache size (via format.chunkcachesize)...
r20180 test custom revlog chunk cache sizes
$ hg --config format.chunkcachesize=0 log -R local -pv
Martin von Zweigbergk
errors: remove trailing "!" from some error messages for consistency...
r46518 abort: revlog chunk cache size 0 is not greater than 0
Martin von Zweigbergk
errors: use detailed exit code 50 for StorageError...
r46732 [50]
Brodie Rao
revlog: allow tuning of the chunk cache size (via format.chunkcachesize)...
r20180 $ hg --config format.chunkcachesize=1023 log -R local -pv
Martin von Zweigbergk
errors: remove trailing "!" from some error messages for consistency...
r46518 abort: revlog chunk cache size 1023 is not a power of 2
Martin von Zweigbergk
errors: use detailed exit code 50 for StorageError...
r46732 [50]
Brodie Rao
revlog: allow tuning of the chunk cache size (via format.chunkcachesize)...
r20180 $ hg --config format.chunkcachesize=1024 log -R local -pv
changeset: 0:08b9e9f63b32
tag: tip
user: test
date: Thu Jan 01 00:00:00 1970 +0000
files: foo
description:
init
diff -r 000000000000 -r 08b9e9f63b32 foo
--- /dev/null Thu Jan 01 00:00:00 1970 +0000
+++ b/foo Thu Jan 01 00:00:00 1970 +0000
@@ -0,0 +1,1 @@
+this
Nicolas Dumazet
tests: unify test-init
r11786 creating repo with format.usestore=false
$ hg --config format.usestore=false init old
$ checknewrepo old
Simon Sapin
dirstate-v2: Update the expected output of some tests for new requirement...
r48054 exp-dirstate-v2 (dirstate-v2 !)
Pierre-Yves David
tests: test generaldelta configuration in test-init.t...
r26921 generaldelta
persistent-nodemap: enable the feature by default when using Rust...
r47646 persistent-nodemap (rust !)
revlog-compression: use zstd by default (if available)...
r47636 revlog-compression-zstd (zstd !)
Nicolas Dumazet
tests: unify test-init
r11786 revlogv1
Gregory Szorc
simplestore: use a custom store for the simple store repo...
r37433 testonly-simplestore (reposimplestore !)
Boris Feld
test: enable sparse-revlog for test-init.t...
r40930 sparserevlog
Nicolas Dumazet
tests: unify test-init
r11786
creating repo with format.usefncache=false
$ hg --config format.usefncache=false init old2
$ checknewrepo old2
store created
00changelog.i created
Simon Sapin
dirstate-v2: Update the expected output of some tests for new requirement...
r48054 exp-dirstate-v2 (dirstate-v2 !)
Pierre-Yves David
tests: test generaldelta configuration in test-init.t...
r26921 generaldelta
persistent-nodemap: enable the feature by default when using Rust...
r47646 persistent-nodemap (rust !)
revlog-compression: use zstd by default (if available)...
r47636 revlog-compression-zstd (zstd !)
Nicolas Dumazet
tests: unify test-init
r11786 revlogv1
Boris Feld
test: enable sparse-revlog for test-init.t...
r40930 sparserevlog
Nicolas Dumazet
tests: unify test-init
r11786 store
Gregory Szorc
simplestore: use a custom store for the simple store repo...
r37433 testonly-simplestore (reposimplestore !)
Nicolas Dumazet
tests: unify test-init
r11786
Adrian Buehlmann
tests: add testcase for --config format.dotencode=false
r12712 creating repo with format.dotencode=false
$ hg --config format.dotencode=false init old3
$ checknewrepo old3
store created
00changelog.i created
Simon Sapin
dirstate-v2: Update the expected output of some tests for new requirement...
r48054 exp-dirstate-v2 (dirstate-v2 !)
Mads Kiilerich
localrepo: store requirements sorted
r18356 fncache
Pierre-Yves David
tests: test generaldelta configuration in test-init.t...
r26921 generaldelta
persistent-nodemap: enable the feature by default when using Rust...
r47646 persistent-nodemap (rust !)
revlog-compression: use zstd by default (if available)...
r47636 revlog-compression-zstd (zstd !)
Pierre-Yves David
tests: test generaldelta configuration in test-init.t...
r26921 revlogv1
Boris Feld
test: enable sparse-revlog for test-init.t...
r40930 sparserevlog
Pierre-Yves David
tests: test generaldelta configuration in test-init.t...
r26921 store
Gregory Szorc
simplestore: use a custom store for the simple store repo...
r37433 testonly-simplestore (reposimplestore !)
Pierre-Yves David
tests: test generaldelta configuration in test-init.t...
r26921
creating repo with format.dotencode=false
Boris Feld
test: enable sparse-revlog for test-init.t...
r40930 $ hg --config format.generaldelta=false --config format.usegeneraldelta=false --config format.sparse-revlog=no init old4
Pierre-Yves David
tests: test generaldelta configuration in test-init.t...
r26921 $ checknewrepo old4
store created
00changelog.i created
dotencode
Simon Sapin
dirstate-v2: Update the expected output of some tests for new requirement...
r48054 exp-dirstate-v2 (dirstate-v2 !)
Pierre-Yves David
tests: test generaldelta configuration in test-init.t...
r26921 fncache
persistent-nodemap: enable the feature by default when using Rust...
r47646 persistent-nodemap (rust !)
revlog-compression: use zstd by default (if available)...
r47636 revlog-compression-zstd (zstd !)
Adrian Buehlmann
tests: add testcase for --config format.dotencode=false
r12712 revlogv1
store
Gregory Szorc
simplestore: use a custom store for the simple store repo...
r37433 testonly-simplestore (reposimplestore !)
Adrian Buehlmann
tests: add testcase for --config format.dotencode=false
r12712
Nicolas Dumazet
tests: unify test-init
r11786 test failure
$ hg init local
Martin von Zweigbergk
errors: remove trailing "!" from some error messages for consistency...
r46518 abort: repository local already exists
Matt Mackall
tests: add exit codes to unified tests
r12316 [255]
Nicolas Dumazet
tests: unify test-init
r11786
init+push to remote2
Matt Harbison
tests: quote $PYTHON for Windows...
r33335 $ hg init -e "\"$PYTHON\" \"$TESTDIR/dummyssh\"" ssh://user@dummy/remote2
Nicolas Dumazet
tests: unify test-init
r11786 $ hg incoming -R remote2 local
comparing with local
Martin Geisler
tests: remove unneeded -d flags...
r12156 changeset: 0:08b9e9f63b32
Nicolas Dumazet
tests: unify test-init
r11786 tag: tip
user: test
Martin Geisler
tests: remove unneeded -d flags...
r12156 date: Thu Jan 01 00:00:00 1970 +0000
Nicolas Dumazet
tests: unify test-init
r11786 summary: init
Matt Harbison
tests: quote $PYTHON for Windows...
r33335 $ hg push -R local -e "\"$PYTHON\" \"$TESTDIR/dummyssh\"" ssh://user@dummy/remote2
Nicolas Dumazet
tests: unify test-init
r11786 pushing to ssh://user@dummy/remote2
searching for changes
remote: adding changesets
remote: adding manifests
remote: adding file changes
remote: added 1 changesets with 1 changes to 1 files
clone to remote1
Matt Harbison
tests: quote $PYTHON for Windows...
r33335 $ hg clone -e "\"$PYTHON\" \"$TESTDIR/dummyssh\"" local ssh://user@dummy/remote1
Nicolas Dumazet
tests: unify test-init
r11786 searching for changes
remote: adding changesets
remote: adding manifests
remote: adding file changes
remote: added 1 changesets with 1 changes to 1 files
Matt Harbison
largefiles: don't crash when cloning to a remote repo...
r24812 The largefiles extension doesn't crash
Matt Harbison
tests: quote $PYTHON for Windows...
r33335 $ hg clone -e "\"$PYTHON\" \"$TESTDIR/dummyssh\"" local ssh://user@dummy/remotelf --config extensions.largefiles=
FUJIWARA Katsunori
tests: add fsmonitor specific output lines at enabling largefiles...
r33209 The fsmonitor extension is incompatible with the largefiles extension and has been disabled. (fsmonitor !)
The fsmonitor extension is incompatible with the largefiles extension and has been disabled. (fsmonitor !)
Matt Harbison
largefiles: don't crash when cloning to a remote repo...
r24812 searching for changes
remote: adding changesets
remote: adding manifests
remote: adding file changes
remote: added 1 changesets with 1 changes to 1 files
Nicolas Dumazet
tests: unify test-init
r11786 init to existing repo
Matt Harbison
tests: quote $PYTHON for Windows...
r33335 $ hg init -e "\"$PYTHON\" \"$TESTDIR/dummyssh\"" ssh://user@dummy/remote1
Martin von Zweigbergk
errors: remove trailing "!" from some error messages for consistency...
r46518 abort: repository remote1 already exists
abort: could not create remote repo
Matt Mackall
tests: add exit codes to unified tests
r12316 [255]
Nicolas Dumazet
tests: unify test-init
r11786
clone to existing repo
Matt Harbison
tests: quote $PYTHON for Windows...
r33335 $ hg clone -e "\"$PYTHON\" \"$TESTDIR/dummyssh\"" local ssh://user@dummy/remote1
Martin von Zweigbergk
errors: remove trailing "!" from some error messages for consistency...
r46518 abort: repository remote1 already exists
abort: could not create remote repo
Matt Mackall
tests: add exit codes to unified tests
r12316 [255]
Nicolas Dumazet
tests: unify test-init
r11786
output of dummyssh
$ cat dummylog
Mads Kiilerich
sshrepo: don't quote obviously safe strings (issue2983)...
r15622 Got arguments 1:user@dummy 2:hg init remote2
Got arguments 1:user@dummy 2:hg -R remote2 serve --stdio
Got arguments 1:user@dummy 2:hg -R remote2 serve --stdio
Got arguments 1:user@dummy 2:hg init remote1
Got arguments 1:user@dummy 2:hg -R remote1 serve --stdio
Matt Harbison
largefiles: don't crash when cloning to a remote repo...
r24812 Got arguments 1:user@dummy 2:hg init remotelf
Got arguments 1:user@dummy 2:hg -R remotelf serve --stdio
Mads Kiilerich
sshrepo: don't quote obviously safe strings (issue2983)...
r15622 Got arguments 1:user@dummy 2:hg init remote1
Got arguments 1:user@dummy 2:hg init remote1
Nicolas Dumazet
tests: unify test-init
r11786
comparing repositories
$ hg tip -q -R local
Martin Geisler
tests: remove unneeded -d flags...
r12156 0:08b9e9f63b32
Nicolas Dumazet
tests: unify test-init
r11786 $ hg tip -q -R remote1
Martin Geisler
tests: remove unneeded -d flags...
r12156 0:08b9e9f63b32
Nicolas Dumazet
tests: unify test-init
r11786 $ hg tip -q -R remote2
Martin Geisler
tests: remove unneeded -d flags...
r12156 0:08b9e9f63b32
Nicolas Dumazet
tests: unify test-init
r11786
check names for repositories (clashes with URL schemes, special chars)
Adrian Buehlmann
test-init: enable for Windows...
r16915 $ for i in bundle file hg http https old-http ssh static-http "with space"; do
Martin Geisler
test-init: replace 'echo -n' with 'printf'...
r11883 > printf "hg init \"$i\"... "
Nicolas Dumazet
tests: unify test-init
r11786 > hg init "$i"
> test -d "$i" -a -d "$i/.hg" && echo "ok" || echo "failed"
> done
hg init "bundle"... ok
hg init "file"... ok
hg init "hg"... ok
hg init "http"... ok
hg init "https"... ok
hg init "old-http"... ok
hg init "ssh"... ok
hg init "static-http"... ok
hg init "with space"... ok
Mads Kiilerich
tests: use hghave eol-in-paths to test for support for ':' in filenames and " "...
r16974 #if eol-in-paths
Adrian Buehlmann
test-init: enable for Windows...
r16915 /* " " is not a valid name for a directory on Windows */
$ hg init " "
$ test -d " "
$ test -d " /.hg"
#endif
Nicolas Dumazet
tests: unify test-init
r11786
creating 'local/sub/repo'
$ hg init local/sub/repo
$ checknewrepo local/sub/repo
store created
00changelog.i created
Mads Kiilerich
localrepo: store requirements sorted
r18356 dotencode
Simon Sapin
dirstate-v2: Update the expected output of some tests for new requirement...
r48054 exp-dirstate-v2 (dirstate-v2 !)
Andrew Pritchard
localrepo: make requirements attribute of newly-created repos contain a set...
r14905 fncache
Pierre-Yves David
tests: test generaldelta configuration in test-init.t...
r26921 generaldelta
persistent-nodemap: enable the feature by default when using Rust...
r47646 persistent-nodemap (rust !)
revlog-compression: use zstd by default (if available)...
r47636 revlog-compression-zstd (zstd !)
Mads Kiilerich
localrepo: store requirements sorted
r18356 revlogv1
Boris Feld
test: enable sparse-revlog for test-init.t...
r40930 sparserevlog
Nicolas Dumazet
tests: unify test-init
r11786 store
Gregory Szorc
simplestore: use a custom store for the simple store repo...
r37433 testonly-simplestore (reposimplestore !)
Mads Kiilerich
init: expand destination url as a configured paths...
r12584
prepare test of init of url configured from paths
$ echo '[paths]' >> $HGRCPATH
$ echo "somewhere = `pwd`/url from paths" >> $HGRCPATH
$ echo "elsewhere = `pwd`/another paths url" >> $HGRCPATH
init should (for consistency with clone) expand the url
$ hg init somewhere
$ checknewrepo "url from paths"
store created
00changelog.i created
Mads Kiilerich
localrepo: store requirements sorted
r18356 dotencode
Simon Sapin
dirstate-v2: Update the expected output of some tests for new requirement...
r48054 exp-dirstate-v2 (dirstate-v2 !)
Andrew Pritchard
localrepo: make requirements attribute of newly-created repos contain a set...
r14905 fncache
Pierre-Yves David
tests: test generaldelta configuration in test-init.t...
r26921 generaldelta
persistent-nodemap: enable the feature by default when using Rust...
r47646 persistent-nodemap (rust !)
revlog-compression: use zstd by default (if available)...
r47636 revlog-compression-zstd (zstd !)
Mads Kiilerich
localrepo: store requirements sorted
r18356 revlogv1
Boris Feld
test: enable sparse-revlog for test-init.t...
r40930 sparserevlog
Mads Kiilerich
init: expand destination url as a configured paths...
r12584 store
Gregory Szorc
simplestore: use a custom store for the simple store repo...
r37433 testonly-simplestore (reposimplestore !)
Mads Kiilerich
init: expand destination url as a configured paths...
r12584
verify that clone also expand urls
$ hg clone somewhere elsewhere
updating to branch default
0 files updated, 0 files merged, 0 files removed, 0 files unresolved
$ checknewrepo "another paths url"
store created
00changelog.i created
Mads Kiilerich
localrepo: store requirements sorted
r18356 dotencode
Simon Sapin
dirstate-v2: Update the expected output of some tests for new requirement...
r48054 exp-dirstate-v2 (dirstate-v2 !)
Andrew Pritchard
localrepo: make requirements attribute of newly-created repos contain a set...
r14905 fncache
Pierre-Yves David
tests: test generaldelta configuration in test-init.t...
r26921 generaldelta
persistent-nodemap: enable the feature by default when using Rust...
r47646 persistent-nodemap (rust !)
revlog-compression: use zstd by default (if available)...
r47636 revlog-compression-zstd (zstd !)
Mads Kiilerich
localrepo: store requirements sorted
r18356 revlogv1
Boris Feld
test: enable sparse-revlog for test-init.t...
r40930 sparserevlog
Mads Kiilerich
init: expand destination url as a configured paths...
r12584 store
Gregory Szorc
simplestore: use a custom store for the simple store repo...
r37433 testonly-simplestore (reposimplestore !)
David Soria Parra
hg: add support for cloning bookmarks
r13604
clone bookmarks
$ hg -R local bookmark test
$ hg -R local bookmarks
* test 0:08b9e9f63b32
Matt Harbison
tests: quote $PYTHON for Windows...
r33335 $ hg clone -e "\"$PYTHON\" \"$TESTDIR/dummyssh\"" local ssh://user@dummy/remote-bookmarks
David Soria Parra
hg: add support for cloning bookmarks
r13604 searching for changes
remote: adding changesets
remote: adding manifests
remote: adding file changes
remote: added 1 changesets with 1 changes to 1 files
Pierre-Yves David
clone: explicitly push bookmarks when cloning from local to remote...
r22647 exporting bookmark test
David Soria Parra
hg: add support for cloning bookmarks
r13604 $ hg -R remote-bookmarks bookmarks
test 0:08b9e9f63b32
Boris Feld
revlog: make sure we never use sparserevlog without general delta (issue6056)...
r41525
Check format constraint
-----------------------
$ hg init issue6056 --config format.usegeneraldelta=0 --config format.sparse-revlog=0
$ cd issue6056
$ echo foo > 1
$ echo foo > 2
$ echo foo > 3
$ echo foo > 4
$ echo foo > 5
$ hg add *
Build a bogus repository (sparserevlog without general delta)
$ hg commit -m 'initial changesets'
$ echo 'sparserevlog' >> .hg/requires
$ for x in `$TESTDIR/seq.py 100`; do
> echo $x >> `expr $x % 5 + 1`
> hg commit -m $x
> done
$ cd ..