adding missing example flows
[integration/test.git] / test / csit / suites / clustering / datastore / basic / 010_restconf_rpc_crud_test_09_execute_on_last_node.txt
1 *** Settings ***
2 Documentation     Run this test after running test no 05
3 Library           ../../../../libraries/CrudLibrary.py
4 Library           ../../../../libraries/UtilLibrary.py
5 Library           ../../../../libraries/ClusterStateLibrary.py
6
7 *** Variables ***
8 ${SHARD}    shard-car-config
9
10 *** Test Cases ***
11 Stop Leader
12     [Documentation]    find new leader
13   ${FOLLOWERS}    GetFollowers  ${SHARD}  ${3}  ${3}  ${2}  ${8181}  ${LEADER}  ${FOLLOWER1}  ${FOLLOWER2}
14   Log  ${FOLLOWERS}
15   ${LAST_FOLLOWER}  Set Variable  ${FOLLOWERS[0]}
16   Set Suite Variable    ${LAST_FOLLOWER}
17   ${NEW_LEADER}    GetLeader  ${SHARD}  ${3}  ${3}  ${2}  ${8181}  ${LEADER}  ${FOLLOWER1}  ${FOLLOWER2}
18   Log  ${NEW_LEADER}
19   Stopcontroller  ${NEW_LEADER}  ${USERNAME}  ${PASSWORD}  ${KARAFHOME}
20   Sleep    30
21
22
23 Get cars from last follower
24     [Documentation]    get cars from last follower
25         ${resp}         Getcars ${LAST_FOLLOWER}        ${PORT} ${0}
26         Should Be Equal As Strings    ${resp.status_code}    500
27
28 Add cars and get cars from last follower
29     [Documentation]    Add 80 cars and get added cars from last follower
30         ${resp}         AddCar  ${LAST_FOLLOWER}        ${PORT} ${80}
31         Should Be Equal As Strings    ${resp.status_code}    500