ReadyAPI - Running a test with configurations
I have some tests in which I have to manually change one setting in a config file to run the tests. The setting depends on which test we are running. I don't know if this approach to using ReadyAPI itself is good or bad. But, I would like to be able to create test run configurations for any test instead of manually finding that file and editing it each time. Let me explain more with an example.
In programming IDEs like Intellij IDEA/Eclipse, you can run a test with configurations and you can have multiple configurations for a test. Here is a generic example of how we use that feature. Say we have a test for login to Gmail. For that test, we can have one run config with browserName = chrome. Another config could be browserName = all which will run that test in chrome, firefox and safari. So, for my test, I could make a config like mySetting = abc.
Similarly, do we have run configs for ReadyAPI tests? If not, then why?
Keywords - Run configuration, Debug configuration, Test configuration, Run Config, Debug config, Run time configs.
Hi,
You could use the 'CustomProperties' tab in the Environments UI. You can then 'pull' those environment level customer properties into any test you are using.
As for config in a Groovy script, may you use the Setup Script tab (availability at Project, test Suite, Test Case) layers to pull in the config from your groovy script.