mirror of
https://github.com/facebook/sapling.git
synced 2024-10-06 23:07:18 +03:00
tests: make pwd
URL compatible on Windows in test-default-push
Without this, the test fails with: $ hg -q commit -A -m 'add pushurl' abort: file:// URLs can only refer to localhost $ hg push abort: file:// URLs can only refer to localhost The variable $PWD causes check-code to complain, so avoid that.
This commit is contained in:
parent
3d1b5ddf9f
commit
6d5700eb1f
@ -75,10 +75,16 @@ Pushing to a path that isn't defined should not fall back to default
|
||||
$ hg -q clone a pushurlsource
|
||||
$ hg -q clone a pushurldest
|
||||
$ cd pushurlsource
|
||||
|
||||
Windows needs a leading slash to make a URL that passes all of the checks
|
||||
$ WD=`pwd`
|
||||
#if windows
|
||||
$ WD="/$WD"
|
||||
#endif
|
||||
$ cat > .hg/hgrc << EOF
|
||||
> [paths]
|
||||
> default = https://example.com/not/relevant
|
||||
> default:pushurl = file://`pwd`/../pushurldest
|
||||
> default:pushurl = file://$WD/../pushurldest
|
||||
> EOF
|
||||
|
||||
$ touch pushurl
|
||||
|
Loading…
Reference in New Issue
Block a user