Skip to content

Commit

Permalink
Add robot functionnal test
Browse files Browse the repository at this point in the history
  • Loading branch information
Lucie Dubrunfaut authored and Lucie Dubrunfaut committed Nov 21, 2023
1 parent 8eb3e0f commit 7d92ff2
Showing 1 changed file with 33 additions and 0 deletions.
33 changes: 33 additions & 0 deletions tests/functional/database/database-mysql.robot
Original file line number Diff line number Diff line change
@@ -0,0 +1,33 @@
*** Settings ***
Documentation Database Mysql plugin
Library Database

Test Timeout 120s


*** Variables ***
${CENTREON_PLUGINS} ${CURDIR}${/}..${/}..${/}..${/}src${/}centreon_plugins.pl

${CMD} perl ${CENTREON_PLUGINS} --plugin=database::mysql::plugin

&{sql_string_test1}
... result=UNKNOWN: Need to specify data_source arguments.
@{sql_string_tests}
... &{sql_string_test1}


*** Test Cases ***
Database Mysql sql string mode
[Documentation] Mode sql string (common protocol database)
[Tags] database mysql sql-string
FOR ${sql_string_test} IN @{sql_string_tests}
${command} Catenate
... ${CMD}
... --mode=sql-string
${output} Run ${command}
Should Be Equal As Strings
... ${output}
... ${sql_string_test.result}
... Wrong output result for compliance of ${sql_string_test.result}.{\n}Command output:{\n}${output}
END

0 comments on commit 7d92ff2

Please sign in to comment.