mirror of
https://github.com/facebook/sapling.git
synced 2024-10-07 07:17:55 +03:00
runtests: change local IP glob pattern from "127.0.0.1" to "$LOCALIP"
This is similar to what 9704c8e70d2d does. Since 1363aaf74791 has changed "127.0.0.1" to "$LOCALIP". The glob pattern needs update accordingly. It is expected to fix tests running in some BSD jails.
This commit is contained in:
parent
368236438f
commit
35b00f22fa
@ -210,8 +210,8 @@ utestpats = [
|
||||
],
|
||||
# warnings
|
||||
[
|
||||
(r'^ (?!.*127\.0\.0\.1)[^*?/\n]* \(glob\)$',
|
||||
"glob match with no glob string (?, *, /, and 127.0.0.1)"),
|
||||
(r'^ (?!.*\$LOCALIP)[^*?/\n]* \(glob\)$',
|
||||
"glob match with no glob string (?, *, /, and $LOCALIP)"),
|
||||
]
|
||||
]
|
||||
|
||||
|
@ -1034,7 +1034,7 @@ checkcodeglobpats = [
|
||||
re.compile(br'^pulling from \$TESTTMP/.*[^)]$'),
|
||||
# Not all platforms have 127.0.0.1 as loopback (though most do),
|
||||
# so we always glob that too.
|
||||
re.compile(br'.*127.0.0.1.*$'),
|
||||
re.compile(br'.*\$LOCALIP.*$'),
|
||||
]
|
||||
|
||||
bchr = chr
|
||||
@ -1342,7 +1342,7 @@ class TTest(Test):
|
||||
return True
|
||||
return b'-glob'
|
||||
return True
|
||||
el = el.replace(b'127.0.0.1', b'*')
|
||||
el = el.replace(b'$LOCALIP', b'*')
|
||||
i, n = 0, len(el)
|
||||
res = b''
|
||||
while i < n:
|
||||
|
@ -735,9 +735,11 @@ backslash on end of line with glob matching is handled properly
|
||||
|
||||
$ rm -f test-glob-backslash.t
|
||||
|
||||
Test globbing of 127.0.0.1
|
||||
Test globbing of local IP addresses
|
||||
$ echo 172.16.18.1
|
||||
127.0.0.1 (glob)
|
||||
$LOCALIP (glob)
|
||||
$ echo dead:beef::1
|
||||
$LOCALIP (glob)
|
||||
|
||||
Test reusability for third party tools
|
||||
======================================
|
||||
|
Loading…
Reference in New Issue
Block a user