2 set pwdx "${topdir}pwdx"
3 # Run pwdx with no arguments
4 set test "pwdx no args"
6 expect_pass "$test" "^\\s*Usage:\\s+\(lt-\)\?pwdx \\\[options\\\] pid\.\.\."
8 # Run pwdx with pid 0 which is invalid
9 set test "pwdx pid 0 should be invalid"
11 expect_pass "$test" "\(lt-\)\?pwdx\: invalid process id\: 0"
13 # Run pwdx with existing pid
14 set test "pwdx finds sleep in cwd"
15 set sleep_pid [ exec sleep 600 & ]
17 spawn $pwdx $sleep_pid
18 expect_pass "$test" "^$sleep_pid: $sleep_pwd"