tests: don't overwrite HGRCPATH

Overwriting instead of appending to the file removes the [defaults]
section put into the file by run-tests.py.

It also defeats the --inotify option to run-tests.py.

(Nothing was broken yet, but the lack of -d "0 0" cause changeset
hashes to change unexpectedly in a test case I was editing.)
This commit is contained in:
Martin Geisler 2011-03-01 17:01:17 +01:00
parent 9b2d3c510c
commit 83c27fb95f
16 changed files with 16 additions and 15 deletions

View File

@ -66,6 +66,7 @@ testpats = [
(r'^source\b', "don't use 'source', use '.'"),
(r'touch -d', "don't use 'touch -d', use 'touch -t' instead"),
(r'ls\s+[^|-]+\s+-', "options to 'ls' must come before filenames"),
(r'cat > \$HGRCPATH <<EOF', "append to $HGRCPATH, do not overwrite it"),
]
testfilters = [

View File

@ -1,5 +1,5 @@
$ cat > $HGRCPATH <<EOF
$ cat >> $HGRCPATH <<EOF
> [extensions]
> graphlog =
> convert =

View File

@ -1,7 +1,7 @@
$ "$TESTDIR/hghave" svn svn-bindings || exit 80
$ cat > $HGRCPATH <<EOF
$ cat >> $HGRCPATH <<EOF
> [extensions]
> convert =
> graphlog =

View File

@ -1,7 +1,7 @@
$ "$TESTDIR/hghave" svn svn-bindings || exit 80
$ cat > $HGRCPATH <<EOF
$ cat >> $HGRCPATH <<EOF
> [extensions]
> convert =
> graphlog =

View File

@ -5,7 +5,7 @@
> {
> tr '\\' /
> }
$ cat > $HGRCPATH <<EOF
$ cat >> $HGRCPATH <<EOF
> [extensions]
> convert =
> graphlog =

View File

@ -22,7 +22,7 @@
> )
> }
$ cat > $HGRCPATH <<EOF
$ cat >> $HGRCPATH <<EOF
> [extensions]
> convert =
> graphlog =

View File

@ -5,7 +5,7 @@
> {
> tr '\\' /
> }
$ cat > $HGRCPATH <<EOF
$ cat >> $HGRCPATH <<EOF
> [extensions]
> convert =
> graphlog =

View File

@ -1,7 +1,7 @@
$ "$TESTDIR/hghave" svn svn-bindings || exit 80
$ cat > $HGRCPATH <<EOF
$ cat >> $HGRCPATH <<EOF
> [extensions]
> convert =
> graphlog =

View File

@ -1,7 +1,7 @@
$ "$TESTDIR/hghave" svn svn-bindings || exit 80
$ cat > $HGRCPATH <<EOF
$ cat >> $HGRCPATH <<EOF
> [extensions]
> convert =
> graphlog =

View File

@ -1,6 +1,6 @@
Test adding .hgeol
$ cat > $HGRCPATH <<EOF
$ cat >> $HGRCPATH <<EOF
> [diff]
> git = 1
> EOF

View File

@ -1,6 +1,6 @@
Testing cloning with the EOL extension
$ cat > $HGRCPATH <<EOF
$ cat >> $HGRCPATH <<EOF
> [diff]
> git = True
>

View File

@ -1,6 +1,6 @@
Test the EOL hook
$ cat > $HGRCPATH <<EOF
$ cat >> $HGRCPATH <<EOF
> [diff]
> git = True
> EOF

View File

@ -1,6 +1,6 @@
Test EOL patching
$ cat > $HGRCPATH <<EOF
$ cat >> $HGRCPATH <<EOF
> [diff]
> git = 1
> EOF

View File

@ -2,7 +2,7 @@ http://mercurial.selenic.com/bts/issue2493
Testing tagging with the EOL extension
$ cat > $HGRCPATH <<EOF
$ cat >> $HGRCPATH <<EOF
> [diff]
> git = True
>

View File

@ -1,6 +1,6 @@
Test EOL update
$ cat > $HGRCPATH <<EOF
$ cat >> $HGRCPATH <<EOF
> [diff]
> git = 1
> EOF

View File

@ -1,6 +1,6 @@
Test EOL extension
$ cat > $HGRCPATH <<EOF
$ cat >> $HGRCPATH <<EOF
> [diff]
> git = True
> EOF