add cases0
This commit is contained in:
parent
926221ee07
commit
0cf4be5a5f
74
xCAT-test/autotest/testcase/restapi/network/cases0
Normal file
74
xCAT-test/autotest/testcase/restapi/network/cases0
Normal file
@ -0,0 +1,74 @@
|
||||
start:get_networks
|
||||
description: get_networks
|
||||
cmd:restapitest -m GET -r /networks
|
||||
check:rc==200
|
||||
cmdcheck:restapitest -o '["network1"]' -O ==
|
||||
end
|
||||
|
||||
start:post_networks
|
||||
description: post_networks
|
||||
cmd:restapitest -m POST -r /networks
|
||||
check:rc==201
|
||||
end
|
||||
|
||||
start:get_networks_attr_for_post
|
||||
description: get_networks_attr_for_post
|
||||
cmd:restapitest -m GET -r /networks/network1
|
||||
check:rc==200
|
||||
cmdcheck:restapitest -o '{"network1":{"net":"10.1.0.0"}}' -O ==
|
||||
end
|
||||
|
||||
start:post_networks_attr
|
||||
description: post_networks_attr
|
||||
cmd:restapitest -m GET -r /networks/network1 -d '{"gateway":"10.1.0.1","mask":"255.255.0.0"}'
|
||||
check:rc==201
|
||||
end
|
||||
|
||||
start:get_networks_all_attr
|
||||
description: get_networks_all_attr
|
||||
cmd:restapitest -m GET -r /networks/network1
|
||||
check:rc==200
|
||||
cmdcheck:restapitest -o '{"network1":{"net":"10.1.0.0"}}' -O ==
|
||||
end
|
||||
|
||||
start:get_networks_attr
|
||||
description: get_networks_attr
|
||||
cmd:restapitest -m GET -r /networks/network1/attrs/net,mask
|
||||
check:rc==200
|
||||
cmdcheck:restapitest -o '{"network1":{"net":"10.1.0.0"}}' -O ==
|
||||
end
|
||||
|
||||
start:put_networks_attr
|
||||
description: put_networks_attr
|
||||
cmd:restapitest -m PUT -r /networks/network1 -d '{"mgtifname":"eth0","net":"10.1.0.0"}'
|
||||
check:rc==200
|
||||
end
|
||||
|
||||
start:get_networks_attr_for_put
|
||||
description: get_networks_attr_for_put
|
||||
cmd:restapitest -m GET -r /networks/network1
|
||||
check:rc==200
|
||||
cmdcheck:restapitest -o '{"network1":{"net":"10.1.0.0"}}' -O ==
|
||||
end
|
||||
|
||||
start:delete_networks_attr_for_put
|
||||
description: delete_networks_attr_for_put
|
||||
cmd:restapitest -m DELETE -r /networks/network1
|
||||
check:rc==200
|
||||
end
|
||||
|
||||
start:get_networks_for_delete
|
||||
description: get_networks_for_delete
|
||||
cmd:restapitest -m GET -r /networks
|
||||
check:rc==200
|
||||
cmdcheck:restapitest -o '["network1"]' -O !=
|
||||
end
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user