Adding hosts test + fix a test to run locally
This commit is contained in:
parent
a75641aaf3
commit
434aea8b4c
File diff suppressed because one or more lines are too long
|
@ -0,0 +1,38 @@
|
||||||
|
*** Settings ***
|
||||||
|
Documentation Check the hosts mode with api custom mode
|
||||||
|
|
||||||
|
Resource ${CURDIR}${/}..${/}..${/}..${/}..${/}..${/}resources/import.resource
|
||||||
|
|
||||||
|
Test Timeout 120s
|
||||||
|
|
||||||
|
Test Setup Set Test Variable ${cnt} ${1}
|
||||||
|
Test Teardown Set Test Variable ${cnt} ${cnt + 1}
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
*** Variables ***
|
||||||
|
${CMD} ${CENTREON_PLUGINS}
|
||||||
|
... --plugin=apps::automation::ansible::tower::plugin
|
||||||
|
... --custommode=api
|
||||||
|
... --hostname=host.docker.internal
|
||||||
|
... --username=username
|
||||||
|
... --password=password
|
||||||
|
... --port=3000
|
||||||
|
|
||||||
|
|
||||||
|
*** Test Cases ***
|
||||||
|
Hosts ${tc}
|
||||||
|
[Documentation] Check the number of returned hosts
|
||||||
|
[Tags] apps automation ansible service-disco
|
||||||
|
${command} Catenate
|
||||||
|
... ${CMD}
|
||||||
|
... --mode=hosts
|
||||||
|
${output} Run ${command}
|
||||||
|
${output} Strip String ${output}
|
||||||
|
Should Be Equal As Strings
|
||||||
|
... ${expected_result}
|
||||||
|
... ${output}
|
||||||
|
... Wrong output result for command:{\n}{\n}${command}{\n}{\n}Command output:{\n}{\n}${output}
|
||||||
|
|
||||||
|
Examples: tc snmpcommunity expected_result --
|
||||||
|
... 1 os/linux/snmp/list-diskio OK: Hosts total: 10, failed: 0 - All hosts are ok | 'hosts.total.count'=10;;;0; 'hosts.failed.count'=0;;;0;10
|
|
@ -13,7 +13,7 @@ ${CMD} ${CENTREON_PLUGINS}
|
||||||
... --command=cat
|
... --command=cat
|
||||||
... --command-path=/usr/bin
|
... --command-path=/usr/bin
|
||||||
... --no-ps
|
... --no-ps
|
||||||
... --command-options=nodeintegrationservice-2022.json
|
... --command-options=${CURDIR}/nodeintegrationservice-2022.json
|
||||||
|
|
||||||
*** Test Cases ***
|
*** Test Cases ***
|
||||||
HyperV 2022 ${tc}/3
|
HyperV 2022 ${tc}/3
|
||||||
|
|
Loading…
Reference in New Issue