Hello everyone, just got one thing to ask,In all the rest api tools like soapui or postman, can we use python to call all the parameters and test the api's automatically instead of manually testing them?plz respond
Solved! Go to Solution.
Or you can pass those parameters to the testrunner as arguments and you'll be able to access them at the Project level.
High level pseudo example:
SOAPUI_RUNNER=${SOAPUI_HOME}/bin/testrunner.sh
SOAPUI_COMMAND="${SOAPUI_RUNNER} "${SOAPUI_TESTS_DIR}/${TEST_SUITE}" -I -f \"${RELATIVE_REPORT_DIR}\" \
-PmyCustomEndpoint=httpEndpointHere \
-PsecondParameter=secondValue \
${ANY_OTHER_PREDEFINED_SOAPUI_EXTRA_ARGS}"
echo "Running: ${SOAPUI_COMMAND}"
sh -c "${SOAPUI_COMMAND}"
And then you'll use that as an endpoint for your http test step: ${#Project#myCustomEndpoint}/api/v2
Hi,
As per https://support.smartbear.com/readyapi/docs/testing/scripts/index.html, Groovy and Rhino JavaScript are supported as scripting languages.
Or you can pass those parameters to the testrunner as arguments and you'll be able to access them at the Project level.
High level pseudo example:
SOAPUI_RUNNER=${SOAPUI_HOME}/bin/testrunner.sh
SOAPUI_COMMAND="${SOAPUI_RUNNER} "${SOAPUI_TESTS_DIR}/${TEST_SUITE}" -I -f \"${RELATIVE_REPORT_DIR}\" \
-PmyCustomEndpoint=httpEndpointHere \
-PsecondParameter=secondValue \
${ANY_OTHER_PREDEFINED_SOAPUI_EXTRA_ARGS}"
echo "Running: ${SOAPUI_COMMAND}"
sh -c "${SOAPUI_COMMAND}"
And then you'll use that as an endpoint for your http test step: ${#Project#myCustomEndpoint}/api/v2
Thank you, Community!
@Roshan Does this help? Please mark the best reply as a Solution to help others in the future!
Subject | Author | Latest Post |
---|---|---|