| 1 |
#!/bin/bash |
| 2 |
|
| 3 |
## Include utility functions. |
| 4 |
. "$XDG_TEST_DIR/include/testassertions.sh" |
| 5 |
. "$XDG_TEST_DIR/include/testcontrol.sh" |
| 6 |
|
| 7 |
## Test function |
| 8 |
test_email_basic() { |
| 9 |
test_start "$FUNCNAME: verify basic email compose" |
| 10 |
|
| 11 |
ADDR="[email protected]" |
| 12 |
|
| 13 |
test_init |
| 14 |
|
| 15 |
require_notroot |
| 16 |
## Require a running X server |
| 17 |
assert_display |
| 18 |
|
| 19 |
test_procedure |
| 20 |
|
| 21 |
assert_exit 0 xdg-email "$PRE$ADDR" |
| 22 |
assert_nostdout |
| 23 |
assert_nostderr |
| 24 |
|
| 25 |
assert_interactive "Did a new email open to '$ADDR' with only the to: field complete?" y |
| 26 |
assert_interactive "Please close any email windows opened by the test." C |
| 27 |
|
| 28 |
test_result |
| 29 |
} |
| 30 |
|
| 31 |
repeat_test test_email_basic 1 PRE "" "mailto:" |