2011-10-30 18:13:50 -04:00
|
|
|
! Copyright (C) 2011 Doug Coleman.
|
|
|
|
! See http://factorcode.org/license.txt for BSD license.
|
2014-04-22 10:40:57 -04:00
|
|
|
USING: environment io.standard-paths io.standard-paths.unix
|
|
|
|
sequences tools.test ;
|
2011-10-30 18:13:50 -04:00
|
|
|
IN: io.standard-paths.unix.tests
|
|
|
|
|
2014-03-11 14:37:00 -04:00
|
|
|
{ f } [ "" find-in-path ] unit-test
|
|
|
|
{ t } [
|
|
|
|
"ls" find-in-path { "/bin/ls" "/usr/bin/ls" } member?
|
|
|
|
] unit-test
|
2014-04-22 02:17:44 -04:00
|
|
|
|
2014-04-22 10:40:57 -04:00
|
|
|
{ t } [
|
|
|
|
"/sbin:" "PATH" os-env append "PATH" [
|
2017-07-02 11:17:46 -04:00
|
|
|
"ps" find-in-path
|
2017-07-02 18:56:55 -04:00
|
|
|
{ "/bin/ps" "/sbin/ps" "/usr/bin/ps" } member?
|
2014-04-22 10:40:57 -04:00
|
|
|
] with-os-env
|
|
|
|
] unit-test
|