firejail/test/environment/rlimit-bad-profile.exp
2025-09-12 10:34:02 +00:00

51 lines
1 KiB
Text
Executable file

#!/usr/bin/expect -f
# This file is part of Firejail project
# Copyright (C) 2014-2025 Firejail Authors
# License GPL v2
set timeout 10
spawn $env(SHELL)
match_max 100000
send -- "firejail --profile=rlimit-bad-as.profile\r"
expect {
timeout {puts "TESTING ERROR 0\n";exit}
"invalid rlimit-as:"
}
after 100
send -- "firejail --profile=rlimit-bad-cpu.profile\r"
expect {
timeout {puts "TESTING ERROR 1\n";exit}
"invalid rlimit-cpu:"
}
after 100
send -- "firejail --profile=rlimit-bad-fsize.profile\r"
expect {
timeout {puts "TESTING ERROR 2\n";exit}
"invalid rlimit-fsize:"
}
after 100
send -- "firejail --profile=rlimit-bad-nofile.profile\r"
expect {
timeout {puts "TESTING ERROR 3\n";exit}
"invalid rlimit-nofile:"
}
after 100
send -- "firejail --profile=rlimit-bad-nproc.profile\r"
expect {
timeout {puts "TESTING ERROR 4\n";exit}
"invalid rlimit-nproc:"
}
after 100
send -- "firejail --profile=rlimit-bad-sigpending.profile\r"
expect {
timeout {puts "TESTING ERROR 5\n";exit}
"invalid rlimit-sigpending:"
}
after 100
puts "\nall done\n"