Build a WCF in VS locally will also not copy the .svc
file by default. Right click the file and select properties, the default value of Build Action is content
and Copy to Output Directory is Do not Copy
.
If you really want to copy this file, you could add a task in your .csproj
file to achieve it. A sample for your reference:
<Target Name="AfterBuild">
<PropertyGroup>
<SolutionDir>$([System.IO.Path]::GetDirectoryName($(MSBuildProjectDirectory)))</SolutionDir>
</PropertyGroup>
<PropertyGroup>
<CopyFileOutput>$(SolutionDir)\WebUI.UnitTest\bin\Debug\WebUI.UnitTest.dll;$(SolutionDir)\Core.UnitTest\bin\Debug\Core.UnitTest.dll</CopyFileOutput>
</PropertyGroup>
<Copy
SourceFiles="$(CopyFileOutput)"
DestinationFolder="$(SolutionDir)\WebUI\bin"
/>
</Target>