Test Threads not starting with config transform

528 views
Skip to first unread message

Rahul Dixit

unread,
Oct 30, 2013, 6:07:23 PM10/30/13
to spe...@googlegroups.com
Hi All,


When running SpecRun with multiple threads, I get the below error.
It occurs randomly one some threads and not on others.
Attached are the config files I am using.

Can anyone advise what is causing the issue and how to fix it please? Thanks.

Issue:

TechTalk.SpecRun.Framework.SpecRunException: At least one test thread aborted. -
--> TechTalk.SpecRun.Framework.SpecRunException: error in config transfrom (conf
igFile: C:\Projects\SelfService\Development\SelfService\SpecFlow\bin\Debug\Debit
success.SelfService.SpecFlow.dll.config)
<?xml version="1.0" encoding="utf-8"?>
              <configuration xmlns:xdt="http://schemas.microsoft.com/XML-Documen
t-Transform">
                <applicationSettings>
                      <SettingsNameSpace.SettingsFileName>
                        <setting name="browser" serializeAs="String">
                          <value xdt:Transform="Replace">firefox</value>
                        </setting>
                        <setting name="version" serializeAs="String">
                          <value xdt:Transform="Replace">22.0</value>
                        </setting>
                      </SettingsNameSpace.SettingsFileName>
                </applicationSettings>

              </configuration>
The process cannot access the file 'C:\Projects\SelfService\Development\SelfServ
ice\SpecFlow\bin\Debug\Debitsuccess.SelfService.SpecFlow.dll.config.bak' because
 it is being used by another process. ---> System.IO.IOException: The process ca
nnot access the file 'C:\Projects\SelfService\Development\SelfService\SpecFlow\b
in\Debug\Debitsuccess.SelfService.SpecFlow.dll.config.bak' because it is being u
sed by another process.
   at System.IO.__Error.WinIOError(Int32 errorCode, String maybeFullPath)
   at System.IO.File.InternalCopy(String sourceFileName, String destFileName, Bo
olean overwrite, Boolean checkHost)
   at TechTalk.SpecRun.Framework.DeploymentSteps.ConfigFileTransformationStep.Ba
ckup(String configFilePath, DeploymentContext deploymentContext) in c:\TeamCity\
buildAgent\work\1ace6ed01d0a43bb\TechTalk.SpecRun.Framework\DeploymentSteps\Conf
igFileTransformationStep.cs:line 43
   at TechTalk.SpecRun.Framework.DeploymentSteps.ConfigFileTransformationStep.Ap
ply(DeploymentContext deploymentContext) in c:\TeamCity\buildAgent\work\1ace6ed0
1d0a43bb\TechTalk.SpecRun.Framework\DeploymentSteps\ConfigFileTransformationStep
.cs:line 72
   --- End of inner exception stack trace ---
   at TechTalk.SpecRun.Framework.DeploymentSteps.ConfigFileTransformationStep.Ap
ply(DeploymentContext deploymentContext) in c:\TeamCity\buildAgent\work\1ace6ed0
1d0a43bb\TechTalk.SpecRun.Framework\DeploymentSteps\ConfigFileTransformationStep
.cs:line 93
   at TechTalk.SpecRun.Framework.DeploymentSteps.DeploymentContext.Apply(Deploym
entTransformationSteps steps, ITestRunTracer tracer) in c:\TeamCity\buildAgent\w
ork\1ace6ed01d0a43bb\TechTalk.SpecRun.Framework\DeploymentSteps\DeploymentContex
t.cs:line 150
   at TechTalk.SpecRun.Framework.TestThread.InitializeTestThreadExecutor(IAssemb
lyReference testAssembly, ExecutionModelSettings executionModelSettings, String
testTarget) in c:\TeamCity\buildAgent\work\1ace6ed01d0a43bb\TechTalk.SpecRun.Fra
mework\TestThread.cs:line 152
   at TechTalk.SpecRun.Framework.TestThread.GetThreadExecutorFor(TestItem testIt
em) in c:\TeamCity\buildAgent\work\1ace6ed01d0a43bb\TechTalk.SpecRun.Framework\T
estThread.cs:line 136
   at TechTalk.SpecRun.Framework.TestThread.Run(ITestExecutionManager executionM
anagerForRun) in c:\TeamCity\buildAgent\work\1ace6ed01d0a43bb\TechTalk.SpecRun.F
ramework\TestThread.cs:line 113
   at TechTalk.SpecRun.Framework.AsyncTestThreadRunner.RunSync(TestExecutionMana
ger executionManager) in c:\TeamCity\buildAgent\work\1ace6ed01d0a43bb\TechTalk.S
pecRun.Framework\AsyncTestThreadRunner.cs:line 33
   --- End of inner exception stack trace ---
Result: test framework error: At least one test thread aborted.


App.config
FF22.srprofile
IE10.srprofile

Hans Wurst

unread,
Nov 12, 2013, 7:28:03 PM11/12/13
to spe...@googlegroups.com
Have a look at this video:
http://youtu.be/h3j1amcsswc?t=4m

Cheers!

Rahul Dixit

unread,
Nov 13, 2013, 2:06:35 PM11/13/13
to spe...@googlegroups.com
Thanks, issue solved. relocated config file for each thread.
Reply all
Reply to author
Forward
0 new messages