Committed by
Gerrit Code Review
Add Distributed Primitives scenario to smoke test
Change-Id: I9ad43c5a5562e90a10579758c6ffa45a3509c0f5
Showing
6 changed files
with
79 additions
and
119 deletions
... | @@ -14,66 +14,63 @@ | ... | @@ -14,66 +14,63 @@ |
14 | ~ limitations under the License. | 14 | ~ limitations under the License. |
15 | --> | 15 | --> |
16 | 16 | ||
17 | -<scenario name="distributed counter test" | 17 | +<scenario name="distributed-counter-test" |
18 | description="ONOS AtomicCounter distributed primitive Test"> | 18 | description="ONOS AtomicCounter distributed primitive Test"> |
19 | <group name="Distributed-Primitive-Counter"> | 19 | <group name="Distributed-Primitive-Counter"> |
20 | 20 | ||
21 | - <!--<import file="${ONOS_SCENARIOS}/setup.xml"/> | 21 | + <step name="Distributed-Primitive-Counter.Activate-Distributed-Primitives-App" |
22 | - <dependency name="Setup" requires="Prerequisites"/>--> | ||
23 | - | ||
24 | - <step name="Activate-Distributed-Primitives-App" | ||
25 | exec="onos ${OCI} app activate org.onosproject.distributedprimitives"/> | 22 | exec="onos ${OCI} app activate org.onosproject.distributedprimitives"/> |
26 | 23 | ||
27 | - <step name="Test-Counter-Initial-Value" requires="^" | 24 | + <step name="Distributed-Primitive-Counter.Test-Counter-Initial-Value" requires="Distributed-Primitive-Counter.Activate-Distributed-Primitives-App" |
28 | exec="onos-cluster-execute-expect counter-test test-counter get --expect 0"/> | 25 | exec="onos-cluster-execute-expect counter-test test-counter get --expect 0"/> |
29 | 26 | ||
30 | - <step name="Test-Counter-Set" requires="^" | 27 | + <step name="Distributed-Primitive-Counter.Test-Counter-Set" requires="Distributed-Primitive-Counter.Test-Counter-Initial-Value" |
31 | exec="onos ${OCI} counter-test test-counter set 1"/> | 28 | exec="onos ${OCI} counter-test test-counter set 1"/> |
32 | 29 | ||
33 | - <step name="Test-Counter-Get" requires="^" | 30 | + <step name="Distributed-Primitive-Counter.Test-Counter-Get" requires="Distributed-Primitive-Counter.Test-Counter-Set" |
34 | exec="onos-cluster-execute-expect counter-test test-counter get --expect 1"/> | 31 | exec="onos-cluster-execute-expect counter-test test-counter get --expect 1"/> |
35 | 32 | ||
36 | - <step name="Test-Counter-IncrementAndGet" requires="^" | 33 | + <step name="Distributed-Primitive-Counter.Test-Counter-IncrementAndGet" requires="Distributed-Primitive-Counter.Test-Counter-Get" |
37 | exec="onos-execute-expect ${OCI} counter-test test-counter incrementAndGet --expect 2"/> | 34 | exec="onos-execute-expect ${OCI} counter-test test-counter incrementAndGet --expect 2"/> |
38 | 35 | ||
39 | - <step name="Test-Counter-GetAndIncrement" requires="^" | 36 | + <step name="Distributed-Primitive-Counter.Test-Counter-GetAndIncrement" requires="Distributed-Primitive-Counter.Test-Counter-IncrementAndGet" |
40 | exec="onos-execute-expect ${OCI} counter-test test-counter getAndIncrement --expect 2"/> | 37 | exec="onos-execute-expect ${OCI} counter-test test-counter getAndIncrement --expect 2"/> |
41 | 38 | ||
42 | - <step name="Test-Counter-Incremented" requires="^" | 39 | + <step name="Distributed-Primitive-Counter.Test-Counter-Incremented" requires="Distributed-Primitive-Counter.Test-Counter-GetAndIncrement" |
43 | exec="onos-cluster-execute-expect counter-test test-counter get --expect 3"/> | 40 | exec="onos-cluster-execute-expect counter-test test-counter get --expect 3"/> |
44 | 41 | ||
45 | - <step name="Test-Counter-AddAndGet" requires="^" | 42 | + <step name="Distributed-Primitive-Counter.Test-Counter-AddAndGet" requires="Distributed-Primitive-Counter.Test-Counter-Incremented" |
46 | exec="onos-execute-expect ${OCI} counter-test test-counter addAndGet 10 --expect 13"/> | 43 | exec="onos-execute-expect ${OCI} counter-test test-counter addAndGet 10 --expect 13"/> |
47 | 44 | ||
48 | - <step name="Test-Counter-GetAndAdd" requires="^" | 45 | + <step name="Distributed-Primitive-Counter.Test-Counter-GetAndAdd" requires="Distributed-Primitive-Counter.Test-Counter-AddAndGet" |
49 | exec="onos-execute-expect ${OCI} counter-test test-counter getAndAdd 10 --expect 13"/> | 46 | exec="onos-execute-expect ${OCI} counter-test test-counter getAndAdd 10 --expect 13"/> |
50 | 47 | ||
51 | - <step name="Test-Counter-Updated-After-GetAndAdd" requires="^" | 48 | + <step name="Distributed-Primitive-Counter.Test-Counter-Updated-After-GetAndAdd" requires="Distributed-Primitive-Counter.Test-Counter-GetAndAdd" |
52 | exec="onos-cluster-execute-expect counter-test test-counter get --expect 23"/> | 49 | exec="onos-cluster-execute-expect counter-test test-counter get --expect 23"/> |
53 | 50 | ||
54 | - <step name="Test-Counter-CompareAndSet-False" requires="^" | 51 | + <step name="Distributed-Primitive-Counter.Test-Counter-CompareAndSet-False" requires="Distributed-Primitive-Counter.Test-Counter-Updated-After-GetAndAdd" |
55 | exec="onos-execute-expect ${OCI} counter-test test-counter compareAndSet 1 2 --expect false"/> | 52 | exec="onos-execute-expect ${OCI} counter-test test-counter compareAndSet 1 2 --expect false"/> |
56 | 53 | ||
57 | - <step name="Test-Counter-Not-Updated-After-CAS" requires="^" | 54 | + <step name="Distributed-Primitive-Counter.Test-Counter-Not-Updated-After-CAS" requires="Distributed-Primitive-Counter.Test-Counter-CompareAndSet-False" |
58 | exec="onos-cluster-execute-expect counter-test test-counter get --expect 23"/> | 55 | exec="onos-cluster-execute-expect counter-test test-counter get --expect 23"/> |
59 | 56 | ||
60 | - <step name="Test-Counter-CompareAndSet-True" requires="^" | 57 | + <step name="Distributed-Primitive-Counter.Test-Counter-CompareAndSet-True" requires="Distributed-Primitive-Counter.Test-Counter-Not-Updated-After-CAS" |
61 | exec="onos-execute-expect ${OCI} counter-test test-counter compareAndSet 23 25 --expect true"/> | 58 | exec="onos-execute-expect ${OCI} counter-test test-counter compareAndSet 23 25 --expect true"/> |
62 | 59 | ||
63 | - <step name="Test-Counter-Updated-After-CAS" requires="^" | 60 | + <step name="Distributed-Primitive-Counter.Test-Counter-Updated-After-CAS" requires="Distributed-Primitive-Counter.Test-Counter-CompareAndSet-True" |
64 | exec="onos-cluster-execute-expect counter-test test-counter get --expect 25"/> | 61 | exec="onos-cluster-execute-expect counter-test test-counter get --expect 25"/> |
65 | 62 | ||
66 | - <step name="Test-Counter-Reset" requires="^" | 63 | + <step name="Distributed-Primitive-Counter.Test-Counter-Reset" requires="Distributed-Primitive-Counter.Test-Counter-Updated-After-CAS" |
67 | exec="onos ${OCI} counter-test test-counter set 0"/> | 64 | exec="onos ${OCI} counter-test test-counter set 0"/> |
68 | 65 | ||
69 | - <step name="Test-Counter-Get-After-Reset" requires="^" | 66 | + <step name="Distributed-Primitive-Counter.Test-Counter-Get-After-Reset" requires="Distributed-Primitive-Counter.Test-Counter-Reset" |
70 | exec="onos-cluster-execute-expect counter-test test-counter get --expect 0"/> | 67 | exec="onos-cluster-execute-expect counter-test test-counter get --expect 0"/> |
71 | 68 | ||
72 | <!--Check with check logs--> | 69 | <!--Check with check logs--> |
73 | - <step name="Check-Log-Exceptions" requires="^" | 70 | + <step name="Distributed-Primitive-Counter.Check-Log-Exceptions" requires="Distributed-Primitive-Counter.Test-Counter-Get-After-Reset" |
74 | exec="onos-check-logs ${OCI}"/> | 71 | exec="onos-check-logs ${OCI}"/> |
75 | 72 | ||
76 | - <step name="Teardown-Distributed-Primitives-Test-App" requires="^" | 73 | + <step name="Distributed-Primitive-Counter.Teardown-Distributed-Primitives-Test-App" requires="Distributed-Primitive-Counter.Check-Log-Exceptions" |
77 | exec="onos ${OCI} app deactivate org.onosproject.distributedprimitives"/> | 74 | exec="onos ${OCI} app deactivate org.onosproject.distributedprimitives"/> |
78 | </group> | 75 | </group> |
79 | </scenario> | 76 | </scenario> | ... | ... |
... | @@ -14,33 +14,30 @@ | ... | @@ -14,33 +14,30 @@ |
14 | ~ limitations under the License. | 14 | ~ limitations under the License. |
15 | --> | 15 | --> |
16 | 16 | ||
17 | -<scenario name="distributed leader elector test" | 17 | +<scenario name="distributed-leader-elector-test" |
18 | description="ONOS LeaderElector distributed primitive Test"> | 18 | description="ONOS LeaderElector distributed primitive Test"> |
19 | - <group name="Distributed-Primitive-Value"> | 19 | + <group name="Distributed-Primitive-Leader"> |
20 | 20 | ||
21 | - <!--<import file="${ONOS_SCENARIOS}/setup.xml"/> | 21 | + <step name="Distributed-Primitive-Leader.Activate-Distributed-Primitives-App" |
22 | - <dependency name="Setup" requires="Prerequisites"/>--> | ||
23 | - | ||
24 | - <step name="Activate-Distributed-Primitives-App" | ||
25 | exec="onos ${OCI} app activate org.onosproject.distributedprimitives"/> | 22 | exec="onos ${OCI} app activate org.onosproject.distributedprimitives"/> |
26 | 23 | ||
27 | - <step name="Test-Initial-No-Leader" requires="^" | 24 | + <step name="Distributed-Primitive-Leader.Test-Initial-No-Leader" requires="Distributed-Primitive-Leader.Activate-Distributed-Primitives-App" |
28 | exec="onos-cluster-execute-expect leader-test test-elector show foo --expect leader=none#candidates=none"/> | 25 | exec="onos-cluster-execute-expect leader-test test-elector show foo --expect leader=none#candidates=none"/> |
29 | 26 | ||
30 | - <step name="Test-Leader-Run" requires="^" | 27 | + <step name="Distributed-Primitive-Leader.Test-Leader-Run" requires="Distributed-Primitive-Leader.Test-Initial-No-Leader" |
31 | - exec="onos-execute-expect ${OCI} leader-test test-elector run foo --expect leader=${OCI}#term=1#candidates=${OCI}"/> | 28 | + exec="onos-execute-expect ${OCI} leader-test test-elector run foo --expect leader=${OCI}#term=[0-9][0-9]*#candidates=${OCI}"/> |
32 | 29 | ||
33 | - <step name="Test-Leader-Withdraw" requires="^" | 30 | + <step name="Distributed-Primitive-Leader.Test-Leader-Withdraw" requires="Distributed-Primitive-Leader.Test-Leader-Run" |
34 | exec="onos ${OCI} leader-test test-elector withdraw foo"/> | 31 | exec="onos ${OCI} leader-test test-elector withdraw foo"/> |
35 | 32 | ||
36 | - <step name="Test-No-Leader-After-Withdraw" requires="^" | 33 | + <step name="Distributed-Primitive-Leader.Test-No-Leader-After-Withdraw" requires="Distributed-Primitive-Leader.Test-Leader-Withdraw" |
37 | exec="onos-cluster-execute-expect leader-test test-elector show foo --expect leader=none#candidates=none"/> | 34 | exec="onos-cluster-execute-expect leader-test test-elector show foo --expect leader=none#candidates=none"/> |
38 | 35 | ||
39 | <!--Check with check logs--> | 36 | <!--Check with check logs--> |
40 | - <step name="Check-Log-Exceptions" requires="^" | 37 | + <step name="Distributed-Primitive-Leader.Check-Log-Exceptions" requires="Distributed-Primitive-Leader.Test-No-Leader-After-Withdraw" |
41 | exec="onos-check-logs ${OCI}"/> | 38 | exec="onos-check-logs ${OCI}"/> |
42 | 39 | ||
43 | - <step name="Teardown-Distributed-Primitives-Test-App" requires="^" | 40 | + <step name="Distributed-Primitive-Leader.Teardown-Distributed-Primitives-Test-App" requires="Distributed-Primitive-Leader.Check-Log-Exceptions" |
44 | exec="onos ${OCI} app deactivate org.onosproject.distributedprimitives"/> | 41 | exec="onos ${OCI} app deactivate org.onosproject.distributedprimitives"/> |
45 | </group> | 42 | </group> |
46 | </scenario> | 43 | </scenario> | ... | ... |
... | @@ -14,81 +14,78 @@ | ... | @@ -14,81 +14,78 @@ |
14 | ~ limitations under the License. | 14 | ~ limitations under the License. |
15 | --> | 15 | --> |
16 | 16 | ||
17 | -<scenario name="Distributed consistent map test" | 17 | +<scenario name="distributed-consistent-map-test" |
18 | description="ONOS ConsistentMap distributed primitive Test"> | 18 | description="ONOS ConsistentMap distributed primitive Test"> |
19 | <group name="Distributed-Primitive-Map"> | 19 | <group name="Distributed-Primitive-Map"> |
20 | 20 | ||
21 | - <!--<import file="${ONOS_SCENARIOS}/setup.xml"/> | 21 | + <step name="Distributed-Primitive-Map.Activate-Distributed-Primitives-App" |
22 | - <dependency name="Setup" requires="Prerequisites"/>--> | ||
23 | - | ||
24 | - <step name="Activate-Distributed-Primitives-App" | ||
25 | exec="onos ${OCI} app activate org.onosproject.distributedprimitives"/> | 22 | exec="onos ${OCI} app activate org.onosproject.distributedprimitives"/> |
26 | 23 | ||
27 | - <step name="Test-Map-Get" requires="^" | 24 | + <step name="Distributed-Primitive-Map.Test-Map-Get" requires="Distributed-Primitive-Map.Activate-Distributed-Primitives-App" |
28 | exec="onos-cluster-execute-expect map-test foo get a --expect null"/> | 25 | exec="onos-cluster-execute-expect map-test foo get a --expect null"/> |
29 | 26 | ||
30 | - <step name="Test-Map-Put" requires="^" | 27 | + <step name="Distributed-Primitive-Map.Test-Map-Put" requires="Distributed-Primitive-Map.Test-Map-Get" |
31 | exec="onos-execute-expect ${OCI} map-test foo put a b --expect null"/> | 28 | exec="onos-execute-expect ${OCI} map-test foo put a b --expect null"/> |
32 | 29 | ||
33 | - <step name="Test-Map-Updated-After-Put" requires="^" | 30 | + <step name="Distributed-Primitive-Map.Test-Map-Updated-After-Put" requires="Distributed-Primitive-Map.Test-Map-Put" |
34 | exec="onos-cluster-execute-expect map-test foo get a --expect b"/> | 31 | exec="onos-cluster-execute-expect map-test foo get a --expect b"/> |
35 | 32 | ||
36 | - <step name="Test-Map-PutIfAbsent-When-Key-Present" requires="^" | 33 | + <step name="Distributed-Primitive-Map.Test-Map-PutIfAbsent-When-Key-Present" requires="Distributed-Primitive-Map.Test-Map-Updated-After-Put" |
37 | exec="onos-execute-expect ${OCI} map-test foo putIfAbsent a c --expect b"/> | 34 | exec="onos-execute-expect ${OCI} map-test foo putIfAbsent a c --expect b"/> |
38 | 35 | ||
39 | - <step name="Test-Map-PutIfAbsent-When-Key-Absent" requires="^" | 36 | + <step name="Distributed-Primitive-Map.Test-Map-PutIfAbsent-When-Key-Absent" requires="Distributed-Primitive-Map.Test-Map-PutIfAbsent-When-Key-Present" |
40 | exec="onos-execute-expect ${OCI} map-test foo putIfAbsent b c --expect null"/> | 37 | exec="onos-execute-expect ${OCI} map-test foo putIfAbsent b c --expect null"/> |
41 | 38 | ||
42 | - <step name="Test-Map-Updated-After-PutIfAbsent" requires="^" | 39 | + <step name="Distributed-Primitive-Map.Test-Map-Updated-After-PutIfAbsent" requires="Distributed-Primitive-Map.Test-Map-PutIfAbsent-When-Key-Absent" |
43 | exec="onos-cluster-execute-expect map-test foo get b --expect c"/> | 40 | exec="onos-cluster-execute-expect map-test foo get b --expect c"/> |
44 | 41 | ||
45 | - <step name="Test-Map-Updated-After-PutAndGet" requires="^" | 42 | + <step name="Distributed-Primitive-Map.Test-Map-Updated-After-PutAndGet" requires="Distributed-Primitive-Map.Test-Map-Updated-After-PutIfAbsent" |
46 | exec="onos-execute-expect ${OCI} map-test foo putAndGet b d --expect d"/> | 43 | exec="onos-execute-expect ${OCI} map-test foo putAndGet b d --expect d"/> |
47 | 44 | ||
48 | - <step name="Test-Map-Replace-When-Key-Absent" requires="^" | 45 | + <step name="Distributed-Primitive-Map.Test-Map-Replace-When-Key-Absent" requires="Distributed-Primitive-Map.Test-Map-Updated-After-PutAndGet" |
49 | exec="onos-execute-expect ${OCI} map-test foo replace c e --expect null"/> | 46 | exec="onos-execute-expect ${OCI} map-test foo replace c e --expect null"/> |
50 | 47 | ||
51 | - <step name="Test-Map-Replace-When-Key-Present" requires="^" | 48 | + <step name="Distributed-Primitive-Map.Test-Map-Replace-When-Key-Present" requires="Distributed-Primitive-Map.Test-Map-Replace-When-Key-Absent" |
52 | exec="onos-execute-expect ${OCI} map-test foo replace b e --expect d"/> | 49 | exec="onos-execute-expect ${OCI} map-test foo replace b e --expect d"/> |
53 | 50 | ||
54 | - <step name="Test-Map-Replace-When-Value-Does-Not-Match" requires="^" | 51 | + <step name="Distributed-Primitive-Map.Test-Map-Replace-When-Value-Does-Not-Match" requires="Distributed-Primitive-Map.Test-Map-Replace-When-Key-Present" |
55 | exec="onos-execute-expect ${OCI} map-test foo replace b x f --expect false"/> | 52 | exec="onos-execute-expect ${OCI} map-test foo replace b x f --expect false"/> |
56 | 53 | ||
57 | - <step name="Test-Map-Replace-When-Value-Does-Match" requires="^" | 54 | + <step name="Distributed-Primitive-Map.Test-Map-Replace-When-Value-Does-Match" requires="Distributed-Primitive-Map.Test-Map-Replace-When-Value-Does-Not-Match" |
58 | exec="onos-execute-expect ${OCI} map-test foo replace b e f --expect true"/> | 55 | exec="onos-execute-expect ${OCI} map-test foo replace b e f --expect true"/> |
59 | 56 | ||
60 | - <step name="Test-Map-ContainsValue-False-Case" requires="^" | 57 | + <step name="Distributed-Primitive-Map.Test-Map-ContainsValue-False-Case" requires="Distributed-Primitive-Map.Test-Map-Replace-When-Value-Does-Match" |
61 | exec="onos-cluster-execute-expect map-test foo containsValue x --expect false"/> | 58 | exec="onos-cluster-execute-expect map-test foo containsValue x --expect false"/> |
62 | 59 | ||
63 | - <step name="Test-Map-ContainsValue-True-Case" requires="^" | 60 | + <step name="Distributed-Primitive-Map.Test-Map-ContainsValue-True-Case" requires="Distributed-Primitive-Map.Test-Map-ContainsValue-False-Case" |
64 | exec="onos-cluster-execute-expect map-test foo containsValue f --expect true"/> | 61 | exec="onos-cluster-execute-expect map-test foo containsValue f --expect true"/> |
65 | 62 | ||
66 | - <step name="Test-Map-Size" requires="^" | 63 | + <step name="Distributed-Primitive-Map.Test-Map-Size" requires="Distributed-Primitive-Map.Test-Map-ContainsValue-True-Case" |
67 | exec="onos-cluster-execute-expect map-test foo size --expect 2"/> | 64 | exec="onos-cluster-execute-expect map-test foo size --expect 2"/> |
68 | 65 | ||
69 | - <step name="Test-Map-IsEmpty" requires="^" | 66 | + <step name="Distributed-Primitive-Map.Test-Map-IsEmpty" requires="Distributed-Primitive-Map.Test-Map-Size" |
70 | exec="onos-cluster-execute-expect map-test foo isEmpty --expect false"/> | 67 | exec="onos-cluster-execute-expect map-test foo isEmpty --expect false"/> |
71 | 68 | ||
72 | - <step name="Test-Map-Remove" requires="^" | 69 | + <step name="Distributed-Primitive-Map.Test-Map-Remove" requires="Distributed-Primitive-Map.Test-Map-IsEmpty" |
73 | exec="onos-execute-expect ${OCI} map-test foo remove b --expect f"/> | 70 | exec="onos-execute-expect ${OCI} map-test foo remove b --expect f"/> |
74 | 71 | ||
75 | - <step name="Test-Map-Remove-Key-Value-Does-Not-Match" requires="^" | 72 | + <step name="Distributed-Primitive-Map.Test-Map-Remove-Key-Value-Does-Not-Match" requires="Distributed-Primitive-Map.Test-Map-Remove" |
76 | exec="onos-execute-expect ${OCI} map-test foo remove a c --expect false"/> | 73 | exec="onos-execute-expect ${OCI} map-test foo remove a c --expect false"/> |
77 | 74 | ||
78 | - <step name="Test-Map-Remove-Key-Value-Does-Match" requires="^" | 75 | + <step name="Distributed-Primitive-Map.Test-Map-Remove-Key-Value-Does-Match" requires="Distributed-Primitive-Map.Test-Map-Remove-Key-Value-Does-Not-Match" |
79 | exec="onos-execute-expect ${OCI} map-test foo remove a b --expect true"/> | 76 | exec="onos-execute-expect ${OCI} map-test foo remove a b --expect true"/> |
80 | 77 | ||
81 | - <step name="Test-Map-Clear" requires="^" | 78 | + <step name="Distributed-Primitive-Map.Test-Map-Clear" requires="Distributed-Primitive-Map.Test-Map-Remove-Key-Value-Does-Match" |
82 | exec="onos ${OCI} map-test foo clear"/> | 79 | exec="onos ${OCI} map-test foo clear"/> |
83 | 80 | ||
84 | - <step name="Test-Map-Cleared" requires="^" | 81 | + <step name="Distributed-Primitive-Map.Test-Map-Cleared" requires="Distributed-Primitive-Map.Test-Map-Clear" |
85 | exec="onos-execute-expect ${OCI} map-test foo isEmpty --expect true"/> | 82 | exec="onos-execute-expect ${OCI} map-test foo isEmpty --expect true"/> |
86 | 83 | ||
87 | <!--Check with check logs--> | 84 | <!--Check with check logs--> |
88 | - <step name="Check-Log-Exceptions" requires="^" | 85 | + <step name="Distributed-Primitive-Map.Check-Log-Exceptions" requires="Distributed-Primitive-Map.Test-Map-Cleared" |
89 | exec="onos-check-logs ${OCI}"/> | 86 | exec="onos-check-logs ${OCI}"/> |
90 | 87 | ||
91 | - <step name="Teardown-Distributed-Primitives-Test-App" requires="^" | 88 | + <step name="Distributed-Primitive-Map.Teardown-Distributed-Primitives-Test-App" requires="Distributed-Primitive-Map.Check-Log-Exceptions" |
92 | exec="onos ${OCI} app deactivate org.onosproject.distributedprimitives"/> | 89 | exec="onos ${OCI} app deactivate org.onosproject.distributedprimitives"/> |
93 | </group> | 90 | </group> |
94 | </scenario> | 91 | </scenario> | ... | ... |
... | @@ -18,53 +18,18 @@ | ... | @@ -18,53 +18,18 @@ |
18 | description="ONOS distributed primitives setup"> | 18 | description="ONOS distributed primitives setup"> |
19 | <group name="Distributed-Primitives"> | 19 | <group name="Distributed-Primitives"> |
20 | 20 | ||
21 | - <!--<import file="${ONOS_SCENARIOS}/setup.xml"/> | 21 | + <import file="${ONOS_SCENARIOS}/dist-map.xml"/> |
22 | - <dependency name="Setup" requires="Prerequisites"/>--> | 22 | + <dependency name="Distributed-Primitive-Map" requires="Setup"/> |
23 | 23 | ||
24 | - <step name="Distributed-App" | 24 | + <import file="${ONOS_SCENARIOS}/dist-value.xml"/> |
25 | - requires="Setup" | 25 | + <dependency name="Distributed-Primitive-Value" requires="Distributed-Primitive-Map"/> |
26 | - exec="onos ${OCI} app activate org.onosproject.distributedprimitives"/> | ||
27 | 26 | ||
28 | - <step name="Test-Counter-Increment" | 27 | + <import file="${ONOS_SCENARIOS}/dist-counter.xml"/> |
29 | - requires="Distributed-App" | 28 | + <dependency name="Distributed-Primitive-Counter" requires="Distributed-Primitive-Value"/> |
30 | - exec="onos-execute-expect ${OCI} counter-test-increment fooCounter 5 --expect updated"/> | ||
31 | 29 | ||
32 | - <step name="Test-Add" | 30 | + <import file="${ONOS_SCENARIOS}/dist-leader.xml"/> |
33 | - requires="Distributed-App" | 31 | + <dependency name="Distributed-Primitive-Leader" requires="Distributed-Primitive-Counter"/> |
34 | - exec="onos-execute-expect ${OCI} set-test-add fooSet foo --expect added"/> | ||
35 | 32 | ||
36 | - <step name="Test-Get" | ||
37 | - requires="Test-Add" | ||
38 | - exec="onos-execute-expect ${OCI} set-test-get fooSet foo --expect contains"/> | ||
39 | - | ||
40 | - <step name="Test-Remove" | ||
41 | - requires="Test-Get" | ||
42 | - exec="onos-execute-expect ${OCI} set-test-remove fooSet foo --expect removed"/> | ||
43 | - | ||
44 | - <step name="Test-Add-Multiple" | ||
45 | - requires="Test-Remove" | ||
46 | - exec="onos-execute-expect ${OCI} set-test-add fooSet foo foo2 foo3 --expect added"/> | ||
47 | - | ||
48 | - <step name="Test-Get-Multiple" | ||
49 | - requires="Test-Add-Multiple" | ||
50 | - exec="onos-execute-expect ${OCI} set-test-get fooSet foo foo2 foo3 --expect contains"/> | ||
51 | - | ||
52 | - <step name="Test-Remove-Multiple" | ||
53 | - requires="Test-Get-Multiple" | ||
54 | - exec="onos-execute-expect ${OCI} set-test-remove fooSet foo foo2 foo3 --expect removed"/> | ||
55 | - | ||
56 | - <step name="Test-Map-Put" | ||
57 | - requires="Distributed-App" | ||
58 | - exec="onos-execute-expect ${OCI} transactional-map-test-put 1 foo --expect Created"/> | ||
59 | - | ||
60 | - <step name="Test-Map-Get" | ||
61 | - requires="Test-Map-Put" | ||
62 | - exec="onos-execute-expect ${OCI} transactional-map-test-get Key1 --expect Key-value"/> | ||
63 | - | ||
64 | - <!--Check with check logs--> | ||
65 | - <step name="Check-Distributed-Exceptions" | ||
66 | - exec="onos-check-logs ${OCI}" | ||
67 | - requires="Test-Map-Get"/> | ||
68 | </group> | 33 | </group> |
69 | </scenario> | 34 | </scenario> |
70 | 35 | ... | ... |
... | @@ -14,42 +14,45 @@ | ... | @@ -14,42 +14,45 @@ |
14 | ~ limitations under the License. | 14 | ~ limitations under the License. |
15 | --> | 15 | --> |
16 | 16 | ||
17 | -<scenario name="distributed value test" | 17 | +<scenario name="distributed-value-test" |
18 | description="ONOS AtomicValue distributed primitive Test"> | 18 | description="ONOS AtomicValue distributed primitive Test"> |
19 | <group name="Distributed-Primitive-Value"> | 19 | <group name="Distributed-Primitive-Value"> |
20 | 20 | ||
21 | <!--<import file="${ONOS_SCENARIOS}/setup.xml"/> | 21 | <!--<import file="${ONOS_SCENARIOS}/setup.xml"/> |
22 | <dependency name="Setup" requires="Prerequisites"/>--> | 22 | <dependency name="Setup" requires="Prerequisites"/>--> |
23 | 23 | ||
24 | - <step name="Activate-Distributed-Primitives-App" | 24 | + <step name="Distributed-Primitive-Value.Activate-Distributed-Primitives-App" |
25 | exec="onos ${OCI} app activate org.onosproject.distributedprimitives"/> | 25 | exec="onos ${OCI} app activate org.onosproject.distributedprimitives"/> |
26 | 26 | ||
27 | - <step name="Test-Value-Initial-Value" requires="^" | 27 | + <step name="Distributed-Primitive-Value.Test-Value-Initial-Value" requires="Distributed-Primitive-Value.Activate-Distributed-Primitives-App" |
28 | exec="onos-cluster-execute-expect value-test test-value get --expect null"/> | 28 | exec="onos-cluster-execute-expect value-test test-value get --expect null"/> |
29 | 29 | ||
30 | - <step name="Test-Value-Set" requires="^" | 30 | + <step name="Distributed-Primitive-Value.Test-Value-Set" requires="Distributed-Primitive-Value.Test-Value-Initial-Value" |
31 | exec="onos ${OCI} value-test test-value set v0"/> | 31 | exec="onos ${OCI} value-test test-value set v0"/> |
32 | 32 | ||
33 | - <step name="Test-Value-Get" requires="^" | 33 | + <step name="Distributed-Primitive-Value.Test-Value-Get" requires="Distributed-Primitive-Value.Test-Value-Set" |
34 | exec="onos-cluster-execute-expect value-test test-value get --expect v0"/> | 34 | exec="onos-cluster-execute-expect value-test test-value get --expect v0"/> |
35 | 35 | ||
36 | - <step name="Test-Value-CompareAndSet-False" requires="^" | 36 | + <step name="Distributed-Primitive-Value.Test-Value-CompareAndSet-False" requires="Distributed-Primitive-Value.Test-Value-Get" |
37 | exec="onos-execute-expect ${OCI} value-test test-value compareAndSet v1 v2 --expect false"/> | 37 | exec="onos-execute-expect ${OCI} value-test test-value compareAndSet v1 v2 --expect false"/> |
38 | 38 | ||
39 | - <step name="Test-Value-Not-Updated-After-CAS" requires="^" | 39 | + <step name="Distributed-Primitive-Value.Test-Value-Not-Updated-After-CAS" requires="Distributed-Primitive-Value.Test-Value-CompareAndSet-False" |
40 | exec="onos-cluster-execute-expect value-test test-value get --expect v0"/> | 40 | exec="onos-cluster-execute-expect value-test test-value get --expect v0"/> |
41 | 41 | ||
42 | - <step name="Test-Value-CompareAndSet-True" requires="^" | 42 | + <step name="Distributed-Primitive-Value.Test-Value-CompareAndSet-True" requires="Distributed-Primitive-Value.Test-Value-Not-Updated-After-CAS" |
43 | exec="onos-execute-expect ${OCI} value-test test-value compareAndSet v0 v1 --expect true"/> | 43 | exec="onos-execute-expect ${OCI} value-test test-value compareAndSet v0 v1 --expect true"/> |
44 | 44 | ||
45 | - <step name="Test-Value-Updated-After-CAS" requires="^" | 45 | + <step name="Distributed-Primitive-Value.Test-Value-Updated-After-CAS" requires="Distributed-Primitive-Value.Test-Value-CompareAndSet-True" |
46 | exec="onos-cluster-execute-expect value-test test-value get --expect v1"/> | 46 | exec="onos-cluster-execute-expect value-test test-value get --expect v1"/> |
47 | 47 | ||
48 | + <step name="Distributed-Primitive-Value.Destroy-Value" requires="Distributed-Primitive-Value.Test-Value-Updated-After-CAS" | ||
49 | + exec="onos ${OCI} value-test test-value set null"/> | ||
50 | + | ||
48 | <!--Check with check logs--> | 51 | <!--Check with check logs--> |
49 | - <step name="Check-Log-Exceptions" requires="^" | 52 | + <step name="Distributed-Primitive-Value.Check-Log-Exceptions" requires="Distributed-Primitive-Value.Destroy-Value" |
50 | exec="onos-check-logs ${OCI}"/> | 53 | exec="onos-check-logs ${OCI}"/> |
51 | 54 | ||
52 | - <step name="Teardown-Distributed-Primitives-Test-App" requires="^" | 55 | + <step name="Distributed-Primitive-Value.Teardown-Distributed-Primitives-Test-App" requires="Distributed-Primitive-Value.Check-Log-Exceptions" |
53 | exec="onos ${OCI} app deactivate org.onosproject.distributedprimitives"/> | 56 | exec="onos ${OCI} app deactivate org.onosproject.distributedprimitives"/> |
54 | </group> | 57 | </group> |
55 | </scenario> | 58 | </scenario> | ... | ... |
... | @@ -16,16 +16,17 @@ | ... | @@ -16,16 +16,17 @@ |
16 | <scenario name="smoke" description="ONOS smoke test"> | 16 | <scenario name="smoke" description="ONOS smoke test"> |
17 | <import file="${ONOS_SCENARIOS}/prerequisites.xml"/> | 17 | <import file="${ONOS_SCENARIOS}/prerequisites.xml"/> |
18 | <import file="${ONOS_SCENARIOS}/net-prerequisites.xml"/> | 18 | <import file="${ONOS_SCENARIOS}/net-prerequisites.xml"/> |
19 | - | ||
20 | <import file="${ONOS_SCENARIOS}/setup.xml"/> | 19 | <import file="${ONOS_SCENARIOS}/setup.xml"/> |
21 | - <dependency name="Setup" requires="Prerequisites,Net-Prerequisites"/> | 20 | + <import file="${ONOS_SCENARIOS}/dist-test.xml"/> |
22 | - | ||
23 | <import file="${ONOS_SCENARIOS}/smoke-internal.xml"/> | 21 | <import file="${ONOS_SCENARIOS}/smoke-internal.xml"/> |
22 | + | ||
23 | + <dependency name="Setup" requires="Prerequisites,Net-Prerequisites"/> | ||
24 | <dependency name="Net-Smoke" requires="Setup"/> | 24 | <dependency name="Net-Smoke" requires="Setup"/> |
25 | <dependency name="Archetypes" requires="Setup"/> | 25 | <dependency name="Archetypes" requires="Setup"/> |
26 | <dependency name="Drivers-Test" requires="Setup"/> | 26 | <dependency name="Drivers-Test" requires="Setup"/> |
27 | <dependency name="Meta-App" requires="Setup"/> | 27 | <dependency name="Meta-App" requires="Setup"/> |
28 | <dependency name="Netcfg" requires="Setup"/> | 28 | <dependency name="Netcfg" requires="Setup"/> |
29 | + <dependency name="Distributed-Primitives" requires="Setup"/> | ||
29 | 30 | ||
30 | <import file="${ONOS_SCENARIOS}/wrapup.xml"/> | 31 | <import file="${ONOS_SCENARIOS}/wrapup.xml"/> |
31 | <dependency name="Wrapup" requires="~Setup,~Net-Smoke,~Archetypes,~Drivers-Test,~Meta-App,~Netcfg"/> | 32 | <dependency name="Wrapup" requires="~Setup,~Net-Smoke,~Archetypes,~Drivers-Test,~Meta-App,~Netcfg"/> | ... | ... |
-
Please register or login to post a comment