1 Replies Last post: Jul 16, 2010 1:20 PM by Eugene Petrenko  
j w Newbie 2 posts since
Jun 22, 2010
Currently Being Moderated

Jul 15, 2010 2:01 PM

Use TeamCity environment variable in MStest

Hi,

 

I'm using TeamCity to run my build using VS2010 SLN runner. I'm also using the MSTest integration to run some tests.

 

My tests require some setup/teardown work which is done by two batch scripts which are defined in an MSTest config file (mstest /runconfig flag)

 

My problem is, these scripts need to know my source checkout directory %teamcity.build.checkoutDir%. However, when this variable is used in my batch scripts it cannot be resolved.

 

Is there any way I can use these variables in my batch scripts?

 

e.g.

 

cd %teamcity.build.checkoutDir%

"C:\Program Files\Windows Azure SDK\v1.2\bin\csrun.exe" SC.CloudService.csx ServiceConfiguration.cscfg

 

 

Thanks,

Eugene Petrenko JetBrains 2,377 posts since
Oct 4, 2004
Currently Being Moderated
Jul 16, 2010 1:20 PM in response to: j w
Re: Use TeamCity environment variable in MStest

Where have you put this reference? Those references are only resolved if used in web UI. You may use $(teamcity_build_checkoutDir) msbuild property inside msbuild script. Do you use TeamCity 5.1.x? There were some major improvements of support of .NET 4.0 in 5.1.x

More Like This

  • Retrieving data ...