Test
This commit is contained in:
parent
0d2b2bd30d
commit
e16cef2ed0
2 changed files with 11 additions and 11 deletions
|
|
@ -9,6 +9,7 @@ recommend:
|
|||
- mailcap
|
||||
- mutt
|
||||
- expect
|
||||
- tmux
|
||||
duration: 20m
|
||||
enabled: true
|
||||
tag:
|
||||
|
|
|
|||
|
|
@ -62,26 +62,25 @@ rlJournalStart
|
|||
rlPhaseEnd
|
||||
|
||||
rlPhaseStartTest
|
||||
# Spustit mutt s výstupem do souboru pro ladění
|
||||
mutt -d 5 2> mutt_debug.log &
|
||||
|
||||
# Získat PID procesu mutt
|
||||
MUTT_PID=$!
|
||||
# Vytvořit nové tmux sezení a spustit mutt
|
||||
tmux new-session -d -s mysession 'mutt -d 5'
|
||||
|
||||
# Čekat chvíli, aby se mutt spustil
|
||||
sleep 2
|
||||
# Čekat chvíli, aby se mutt spustil
|
||||
sleep 2
|
||||
|
||||
# Poslat vstup do procesu mutt
|
||||
echo -e "\rqq" > /proc/$MUTT_PID/fd/0
|
||||
# Poslat klávesové vstupy do tmux sezení
|
||||
tmux send-keys -t mysession Enter 'qq'
|
||||
|
||||
# Čekat na dokončení mutt
|
||||
wait $MUTT_PID
|
||||
#rlRun "chmod +x ./test.exp"
|
||||
# Čekat na dokončení mutt
|
||||
tmux wait-for -S mysession
|
||||
#lRun "chmod +x ./test.exp"
|
||||
#rlRun "./test.exp"
|
||||
# script -qfec 'expect -f ./mutt.exp'
|
||||
#rlRun "ls /dev" 0 "Get me tty list"
|
||||
#rlRun "cat typescript" 0 "Get me log"
|
||||
#rlRun "cat ~/.muttdebug0" 0 "Get me debug of mutt"
|
||||
bash
|
||||
rlAssertGrep "123 hello world We are here" /tmp/testing
|
||||
rlPhaseEnd
|
||||
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue