Skip to content
Browse files

TDNetRunner prepares necessary files for itself

  • Loading branch information...
1 parent 50c9048 commit 9fb7fb4fab788a68d068e6d44ae1e6df60cec34e @danielmarbach danielmarbach committed Jan 3, 2014
View
15 Source/Runners/Machine.Specifications.TDNetRunner/Machine.Specifications.TDNetRunner.csproj
@@ -83,10 +83,7 @@
<None Include="InstallTDNetRunnerSilent.bat">
<CopyToOutputDirectory>Always</CopyToOutputDirectory>
</None>
- <None Include="Machine.Specifications.dll.tdnet">
- <CopyToOutputDirectory>Always</CopyToOutputDirectory>
- </None>
- <None Include="Machine.Specifications.dll.tdnet.template" />
+ <None Include="Machine.Specifications.dll.tdnet" />
</ItemGroup>
<ItemGroup>
<BootstrapperPackage Include="Microsoft.Net.Client.3.5">
@@ -112,11 +109,17 @@
<PreBuildEvent>
</PreBuildEvent>
</PropertyGroup>
+ <!-- The after build task prepares the tdnet file -->
+ <Target Name="AfterBuild">
+ <GetAssemblyIdentity AssemblyFiles="$(TargetPath)">
+ <Output TaskParameter="Assemblies" ItemName="AssemblyInfo"/>
+ </GetAssemblyIdentity>
+ <Copy SourceFiles="$(ProjectDir)\Machine.Specifications.dll.tdnet" DestinationFiles="$(TargetDir)\Machine.Specifications.dll.tdnet" />
+ <XmlPoke XmlInputPath="$(TargetDir)\Machine.Specifications.dll.tdnet" Query="//ns:FriendlyName" Value="Machine.Specifications %(AssemblyInfo.Version)" Namespaces="&lt;Namespace Prefix='ns' Uri='' /&gt;" />
+ </Target>
<!-- To modify your build process, add your task inside one of the targets below and uncomment it.
Other similar extension points exist, see Microsoft.Common.targets.
<Target Name="BeforeBuild">
</Target>
- <Target Name="AfterBuild">
- </Target>
-->
</Project>
View
2 ...Machine.Specifications.dll.tdnet.template → ...etRunner/Machine.Specifications.dll.tdnet
@@ -1,5 +1,5 @@
<TestRunner>
- <FriendlyName>Machine.Specifications @configatron.version.full@</FriendlyName>
+ <FriendlyName><!-- WILL BE REPLACED BY AFTER BUILD--></FriendlyName>
<AssemblyPath>Machine.Specifications.TDNetRunner.dll</AssemblyPath>
<TypeName>Machine.Specifications.TDNetRunner.SpecificationRunner</TypeName>
</TestRunner>

0 comments on commit 9fb7fb4

Please sign in to comment.
Something went wrong with that request. Please try again.