mirror of
https://github.com/facebook/sapling.git
synced 2024-10-16 19:57:18 +03:00
b27a46c987
Summary: This is a big bulk of generally almost-obvious fixes to the moved tests. Mostly these fixes have to do with correct importing of the actual extensions. Depends on D6675329 Test Plan: - ./run-tests.py fails less after this commit - see further commits for more test fixes Reviewers: #sourcecontrol Differential Revision: https://phabricator.intern.facebook.com/D6675344
55 lines
1.4 KiB
Perl
55 lines
1.4 KiB
Perl
$ cat >> $HGRCPATH <<EOF
|
|
> [extensions]
|
|
> configwarn=
|
|
> [configwarn]
|
|
> systemconfigs=diff.git, phases.publish
|
|
> [alias]
|
|
> noop=log -r null -T '{files}'
|
|
> EOF
|
|
|
|
Need to override rcutil.userrcpath to test properly without side-effects
|
|
|
|
$ cat >> $TESTTMP/rcpath.py <<EOF
|
|
> from __future__ import absolute_import
|
|
> from mercurial import encoding, rcutil
|
|
> def userrcpath():
|
|
> return [encoding.environ[b'USERHGRC']]
|
|
> rcutil.userrcpath = userrcpath
|
|
> EOF
|
|
|
|
$ cat >> $HGRCPATH <<EOF
|
|
> [extensions]
|
|
> rcpath=$TESTTMP/rcpath.py
|
|
> EOF
|
|
|
|
$ USERHGRC="$TESTTMP/userhgrc"
|
|
$ HGRCPATH="$HGRCPATH:$USERHGRC"
|
|
$ export USERHGRC
|
|
|
|
Config set by system config files or command line flags are fine
|
|
|
|
$ hg init
|
|
$ hg noop
|
|
$ hg noop --config diff.git=1
|
|
|
|
Config set by user config will generate warnings
|
|
|
|
$ cat >> $USERHGRC <<EOF
|
|
> [diff]
|
|
> git=0
|
|
> EOF
|
|
|
|
$ hg noop
|
|
warning: overriding config diff.git is unsupported (hint: remove line 2 from $TESTTMP/userhgrc to resolve this issue)
|
|
|
|
Config set by repo will generate warnings
|
|
|
|
$ cat >> .hg/hgrc << EOF
|
|
> [phases]
|
|
> publish=1
|
|
> EOF
|
|
|
|
$ hg noop
|
|
warning: overriding config diff.git is unsupported (hint: remove line 2 from $TESTTMP/userhgrc to resolve this issue)
|
|
warning: overriding config phases.publish is unsupported (hint: remove line 2 from $TESTTMP/.hg/hgrc to resolve this issue)
|