| 1 |
# exportfs |
| 2 |
# |
| 3 |
# |
| 4 |
|
| 5 |
CONFIG |
| 6 |
Agent exportfs |
| 7 |
AgentRoot /usr/lib/ocf/resource.d/heartbeat |
| 8 |
InstallPackage nfs-kernel-server |
| 9 |
HangTimeout 40 |
| 10 |
|
| 11 |
SETUP-AGENT |
| 12 |
# nothing |
| 13 |
|
| 14 |
CASE-BLOCK set_testenv |
| 15 |
Env OCF_RESKEY_directory=/usr |
| 16 |
Env OCF_RESKEY_fsid=105 |
| 17 |
Env OCF_RESKEY_clientspec="*" |
| 18 |
Env OCF_RESKEY_CRM_meta_timeout=30000 |
| 19 |
|
| 20 |
CASE-BLOCK default_status |
| 21 |
AgentRun stop |
| 22 |
|
| 23 |
CASE-BLOCK prepare |
| 24 |
Include set_testenv |
| 25 |
Include default_status |
| 26 |
|
| 27 |
CASE "check base env" |
| 28 |
Include prepare |
| 29 |
AgentRun start OCF_SUCCESS |
| 30 |
|
| 31 |
CASE "check base env: invalid 'OCF_RESKEY_directory'" |
| 32 |
Include prepare |
| 33 |
Env OCF_RESKEY_directory=/no_such |
| 34 |
AgentRun start OCF_ERR_CONFIGURED |
| 35 |
|
| 36 |
CASE "check base env: non-decimal 'OCF_RESKEY_fsid'" |
| 37 |
Include prepare |
| 38 |
Env OCF_RESKEY_fsid="4f838db14f838db14f838db14f838db1" |
| 39 |
AgentRun start OCF_SUCCESS |
| 40 |
|
| 41 |
CASE "unimplemented command" |
| 42 |
Include prepare |
| 43 |
AgentRun no_cmd OCF_ERR_UNIMPLEMENTED |
| 44 |
|
| 45 |
CASE "normal start" |
| 46 |
Include prepare |
| 47 |
AgentRun start OCF_SUCCESS |
| 48 |
|
| 49 |
CASE "normal stop" |
| 50 |
Include prepare |
| 51 |
AgentRun start |
| 52 |
AgentRun stop OCF_SUCCESS |
| 53 |
|
| 54 |
CASE "double start" |
| 55 |
Include prepare |
| 56 |
AgentRun start |
| 57 |
AgentRun start OCF_SUCCESS |
| 58 |
|
| 59 |
CASE "double stop" |
| 60 |
Include prepare |
| 61 |
AgentRun stop OCF_SUCCESS |
| 62 |
|
| 63 |
CASE "stop with no env" |
| 64 |
Include prepare |
| 65 |
Env OCF_RESKEY_directory=/no_such |
| 66 |
AgentRun stop OCF_SUCCESS |
| 67 |
|
| 68 |
CASE "started: monitor" |
| 69 |
Include prepare |
| 70 |
AgentRun start |
| 71 |
AgentRun monitor OCF_SUCCESS |
| 72 |
|
| 73 |
CASE "not started: monitor" |
| 74 |
Include prepare |
| 75 |
AgentRun monitor OCF_NOT_RUNNING |