Sign Up
Log In
Log In
or
Sign Up
Places
All Projects
Status Monitor
Collapse sidebar
openSUSE:12.2:PowerPC
pacemaker
pacemaker-crm_ticket-tests-standby.diff
Overview
Repositories
Revisions
Requests
Users
Attributes
Meta
File pacemaker-crm_ticket-tests-standby.diff of Package pacemaker
commit 0f60f521e85fac6f185f6f5fb71163f7a3772e2b Author: Gao,Yan <ygao@suse.com> Date: Sat Mar 24 09:40:00 2012 +0800 Low: Tools: Add CLI regression tests for ticket standby state diff --git a/tools/regression.exp b/tools/regression.exp index af3fed9..342a8fa 100755 --- a/tools/regression.exp +++ b/tools/regression.exp @@ -842,7 +842,7 @@ false </node_state> </status> </cib> -* Passed: crm_ticket - Default granted-ticket value +* Passed: crm_ticket - Default ticket granted state <cib epoch="18" num_updates="2" admin_epoch="0" validate-with="pacemaker-1.2" > <configuration> <crm_config> @@ -881,7 +881,7 @@ false </tickets> </status> </cib> -* Passed: crm_ticket - Set granted-ticket value +* Passed: crm_ticket - Set ticket granted state false <cib epoch="18" num_updates="2" admin_epoch="0" validate-with="pacemaker-1.2" > <configuration> @@ -921,7 +921,7 @@ false </tickets> </status> </cib> -* Passed: crm_ticket - Query granted-ticket value +* Passed: crm_ticket - Query ticket granted state Deleted ticketA state attribute: name=granted <cib epoch="18" num_updates="3" admin_epoch="0" validate-with="pacemaker-1.2" > <configuration> @@ -961,4 +961,162 @@ Deleted ticketA state attribute: name=granted </tickets> </status> </cib> -* Passed: crm_ticket - Delete granted-ticket value +* Passed: crm_ticket - Delete ticket granted state +<cib epoch="18" num_updates="4" admin_epoch="0" validate-with="pacemaker-1.2" > + <configuration> + <crm_config> + <cluster_property_set id="cib-bootstrap-options"/> + <cluster_property_set id="duplicate"> + <nvpair id="duplicate-cluster-delay" name="cluster-delay" value="30s"/> + </cluster_property_set> + </crm_config> + <nodes> + <node id="clusterNode-UUID" uname="clusterNode-UNAME" type="member"> + <instance_attributes id="nodes-clusterNode-UUID"> + <nvpair id="nodes-clusterNode-UUID-ram" name="ram" value="1024M"/> + </instance_attributes> + </node> + </nodes> + <resources> + <primitive id="dummy" class="ocf" provider="pacemaker" type="Dummy"> + <meta_attributes id="dummy-meta_attributes"/> + <instance_attributes id="dummy-instance_attributes"> + <nvpair id="dummy-instance_attributes-delay" name="delay" value="10s"/> + </instance_attributes> + </primitive> + </resources> + <constraints/> + </configuration> + <status> + <node_state id="clusterNode-UUID" uname="clusterNode-UNAME"> + <transient_attributes id="clusterNode-UUID"> + <instance_attributes id="status-clusterNode-UUID"> + <nvpair id="status-clusterNode-UUID-fail-count-dummy" name="fail-count-dummy" value="10"/> + </instance_attributes> + </transient_attributes> + </node_state> + <tickets> + <ticket_state id="ticketA" standby="true"/> + </tickets> + </status> +</cib> +* Passed: crm_ticket - Make a ticket standby +true +<cib epoch="18" num_updates="4" admin_epoch="0" validate-with="pacemaker-1.2" > + <configuration> + <crm_config> + <cluster_property_set id="cib-bootstrap-options"/> + <cluster_property_set id="duplicate"> + <nvpair id="duplicate-cluster-delay" name="cluster-delay" value="30s"/> + </cluster_property_set> + </crm_config> + <nodes> + <node id="clusterNode-UUID" uname="clusterNode-UNAME" type="member"> + <instance_attributes id="nodes-clusterNode-UUID"> + <nvpair id="nodes-clusterNode-UUID-ram" name="ram" value="1024M"/> + </instance_attributes> + </node> + </nodes> + <resources> + <primitive id="dummy" class="ocf" provider="pacemaker" type="Dummy"> + <meta_attributes id="dummy-meta_attributes"/> + <instance_attributes id="dummy-instance_attributes"> + <nvpair id="dummy-instance_attributes-delay" name="delay" value="10s"/> + </instance_attributes> + </primitive> + </resources> + <constraints/> + </configuration> + <status> + <node_state id="clusterNode-UUID" uname="clusterNode-UNAME"> + <transient_attributes id="clusterNode-UUID"> + <instance_attributes id="status-clusterNode-UUID"> + <nvpair id="status-clusterNode-UUID-fail-count-dummy" name="fail-count-dummy" value="10"/> + </instance_attributes> + </transient_attributes> + </node_state> + <tickets> + <ticket_state id="ticketA" standby="true"/> + </tickets> + </status> +</cib> +* Passed: crm_ticket - Query ticket standby state +<cib epoch="18" num_updates="5" admin_epoch="0" validate-with="pacemaker-1.2" > + <configuration> + <crm_config> + <cluster_property_set id="cib-bootstrap-options"/> + <cluster_property_set id="duplicate"> + <nvpair id="duplicate-cluster-delay" name="cluster-delay" value="30s"/> + </cluster_property_set> + </crm_config> + <nodes> + <node id="clusterNode-UUID" uname="clusterNode-UNAME" type="member"> + <instance_attributes id="nodes-clusterNode-UUID"> + <nvpair id="nodes-clusterNode-UUID-ram" name="ram" value="1024M"/> + </instance_attributes> + </node> + </nodes> + <resources> + <primitive id="dummy" class="ocf" provider="pacemaker" type="Dummy"> + <meta_attributes id="dummy-meta_attributes"/> + <instance_attributes id="dummy-instance_attributes"> + <nvpair id="dummy-instance_attributes-delay" name="delay" value="10s"/> + </instance_attributes> + </primitive> + </resources> + <constraints/> + </configuration> + <status> + <node_state id="clusterNode-UUID" uname="clusterNode-UNAME"> + <transient_attributes id="clusterNode-UUID"> + <instance_attributes id="status-clusterNode-UUID"> + <nvpair id="status-clusterNode-UUID-fail-count-dummy" name="fail-count-dummy" value="10"/> + </instance_attributes> + </transient_attributes> + </node_state> + <tickets> + <ticket_state id="ticketA" standby="false"/> + </tickets> + </status> +</cib> +* Passed: crm_ticket - Activate a ticket +Deleted ticketA state attribute: name=standby +<cib epoch="18" num_updates="6" admin_epoch="0" validate-with="pacemaker-1.2" > + <configuration> + <crm_config> + <cluster_property_set id="cib-bootstrap-options"/> + <cluster_property_set id="duplicate"> + <nvpair id="duplicate-cluster-delay" name="cluster-delay" value="30s"/> + </cluster_property_set> + </crm_config> + <nodes> + <node id="clusterNode-UUID" uname="clusterNode-UNAME" type="member"> + <instance_attributes id="nodes-clusterNode-UUID"> + <nvpair id="nodes-clusterNode-UUID-ram" name="ram" value="1024M"/> + </instance_attributes> + </node> + </nodes> + <resources> + <primitive id="dummy" class="ocf" provider="pacemaker" type="Dummy"> + <meta_attributes id="dummy-meta_attributes"/> + <instance_attributes id="dummy-instance_attributes"> + <nvpair id="dummy-instance_attributes-delay" name="delay" value="10s"/> + </instance_attributes> + </primitive> + </resources> + <constraints/> + </configuration> + <status> + <node_state id="clusterNode-UUID" uname="clusterNode-UNAME"> + <transient_attributes id="clusterNode-UUID"> + <instance_attributes id="status-clusterNode-UUID"> + <nvpair id="status-clusterNode-UUID-fail-count-dummy" name="fail-count-dummy" value="10"/> + </instance_attributes> + </transient_attributes> + </node_state> + <tickets> + <ticket_state id="ticketA"/> + </tickets> + </status> +</cib> +* Passed: crm_ticket - Delete ticket standby state diff --git a/tools/regression.sh b/tools/regression.sh index e8844ec..e7ef151 100755 --- a/tools/regression.sh +++ b/tools/regression.sh @@ -171,16 +171,28 @@ function test_tools() { assert $? 0 crm_resource "Un-migrate a resource" crm_ticket -t ticketA -G granted -d false - assert $? 0 crm_ticket "Default ticket state attribute" + assert $? 0 crm_ticket "Default ticket granted state" crm_ticket -t ticketA -r --force - assert $? 0 crm_ticket "Set ticket state attribute" + assert $? 0 crm_ticket "Set ticket granted state" crm_ticket -t ticketA -G granted - assert $? 0 crm_ticket "Query ticket state attribute" + assert $? 0 crm_ticket "Query ticket granted state" crm_ticket -t ticketA -D granted --force - assert $? 0 crm_ticket "Delete ticket state attribute" + assert $? 0 crm_ticket "Delete ticket granted state" + + crm_ticket -t ticketA -s + assert $? 0 crm_ticket "Make a ticket standby" + + crm_ticket -t ticketA -G standby + assert $? 0 crm_ticket "Query ticket standby state" + + crm_ticket -t ticketA -a + assert $? 0 crm_ticket "Activate a ticket" + + crm_ticket -t ticketA -D standby + assert $? 0 crm_ticket "Delete ticket standby state" } test_tools 2>&1 | sed s/cib-last-written.*\>/\>/ > $test_home/regression.out
Locations
Projects
Search
Status Monitor
Help
OpenBuildService.org
Documentation
API Documentation
Code of Conduct
Contact
Support
@OBShq
Terms
openSUSE Build Service is sponsored by
The Open Build Service is an
openSUSE project
.
Sign Up
Log In
Places
Places
All Projects
Status Monitor