Renamed unit test _known_hosts > _known_hosts_real
This commit is contained in:
parent
0b19577ed9
commit
b1d869cbf2
9
test/fixtures/_known_hosts/spaced conf
vendored
9
test/fixtures/_known_hosts/spaced conf
vendored
@ -1,9 +0,0 @@
|
|||||||
|
|
||||||
# Unindented
|
|
||||||
Host gee
|
|
||||||
UserKnownHostsFile "fixtures/_known_hosts/spaced known_hosts"
|
|
||||||
|
|
||||||
# Indented
|
|
||||||
Host hus # With comment
|
|
||||||
UserKnownHostsFile "fixtures/_known_hosts/known_hosts2"
|
|
||||||
|
|
@ -1,4 +1,4 @@
|
|||||||
UserKnownHostsFile fixtures/_known_hosts/known_hosts
|
UserKnownHostsFile fixtures/_known_hosts_real/known_hosts
|
||||||
|
|
||||||
# Unindented
|
# Unindented
|
||||||
Host gee
|
Host gee
|
9
test/fixtures/_known_hosts_real/spaced conf
vendored
Normal file
9
test/fixtures/_known_hosts_real/spaced conf
vendored
Normal file
@ -0,0 +1,9 @@
|
|||||||
|
|
||||||
|
# Unindented
|
||||||
|
Host gee
|
||||||
|
UserKnownHostsFile "fixtures/_known_hosts_real/spaced known_hosts"
|
||||||
|
|
||||||
|
# Indented
|
||||||
|
Host hus # With comment
|
||||||
|
UserKnownHostsFile "fixtures/_known_hosts_real/known_hosts2"
|
||||||
|
|
@ -17,13 +17,13 @@ set test "Hosts should be put in COMPREPLY"
|
|||||||
# Example string: host1\s+host2\s+host3
|
# Example string: host1\s+host2\s+host3
|
||||||
|
|
||||||
set hosts [exec bash -c "compgen -A hostname"]
|
set hosts [exec bash -c "compgen -A hostname"]
|
||||||
# Hosts `gee' and `hus' are defined in ./fixtures/_known_hosts/config
|
# Hosts `gee' and `hus' are defined in ./fixtures/_known_hosts_real/config
|
||||||
# Hosts `doo' and `ike' are defined in ./fixtures/_known_hosts/known_hosts
|
# Hosts `doo' and `ike' are defined in ./fixtures/_known_hosts_real/known_hosts
|
||||||
lappend hosts doo gee hus ike
|
lappend hosts doo gee hus ike
|
||||||
set hosts [lsort -ascii $hosts]
|
set hosts [lsort -ascii $hosts]
|
||||||
set hosts [join $hosts "\\s+"]
|
set hosts [join $hosts "\\s+"]
|
||||||
# Call _known_hosts
|
# Call _known_hosts
|
||||||
set cmd {_known_hosts -aF fixtures/_known_hosts/config; echo_array COMPREPLY}
|
set cmd {_known_hosts -aF fixtures/_known_hosts_real/config; echo_array COMPREPLY}
|
||||||
send "$cmd\r"
|
send "$cmd\r"
|
||||||
expect -ex "$cmd\r\n"
|
expect -ex "$cmd\r\n"
|
||||||
expect {
|
expect {
|
||||||
@ -40,14 +40,14 @@ set test "Config file containing space should work"
|
|||||||
# Build string list of hostnames, separated by regexp whitespace marker (\s+).
|
# Build string list of hostnames, separated by regexp whitespace marker (\s+).
|
||||||
# Example string: host1\s+host2\s+host3
|
# Example string: host1\s+host2\s+host3
|
||||||
set hosts [exec bash -c "compgen -A hostname"]
|
set hosts [exec bash -c "compgen -A hostname"]
|
||||||
# Hosts `gee' and `hus' are defined in ./fixtures/_known_hosts/spaced conf
|
# Hosts `gee' and `hus' are defined in ./fixtures/_known_hosts_real/spaced conf
|
||||||
# Hosts `doo' and `ike' are defined in ./fixtures/_known_hosts/known_hosts
|
# Hosts `doo' and `ike' are defined in ./fixtures/_known_hosts_real/known_hosts
|
||||||
# Host `two' is defined in ./fixtures/_known_hosts/known_hosts2
|
# Host `two' is defined in ./fixtures/_known_hosts_real/known_hosts2
|
||||||
lappend hosts gee hus doo ike two
|
lappend hosts gee hus doo ike two
|
||||||
set hosts [lsort -ascii $hosts]
|
set hosts [lsort -ascii $hosts]
|
||||||
set hosts [join $hosts "\\s+"]
|
set hosts [join $hosts "\\s+"]
|
||||||
# Call _known_hosts
|
# Call _known_hosts
|
||||||
set cmd {_known_hosts -aF 'fixtures/_known_hosts/spaced conf'; echo_array COMPREPLY}
|
set cmd {_known_hosts -aF 'fixtures/_known_hosts_real/spaced conf'; echo_array COMPREPLY}
|
||||||
send "$cmd\r"
|
send "$cmd\r"
|
||||||
expect -ex "$cmd\r\n"
|
expect -ex "$cmd\r\n"
|
||||||
expect {
|
expect {
|
Loading…
x
Reference in New Issue
Block a user