2012-03-23 15:40:04 +05:30
|
|
|
#
|
|
|
|
# Testsuite for lib/fileutils program
|
|
|
|
#
|
|
|
|
|
|
|
|
set noarg "${topdir}lib/test_fileutils"
|
|
|
|
|
|
|
|
set test "without argument"
|
|
|
|
spawn $noarg
|
|
|
|
expect_pass "$test" "Hello, World!"
|
|
|
|
|
2021-02-24 15:11:38 +05:30
|
|
|
set badfd "${srcdir}/lib.test/fileutils_badfd.sh"
|
2012-03-23 15:40:04 +05:30
|
|
|
set test "test bad file descriptor"
|
|
|
|
spawn $badfd
|
|
|
|
expect_pass "$test" "test_fileutils: write error: Bad file descriptor"
|
|
|
|
|
2021-02-24 15:11:38 +05:30
|
|
|
set full "${srcdir}/lib.test/fileutils_full.sh"
|
2012-03-23 15:40:04 +05:30
|
|
|
set test "test no space left on device"
|
|
|
|
spawn $full
|
|
|
|
expect_pass "$test" "test_fileutils: write error: No space left on device"
|