2013-05-29 14:28:57 +00:00
|
|
|
#! /bin/bash
|
|
|
|
|
2022-04-30 20:05:42 +00:00
|
|
|
run_cap_test ./drive_sql "select readlink('non-existent-link')"
|
2021-01-31 22:19:14 +00:00
|
|
|
|
|
|
|
ln -sf sql_fs_readlink_test sql_fs_readlink_test.lnk
|
2022-04-30 20:05:42 +00:00
|
|
|
run_cap_test ./drive_sql "select readlink('sql_fs_readlink_test.lnk')"
|
2021-01-31 22:19:14 +00:00
|
|
|
rm sql_fs_readlink_test.lnk
|
|
|
|
|
2022-04-30 20:05:42 +00:00
|
|
|
run_cap_test ./drive_sql "select realpath('non-existent-path')"
|
2021-01-31 23:01:11 +00:00
|
|
|
|
2022-05-01 04:50:35 +00:00
|
|
|
# ln -sf drive_sql sql_fs_realpath_test.lnk
|
|
|
|
# run_cap_test ./drive_sql "select realpath('sql_fs_realpath_test.lnk')"
|
|
|
|
# rm sql_fs_realpath_test.lnk
|
2021-01-31 22:41:24 +00:00
|
|
|
|
2022-04-30 20:05:42 +00:00
|
|
|
run_cap_test ./drive_sql "select basename('')"
|
2013-05-29 14:28:57 +00:00
|
|
|
|
2022-04-30 20:05:42 +00:00
|
|
|
run_cap_test ./drive_sql "select basename('/')"
|
2013-05-29 14:28:57 +00:00
|
|
|
|
2022-04-30 20:05:42 +00:00
|
|
|
run_cap_test ./drive_sql "select basename('//')"
|
2013-05-29 14:28:57 +00:00
|
|
|
|
2022-04-30 20:05:42 +00:00
|
|
|
run_cap_test ./drive_sql "select basename('/foo')"
|
2013-05-29 14:28:57 +00:00
|
|
|
|
2022-04-30 20:05:42 +00:00
|
|
|
run_cap_test ./drive_sql "select basename('foo/bar')"
|
2013-05-29 14:28:57 +00:00
|
|
|
|
2022-04-30 20:05:42 +00:00
|
|
|
run_cap_test ./drive_sql "select basename('/foo/')"
|
2013-05-29 14:28:57 +00:00
|
|
|
|
2022-04-30 20:05:42 +00:00
|
|
|
run_cap_test ./drive_sql "select basename('/foo///')"
|
2013-05-29 14:28:57 +00:00
|
|
|
|
2022-04-30 20:05:42 +00:00
|
|
|
run_cap_test ./drive_sql "select basename('foo')"
|
2013-05-29 14:28:57 +00:00
|
|
|
|
2022-04-30 20:05:42 +00:00
|
|
|
run_cap_test ./drive_sql "select dirname('')"
|
2013-05-29 14:28:57 +00:00
|
|
|
|
2022-04-30 20:05:42 +00:00
|
|
|
run_cap_test ./drive_sql "select dirname('foo')"
|
2013-05-29 14:28:57 +00:00
|
|
|
|
2022-04-30 20:05:42 +00:00
|
|
|
run_cap_test ./drive_sql "select dirname('foo///')"
|
2013-05-29 14:28:57 +00:00
|
|
|
|
2022-04-30 20:05:42 +00:00
|
|
|
run_cap_test ./drive_sql "select dirname('/foo/bar')"
|
2013-05-29 14:28:57 +00:00
|
|
|
|
2022-04-30 20:05:42 +00:00
|
|
|
run_cap_test ./drive_sql "select dirname('/')"
|
2013-05-29 14:28:57 +00:00
|
|
|
|
2022-04-30 20:05:42 +00:00
|
|
|
run_cap_test ./drive_sql "select dirname('/foo')"
|
2013-05-29 14:28:57 +00:00
|
|
|
|
2022-04-30 20:05:42 +00:00
|
|
|
run_cap_test ./drive_sql "select dirname('/foo//')"
|
2013-05-29 14:28:57 +00:00
|
|
|
|
2022-04-30 20:05:42 +00:00
|
|
|
run_cap_test ./drive_sql "select dirname('foo//')"
|
2013-05-29 14:28:57 +00:00
|
|
|
|
2022-04-30 20:05:42 +00:00
|
|
|
run_cap_test ./drive_sql "select joinpath()"
|
2013-05-29 14:28:57 +00:00
|
|
|
|
2022-04-30 20:05:42 +00:00
|
|
|
run_cap_test ./drive_sql "select joinpath('foo')"
|
2013-05-29 14:28:57 +00:00
|
|
|
|
2022-04-30 20:05:42 +00:00
|
|
|
run_cap_test ./drive_sql "select joinpath('foo', 'bar', 'baz')"
|
2013-05-29 14:28:57 +00:00
|
|
|
|
2022-04-30 20:05:42 +00:00
|
|
|
run_cap_test ./drive_sql "select joinpath('foo', 'bar', 'baz', '/root')"
|
2023-07-31 04:17:52 +00:00
|
|
|
|
2023-08-05 14:20:17 +00:00
|
|
|
run_cap_test ${lnav_test} -Nn -c ";SELECT shell_exec('echo hi')"
|