Cizo89
12 years agoFrequent Contributor
[Reg] Override environment feature (param "E") isn't working
Hi,
after couple of scripts and some debugging I've realized, that the "E parameter" in automation/command line isn't working correctly.
So I checked this in SoapUI, in the "Launch TestRunner" feature and it looks like I was right, there is a problem in setting/overriding the environment while using TestRunner or using SoapUI in automating the tests (with NAnt scripts).
I attached some simple script to verify this.
In this attached project, I set some active environment (it doesn't matter if it was in TestSuite or TestCase) and in "Launch TestRunner" I overrided the environment to something else, the environment wasn't changed.
It looks like this functionality is broken since the new 4.6 version and it has a very bad impact for our test framework.
I've tested it in the stable 4.6. version as well as in the latest 4.6.1. Maintenance build and it's happening in Composite and also in non-Composite project and in Project-TestRunner, TestSuite-TestRunner and TestCase-TestRunner too.
Could you, please, investigate this?
Adding specific example with logs (I had to remove some confidential data)
Example: Before the TestRunner, environment "Env1" was set as active, in TestRunner I set the environment "Env2", but as can you see from the logs, the active environment is still environment "Env1", instead of expected environment "Env2"
Thanks in advance
Regards,
Marek
after couple of scripts and some debugging I've realized, that the "E parameter" in automation/command line isn't working correctly.
So I checked this in SoapUI, in the "Launch TestRunner" feature and it looks like I was right, there is a problem in setting/overriding the environment while using TestRunner or using SoapUI in automating the tests (with NAnt scripts).
I attached some simple script to verify this.
In this attached project, I set some active environment (it doesn't matter if it was in TestSuite or TestCase) and in "Launch TestRunner" I overrided the environment to something else, the environment wasn't changed.
It looks like this functionality is broken since the new 4.6 version and it has a very bad impact for our test framework.
I've tested it in the stable 4.6. version as well as in the latest 4.6.1. Maintenance build and it's happening in Composite and also in non-Composite project and in Project-TestRunner, TestSuite-TestRunner and TestCase-TestRunner too.
Could you, please, investigate this?
Adding specific example with logs (I had to remove some confidential data)
Example: Before the TestRunner, environment "Env1" was set as active, in TestRunner I set the environment "Env2", but as can you see from the logs, the active environment is still environment "Env1", instead of expected environment "Env2"
Running SoapUI TestRunner for [Test]
directory: C:\Program Files\SmartBear\SoapUI-Pro-4.6.1-m-SNAPSHOT\bin\.
command: cmd.exe /C testrunner.bat -s"TestSuite 1" -c"TestCase 1" -R"TestSuite Report" -EEnv2 C:\Users\mciz\Desktop\Test-soapui-project.xml
SoapUI Pro 4.6.1-m-SNAPSHOT TestCase Runner
Configuring log4j from [C:\Program Files\SmartBear\SoapUI-Pro-4.6.1-m-SNAPSHOT\bin\soapui-log4j.xml]
23:47:16,211 INFO [SoapUI] Adding [C:\Program Files\SmartBear\SoapUI-Pro-4.6.1-m-SNAPSHOT\bin\ext\postgresql-8.3-604.jdbc3.jar] to extensions classpath
23:47:16,213 INFO [SoapUI] Adding [C:\Program Files\SmartBear\SoapUI-Pro-4.6.1-m-SNAPSHOT\bin\ext\postgresql-8.3-604.jdbc4.jar] to extensions classpath
23:47:16,213 INFO [SoapUI] Adding [C:\Program Files\SmartBear\SoapUI-Pro-4.6.1-m-SNAPSHOT\bin\ext\sqljdbc.jar] to extensions classpath
23:47:16,709 INFO [DefaultSoapUICore] initialized soapui-settings from [C:\Users\mciz\soapui-settings.xml]
23:47:17,219 INFO [SoapUIProGroovyScriptEngineFactory] Setting Script Library to [C:\*****\****\Regression_tests\Master Project\Scripts]
23:47:17,222 INFO [DefaultSoapUICore] Adding listeners from [C:\Program Files\SmartBear\SoapUI-Pro-4.6.1-m-SNAPSHOT\bin\listeners\demo-listeners.xml]
23:47:18,896 INFO [WsdlProject] Loaded project from [file:/C:/Users/mciz/Desktop/Test-soapui-project.xml]
23:47:18,998 INFO [SoapUIProGroovyScriptEngineFactory] Setting Script Library to [C:\*****\*****\Regression_tests\Master Project\Scripts]
23:47:19,650 INFO [SoapUIProTestCaseRunner] Running SoapUI tests in project [Test]
23:47:19,704 INFO [SoapUIProTestCaseRunner] Running TestCase [TestCase 1]
23:47:19,712 INFO [SoapUIProTestCaseRunner] Running SoapUI testcase [TestCase 1]
23:47:19,738 INFO [SoapUIProTestCaseRunner] running step [Groovy Script]
23:47:20,508 INFO [log] Current active environment: Env1
23:47:20,509 INFO [log] Looping over all Environments...
23:47:20,569 INFO [log] 1. environment: Env1
23:47:20,569 INFO [log] 2. environment: Env2
23:47:20,569 INFO [log] 3. environment: Env3
23:47:20,577 INFO [SoapUIProTestCaseRunner] Finished running SoapUI testcase [TestCase 1], time taken: 825ms, status: FINISHED
23:47:20,584 INFO [SoapUIProTestCaseRunner] TestCase [TestCase 1] finished with status [FINISHED] in 825ms
Thanks in advance
Regards,
Marek