#!/usr/bin/expect -f set timeout 10 spawn $env(SHELL) match_max 100000 send -- "firejail --private.keep=.mozilla,.config/firejail\r" expect { timeout {puts "TESTING ERROR 0\n";exit} "Child process initialized" } sleep 1 send -- "ls -al\r" expect { timeout {puts "TESTING ERROR 0.1\n";exit} ".config" } expect { timeout {puts "TESTING ERROR 0.2\n";exit} ".mozilla" } sleep 1 send -- "find .config\r" expect { timeout {puts "TESTING ERROR 0.3\n";exit} ".config" } expect { timeout {puts "TESTING ERROR 0.4\n";exit} ".config/firejail" } sleep 1 puts "\n" send -- "exit\r" sleep 2 send -- "firejail --profile=private-keep.profile\r" expect { timeout {puts "TESTING ERROR 1.0\n";exit} "Child process initialized" } sleep 1 send -- "ls -al\r" expect { timeout {puts "TESTING ERROR 1.1\n";exit} ".config" } expect { timeout {puts "TESTING ERROR 1.2\n";exit} ".mozilla" } sleep 1 send -- "find .config\r" expect { timeout {puts "TESTING ERROR 1.3\n";exit} ".config" } expect { timeout {puts "TESTING ERROR 1.4\n";exit} ".config/firejail" }