One of our customers uses Visual Studio Online which is based on capabilities of Team Foundation Server (TFS)
We were researching how to do automated Builds and automated Unit Tests using the Visual Studio Online hosted build agent.
We are trying to build one of our Web Applications on it.
Our Web Application solution contains a number of csproj files under the solution.
Note: The Web Applications will build properly and run properly on our local development computers using Visual Studio 2012.
However, when we build the web application on the Visual Studio Online's Hosted Build Agent, it throws the following error about not finding the my application's main dll( my application is called BlahBlah ):
C:\Program Files (x86)\MSBuild\Microsoft\ VisualStudio\v11.0\WebApplications\Microsoft.WebApplication.targets (182): Could not copy the file "bin\BlahBlah.dll" because it was not found. C:\Program Files (x86)\MSBuild\Microsoft\VisualStudio\v11.0\WebApplications\Microsoft.WebApplication.targets (182): Could not copy the file "bin\BlahBlah.pdb" because it was not found.
Therefore, I checked the various csproj files within our Web Application solutions, and I found the following code:
<Content Include="bin\BlahBlah.dll" />
<Content Include="bin\BlahBlah.pdb" />
In order to make it run properly on the Visual Studio Online's Hosted Build Agent, the above references were replaced by the following:
<Content Include="bin\BlahBlah.dll" Condition="$(IsDesktopBuild) == true" />
<Content Include="bin\BlahBlah.pdb" Condition="$(IsDesktopBuild) == true" />
<None Include="bin\BlahBlah.dll" Condition="$(IsDesktopBuild) != true" />
<None Include="bin\BlahBlah.pdb" Condition="$(IsDesktopBuild) != true" />
After replacing the references, our application would build properly on the Visual Studio Online's Hosted Build Agent.
However, Should I Exclude references to the bin..project..dll in TFS or Visual Studio ONline Builds? In other words, is my above successful build a "False Pass" ?