Browse files

Changed the build.proj to auto start IIS and utilize a new MSBuild ba…

…sed start mechanism

- Removed the old StartIIS.ps1 powershell script, this is now handled
via msbuild.
  • Loading branch information...
1 parent 42cdfdf commit 965e9aea939b6f8627319832ff8fe3f1eeaf43e2 @NTaylorMullen NTaylorMullen committed Dec 14, 2012
Showing with 15 additions and 14 deletions.
  1. +13 −7 build/Build.proj
  2. +2 −0 build/Build.tasks
  3. +0 −7 tools/chutzpah/StartIIS.ps1
View
20 build/Build.proj
@@ -13,8 +13,12 @@
<NuGetExePath>$(NuGetToolsPath)\nuget.exe</NuGetExePath>
<ToolsPath>$(ProjectRoot)\tools\</ToolsPath>
<XunitPath>$(ToolsPath)xunit\</XunitPath>
- <ChutzpahExePath>$(ProjectRoot)\tools\chutzpah\chutzpah.console.exe</ChutzpahExePath>
- <JSTestsBridgeFile>$(ProjectRoot)\tests\Microsoft.AspNet.SignalR.Client.JS.Tests\CommandLineBridge.js</JSTestsBridgeFile>
+ <ChutzpahExe>chutzpah.console.exe</ChutzpahExe>
+ <ChutzpahPath>$(ProjectRoot)\tools\chutzpah</ChutzpahPath>
+ <ChutzpahExePath>$(ChutzpahPath)\$(ChutzpahExe)</ChutzpahExePath>
+ <JSTestsURL>http://localhost:1337/signalr</JSTestsURL>
+ <JSTestsPath>$(ProjectRoot)\tests\Microsoft.AspNet.SignalR.Client.JS.Tests</JSTestsPath>
+ <JSTester>$(JSTestsPath)\default.html</JSTester>
<DocuExePath>$(ToolsPath)docu\docu.exe</DocuExePath>
<ZipExe>$(ToolsPath)7za920\7za.exe</ZipExe>
<ScriptTempPath>$(ArtifactsDir)\Microsoft.AspNet.SignalR.Client.JS\Scripts</ScriptTempPath>
@@ -140,16 +144,18 @@
<Target Name="RunUnitTests" DependsOnTargets="CreateOutputDir">
<MSBuild Projects="%(UnitTestProjects.Identity)"
Targets="Build"
- Properties="Configuration=$(Configuration);ArtifactsDir=$(ArtifactsDir);SolutionDir=$(ProjectRoot)\;$(ExtraProperties)"
+ Properties="Configuration=$(Configuration);ArtifactsDir=$(ArtifactsDir);SolutionDir=$(ProjectRoot)\;$(ExtraProperties);CommandLineTest=true;TestURL=$(JSTestsURL);"
Condition=" '$(OS)' == 'Windows_NT'"/>
-
- <Exec Command="&quot;$(ChutzpahExePath)&quot; &quot;$(JSTestsBridgeFile)&quot; /silent" Condition=" '$(OS)' == 'Windows_NT'" />
- <RemoveDir Directories="$(ProjectRoot)\tests\Microsoft.AspNet.SignalR.Client.JS.Tests\temp" ContinueOnError="true"></RemoveDir>
- <Delete Files="$(ProjectRoot)\tests\Microsoft.AspNet.SignalR.Client.JS.Tests\CommandLineBridge.js" ContinueOnError="true"></Delete>
+
+ <StartIISTask HostLocation="$(JSTestsPath)" />
+ <!--
+ <Exec Command="$(ChutzpahExePath) $(JSTester) /silent" Condition=" '$(OS)' == 'Windows_NT'" />
<xunit Assembly="$(ArtifactsDir)\Microsoft.AspNet.SignalR.Tests\Microsoft.AspNet.SignalR.Tests.dll"
Xml="$(TestResultsPath)\Microsoft.AspNet.SignalR.Tests.XunitResults.xml"
Verbose="true" />
+ <CallTarget Targets="KillIISExpress" />
+ <OnError ExecuteTargets="KillIISExpress" />-->
</Target>
<Target Name="RunFunctionalTests" DependsOnTargets="CreateOutputDir">
View
2 build/Build.tasks
@@ -56,4 +56,6 @@
]]></Code>
</Task>
</UsingTask>
+
+ <UsingTask TaskName="StartIISTask" AssemblyFile="$(ProjectRoot)\tests\Microsoft.AspNet.SignalR.Tests.Common\bin\$(Configuration)\Microsoft.AspNet.SignalR.Tests.Common.dll"></UsingTask>
</Project>
View
7 tools/chutzpah/StartIIS.ps1
@@ -1,7 +0,0 @@
-[System.Reflection.Assembly]::LoadFile("C:\Users\nimullen\Documents\GitHub\SignalR\tests\Microsoft.AspNet.SignalR.FunctionalTests\artifacts\Debug\bin\Microsoft.AspNet.SignalR.FunctionalTests.dll");
-[System.Reflection.Assembly]::LoadFile("C:\Users\nimullen\Documents\GitHub\SignalR\tests\Microsoft.AspNet.SignalR.FunctionalTests\artifacts\Debug\bin\Microsoft.AspNet.SignalR.Client.dll");
-[System.IO.Directory]::SetCurrentDirectory("C:\Users\nimullen\Documents\GitHub\SignalR\tests\Microsoft.AspNet.SignalR.Client.JS.Tests")
-
-$myHost = New-Object Microsoft.AspNet.SignalR.FunctionalTests.Infrastructure.IISExpressTestHost "C:\Users\nimullen\Documents\GitHub\SignalR\tests\Microsoft.AspNet.SignalR.Client.JS.Tests"
-
-$myHost.Initialize(15,120,10,1)

0 comments on commit 965e9ae

Please sign in to comment.