Skip to content

Commit

Permalink
Dev: testcases: Adjust origin regression test based on previous changes
Browse files Browse the repository at this point in the history
  • Loading branch information
liangxin1300 committed Nov 7, 2022
1 parent 270a3b3 commit 1455848
Show file tree
Hide file tree
Showing 14 changed files with 964 additions and 289 deletions.
2 changes: 0 additions & 2 deletions test/features/resource_set.feature
Original file line number Diff line number Diff line change
Expand Up @@ -28,8 +28,6 @@ Feature: Use "crm configure set" to update attributes and operations
Then Except "ERROR: configure.set: Object xxxx not found"
When Try "crm configure set d.name value"
Then Except "ERROR: configure.set: Attribute not found: d.name"
When Try "crm configure set d.start.timeout 30"
Then Except "ERROR: configure.set: Operation "start" not found for resource d"
When Try "crm configure set d.monitor.100.timeout 10"
Then Except "ERROR: configure.set: Operation "monitor" interval "100" not found for resource d"
When Try "crm configure set s.monitor.interval 20"
Expand Down
15 changes: 11 additions & 4 deletions test/testcases/acl.exp
Original file line number Diff line number Diff line change
Expand Up @@ -27,13 +27,20 @@
.EXT cib metadata
.INP: show
node node1
primitive d0 ocf:pacemaker:Dummy
primitive d1 ocf:pacemaker:Dummy
primitive d0 ocf:pacemaker:Dummy \
op monitor timeout=20s interval=10s \
op start timeout=20s interval=0s \
op stop timeout=20s interval=0s
primitive d1 ocf:pacemaker:Dummy \
op monitor timeout=20s interval=10s \
op start timeout=20s interval=0s \
op stop timeout=20s interval=0s
primitive st stonith:ssh \
params hostlist=node1 \
meta target-role=Started requires=nothing \
op start timeout=60s interval=0 \
op monitor interval=60m timeout=60s
op start timeout=60s interval=0s \
op monitor interval=60m timeout=60s \
op stop timeout=15 interval=0s
property cib-bootstrap-options: \
enable-acl=true
role basic-read \
Expand Down
106 changes: 84 additions & 22 deletions test/testcases/bugs.exp
Original file line number Diff line number Diff line change
Expand Up @@ -31,13 +31,33 @@ node node1
primitive st stonith:null \
params hostlist=node1 \
meta description="some description here" requires=nothing \
op monitor interval=60m
primitive p4 Dummy
primitive p3 Dummy
primitive p2 Dummy
primitive p1 Dummy
primitive p5 Dummy
primitive p6 Dummy
op monitor interval=60m timeout=20 \
op start timeout=20 interval=0s \
op stop timeout=15 interval=0s
primitive p4 Dummy \
op monitor timeout=20s interval=10s \
op start timeout=20s interval=0s \
op stop timeout=20s interval=0s
primitive p3 Dummy \
op monitor timeout=20s interval=10s \
op start timeout=20s interval=0s \
op stop timeout=20s interval=0s
primitive p2 Dummy \
op monitor timeout=20s interval=10s \
op start timeout=20s interval=0s \
op stop timeout=20s interval=0s
primitive p1 Dummy \
op monitor timeout=20s interval=10s \
op start timeout=20s interval=0s \
op stop timeout=20s interval=0s
primitive p5 Dummy \
op monitor timeout=20s interval=10s \
op start timeout=20s interval=0s \
op stop timeout=20s interval=0s
primitive p6 Dummy \
op monitor timeout=20s interval=10s \
op start timeout=20s interval=0s \
op stop timeout=20s interval=0s
clone cl-p5 p5
colocation c2 inf: ( p1 p2 ) p3 p4
.INP: commit
Expand All @@ -48,13 +68,33 @@ node node1
primitive st stonith:null \
params hostlist=node1 \
meta description="some description here" requires=nothing \
op monitor interval=60m
primitive p4 Dummy
primitive p3 Dummy
primitive p2 Dummy
primitive p1 Dummy
primitive p6 Dummy
primitive p5 Dummy
op monitor interval=60m timeout=20 \
op start timeout=20 interval=0s \
op stop timeout=15 interval=0s
primitive p4 Dummy \
op monitor timeout=20s interval=10s \
op start timeout=20s interval=0s \
op stop timeout=20s interval=0s
primitive p3 Dummy \
op monitor timeout=20s interval=10s \
op start timeout=20s interval=0s \
op stop timeout=20s interval=0s
primitive p2 Dummy \
op monitor timeout=20s interval=10s \
op start timeout=20s interval=0s \
op stop timeout=20s interval=0s
primitive p1 Dummy \
op monitor timeout=20s interval=10s \
op start timeout=20s interval=0s \
op stop timeout=20s interval=0s
primitive p6 Dummy \
op monitor timeout=20s interval=10s \
op start timeout=20s interval=0s \
op stop timeout=20s interval=0s
primitive p5 Dummy \
op monitor timeout=20s interval=10s \
op start timeout=20s interval=0s \
op stop timeout=20s interval=0s
clone cl-p5 p5
colocation c2 inf: ( p1 p2 ) p3 p4
.TRY Unordered load file
Expand All @@ -70,12 +110,30 @@ INFO: 2: "sort_elements" is accepted as "sort-elements"
node node1
primitive st stonith:null \
params hostlist=node1
primitive p4 Dummy
primitive p3 Dummy
primitive p2 Dummy
primitive p1 Dummy
primitive p6 Dummy
primitive p5 Dummy
primitive p4 Dummy \
op monitor timeout=20s interval=10s \
op start timeout=20s interval=0s \
op stop timeout=20s interval=0s
primitive p3 Dummy \
op monitor timeout=20s interval=10s \
op start timeout=20s interval=0s \
op stop timeout=20s interval=0s
primitive p2 Dummy \
op monitor timeout=20s interval=10s \
op start timeout=20s interval=0s \
op stop timeout=20s interval=0s
primitive p1 Dummy \
op monitor timeout=20s interval=10s \
op start timeout=20s interval=0s \
op stop timeout=20s interval=0s
primitive p6 Dummy \
op monitor timeout=20s interval=10s \
op start timeout=20s interval=0s \
op stop timeout=20s interval=0s
primitive p5 Dummy \
op monitor timeout=20s interval=10s \
op start timeout=20s interval=0s \
op stop timeout=20s interval=0s
primitive gr1 Dummy
primitive gr2 Dummy
primitive gr3 Dummy
Expand Down Expand Up @@ -109,7 +167,9 @@ node node1
primitive st stonith:null \
params hostlist=node1 \
meta description="some description here" requires=nothing \
op monitor interval=60m
op monitor interval=60m timeout=20 \
op start timeout=20 interval=0s \
op stop timeout=15 interval=0s
property SAPHanaSR: \
hana_ha1_site_lss_WDF1=4
.INP: commit
Expand All @@ -121,7 +181,9 @@ node node1
primitive st stonith:null \
params hostlist=node1 \
meta description="some description here" requires=nothing \
op monitor interval=60m
op monitor interval=60m timeout=20 \
op start timeout=20 interval=0s \
op stop timeout=15 interval=0s
property SAPHanaSR: \
hana_ha1_site_lss_WDF1=4
property SAPHanaSR_2: \
Expand Down
16 changes: 11 additions & 5 deletions test/testcases/bundle.exp
Original file line number Diff line number Diff line change
Expand Up @@ -27,15 +27,21 @@ node node1 \
node node2 \
utilization cpu=4
primitive dummy Dummy \
op monitor interval=10 \
meta target-role=Stopped
meta target-role=Stopped \
op monitor interval=10 timeout=20s \
op start timeout=20s interval=0s \
op stop timeout=20s interval=0s
primitive st stonith:ssh \
params hostlist="node1 node2" \
meta target-role=Started requires=nothing \
op start timeout=60s interval=0 \
op monitor interval=60m timeout=60s
op start timeout=60s interval=0s \
op monitor interval=60m timeout=60s \
op stop timeout=15 interval=0s
primitive st2 stonith:ssh \
params hostlist="node1 node2"
params hostlist="node1 node2" \
op monitor timeout=20 interval=3600 \
op start timeout=20 interval=0s \
op stop timeout=15 interval=0s
bundle bundle-test1 \
docker image=test \
network ip-range-start=10.10.10.123 port-mapping id=port1 port=80 \
Expand Down
32 changes: 24 additions & 8 deletions test/testcases/commit.exp
Original file line number Diff line number Diff line change
Expand Up @@ -50,18 +50,34 @@ WARNING: 35: st: unknown attribute 'yoyo-meta'
.INP: show
node node1 \
attributes mem=16G
primitive d1 Dummy
primitive d3 Dummy
primitive d1 Dummy \
op monitor timeout=20s interval=10s \
op start timeout=20s interval=0s \
op stop timeout=20s interval=0s
primitive d3 Dummy \
op monitor timeout=20s interval=10s \
op start timeout=20s interval=0s \
op stop timeout=20s interval=0s
primitive p1 Dummy \
op monitor interval=60m \
op monitor interval=120m \
op_params OCF_CHECK_LEVEL=10
primitive p2 Dummy
primitive p3 Dummy
op monitor interval=60m timeout=20s \
op monitor interval=120m timeout=20s \
op_params OCF_CHECK_LEVEL=10 \
op start timeout=20s interval=0s \
op stop timeout=20s interval=0s
primitive p2 Dummy \
op monitor timeout=20s interval=10s \
op start timeout=20s interval=0s \
op stop timeout=20s interval=0s
primitive p3 Dummy \
op monitor timeout=20s interval=10s \
op start timeout=20s interval=0s \
op stop timeout=20s interval=0s
primitive st stonith:null \
params hostlist=node1 \
meta yoyo-meta="yoyo 2" requires=nothing \
op monitor interval=60m
op monitor interval=60m timeout=20 \
op start timeout=20 interval=0s \
op stop timeout=15 interval=0s
group g1 d1 p2
group g2 d3
colocation cl1 inf: g1 p3
Expand Down
Loading

0 comments on commit 1455848

Please sign in to comment.