38 lines
414 B
Plaintext
Executable File
38 lines
414 B
Plaintext
Executable File
#!/usr/bin/expect
|
|
|
|
spawn make term
|
|
|
|
set timeout 5
|
|
expect {
|
|
"test_shell" {}
|
|
timeout { exit 1 }
|
|
}
|
|
|
|
set timeout 1
|
|
|
|
send "\n"
|
|
send "\n"
|
|
expect {
|
|
">" {}
|
|
timeout { exit 1 }
|
|
}
|
|
|
|
send "start_test\n"
|
|
expect {
|
|
"\[TEST_START\]" {}
|
|
timeout { exit 1 }
|
|
}
|
|
|
|
expect {
|
|
">" {}
|
|
timeout { exit 1 }
|
|
}
|
|
|
|
send "end_test\n"
|
|
expect {
|
|
"\[TEST_END\]" {}
|
|
timeout { exit 1 }
|
|
}
|
|
|
|
puts "\nTest successful!\n"
|