Skip to content

Commit

Permalink
Switch to the new Source\Moq.NetCore.csproj
Browse files Browse the repository at this point in the history
Remove the PCL project from Moq.sln, but didn't add the new one
because the NuGet.Restore.targets doesn't handle the new project. When
invoking `nuget.exe Restore Moq.sln`, nuget.exe tries to use MSBuild
14.0 which fails on the new .csproj.
  • Loading branch information
jeremymeng committed Apr 15, 2017
1 parent bc8ad39 commit 9b595f7
Show file tree
Hide file tree
Showing 6 changed files with 32 additions and 34 deletions.
12 changes: 6 additions & 6 deletions Moq.NetCore.sln
Original file line number Diff line number Diff line change
Expand Up @@ -3,8 +3,6 @@ Microsoft Visual Studio Solution File, Format Version 12.00
# Visual Studio 15
VisualStudioVersion = 15.0.26206.0
MinimumVisualStudioVersion = 10.0.40219.1
Project("{FAE04EC0-301F-11D3-BF4B-00C04F79EFBC}") = "Moq.NetCore", "Source.NetCore\Moq.NetCore.csproj", "{F04EAC58-919C-4CB5-9250-B38DE6FB5ED9}"
EndProject
Project("{2150E333-8FDC-42A3-9474-1A3956D46DE8}") = "Solution Items", "Solution Items", "{EFFD4CEA-0C67-4B36-B2FE-CDADBACE1C5C}"
EndProject
Project("{9A19103F-16F7-4668-BE54-9A1E7A4F7556}") = "ClassLibrary1", "UnitTests.NetCore\ClassLibrary1\ClassLibrary1.csproj", "{48DF0ABB-450B-4617-B3F3-14E92CE2C7B6}"
Expand All @@ -13,16 +11,14 @@ Project("{9A19103F-16F7-4668-BE54-9A1E7A4F7556}") = "ClassLibrary2", "UnitTests.
EndProject
Project("{9A19103F-16F7-4668-BE54-9A1E7A4F7556}") = "Moq.NetCore.Tests", "UnitTests.NetCore\Moq.NetCore.Tests\Moq.NetCore.Tests.csproj", "{193B5DD4-77B8-4B36-8E62-C0E6BD733FAA}"
EndProject
Project("{9A19103F-16F7-4668-BE54-9A1E7A4F7556}") = "Moq.NetCore", "Source\Moq.NetCore.csproj", "{4BA03097-04CA-4B7C-B618-5AAD1B27B4B5}"
EndProject
Global
GlobalSection(SolutionConfigurationPlatforms) = preSolution
Debug|Any CPU = Debug|Any CPU
Release|Any CPU = Release|Any CPU
EndGlobalSection
GlobalSection(ProjectConfigurationPlatforms) = postSolution
{F04EAC58-919C-4CB5-9250-B38DE6FB5ED9}.Debug|Any CPU.ActiveCfg = Debug|Any CPU
{F04EAC58-919C-4CB5-9250-B38DE6FB5ED9}.Debug|Any CPU.Build.0 = Debug|Any CPU
{F04EAC58-919C-4CB5-9250-B38DE6FB5ED9}.Release|Any CPU.ActiveCfg = Release|Any CPU
{F04EAC58-919C-4CB5-9250-B38DE6FB5ED9}.Release|Any CPU.Build.0 = Release|Any CPU
{48DF0ABB-450B-4617-B3F3-14E92CE2C7B6}.Debug|Any CPU.ActiveCfg = Debug|Any CPU
{48DF0ABB-450B-4617-B3F3-14E92CE2C7B6}.Debug|Any CPU.Build.0 = Debug|Any CPU
{48DF0ABB-450B-4617-B3F3-14E92CE2C7B6}.Release|Any CPU.ActiveCfg = Release|Any CPU
Expand All @@ -35,6 +31,10 @@ Global
{193B5DD4-77B8-4B36-8E62-C0E6BD733FAA}.Debug|Any CPU.Build.0 = Debug|Any CPU
{193B5DD4-77B8-4B36-8E62-C0E6BD733FAA}.Release|Any CPU.ActiveCfg = Release|Any CPU
{193B5DD4-77B8-4B36-8E62-C0E6BD733FAA}.Release|Any CPU.Build.0 = Release|Any CPU
{4BA03097-04CA-4B7C-B618-5AAD1B27B4B5}.Debug|Any CPU.ActiveCfg = Debug|Any CPU
{4BA03097-04CA-4B7C-B618-5AAD1B27B4B5}.Debug|Any CPU.Build.0 = Debug|Any CPU
{4BA03097-04CA-4B7C-B618-5AAD1B27B4B5}.Release|Any CPU.ActiveCfg = Release|Any CPU
{4BA03097-04CA-4B7C-B618-5AAD1B27B4B5}.Release|Any CPU.Build.0 = Release|Any CPU
EndGlobalSection
GlobalSection(SolutionProperties) = preSolution
HideSolutionNode = FALSE
Expand Down
8 changes: 4 additions & 4 deletions Moq.nuspec
Original file line number Diff line number Diff line change
Expand Up @@ -210,9 +210,9 @@ Version 1.0
<!-- Could not verify that GitLink works, so disabling pdbs for now -->
<!--<file src="Source\bin\$configuration$\Moq.pdb" target="lib\net45" />-->
<file src="Source\bin\$configuration$\Moq.xml" target="lib\net45" />
<file src="Source.NetCore\bin\$configuration$\Moq.dll" target="lib\netstandard1.3" />
<file src="Source\bin\$configuration$\netstandard1.3\Moq.dll" target="lib\netstandard1.3" />
<!-- Could not verify that GitLink works, so disabling pdbs for now -->
<!--<file src="Source.NetCore\bin\$configuration$\Moq.pdb" target="lib\netstandard1.3" />-->
<file src="Source.NetCore\bin\$configuration$\Moq.xml" target="lib\netstandard1.3" />
<!--<file src="Source\bin\$configuration$\netstandard1.3\Moq.pdb" target="lib\netstandard1.3" />-->
<file src="Source\bin\$configuration$\netstandard1.3\Moq.xml" target="lib\netstandard1.3" />
</files>
</package>
</package>
14 changes: 2 additions & 12 deletions Moq.sln
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
Microsoft Visual Studio Solution File, Format Version 12.00
# Visual Studio 14
VisualStudioVersion = 14.0.25123.0
# Visual Studio 15
VisualStudioVersion = 15.0.26206.0
MinimumVisualStudioVersion = 10.0.40219.1
Project("{2150E333-8FDC-42A3-9474-1A3956D46DE8}") = "Solution Items", "Solution Items", "{A5A5B8C3-D43F-43C6-AEC7-6FA7C35B8BE9}"
ProjectSection(SolutionItems) = preProject
Expand All @@ -17,8 +17,6 @@ Project("{FAE04EC0-301F-11D3-BF4B-00C04F79EFBC}") = "Moq", "Source\Moq.csproj",
EndProject
Project("{FAE04EC0-301F-11D3-BF4B-00C04F79EFBC}") = "Moq.Tests", "UnitTests\Moq.Tests.csproj", "{81BBC911-4916-4E10-A955-752AE47CB2B9}"
EndProject
Project("{FAE04EC0-301F-11D3-BF4B-00C04F79EFBC}") = "Moq.NetCore", "Source.NetCore\Moq.NetCore.csproj", "{F04EAC58-919C-4CB5-9250-B38DE6FB5ED9}"
EndProject
Project("{F184B08F-C81C-45F6-A57F-5ABD9991F28F}") = "Moq.VisualBasicTests", "Moq.VisualBasicTests\Moq.VisualBasicTests.vbproj", "{95F2E2B2-2E06-4AC7-A86F-9B1B6369D4AD}"
EndProject
Global
Expand All @@ -41,14 +39,6 @@ Global
{81BBC911-4916-4E10-A955-752AE47CB2B9}.Release|Any CPU.ActiveCfg = Release|Any CPU
{81BBC911-4916-4E10-A955-752AE47CB2B9}.Release|Any CPU.Build.0 = Release|Any CPU
{81BBC911-4916-4E10-A955-752AE47CB2B9}.Release|x86.ActiveCfg = Release|Any CPU
{F04EAC58-919C-4CB5-9250-B38DE6FB5ED9}.Debug|Any CPU.ActiveCfg = Debug|Any CPU
{F04EAC58-919C-4CB5-9250-B38DE6FB5ED9}.Debug|Any CPU.Build.0 = Debug|Any CPU
{F04EAC58-919C-4CB5-9250-B38DE6FB5ED9}.Debug|x86.ActiveCfg = Debug|Any CPU
{F04EAC58-919C-4CB5-9250-B38DE6FB5ED9}.Debug|x86.Build.0 = Debug|Any CPU
{F04EAC58-919C-4CB5-9250-B38DE6FB5ED9}.Release|Any CPU.ActiveCfg = Release|Any CPU
{F04EAC58-919C-4CB5-9250-B38DE6FB5ED9}.Release|Any CPU.Build.0 = Release|Any CPU
{F04EAC58-919C-4CB5-9250-B38DE6FB5ED9}.Release|x86.ActiveCfg = Release|Any CPU
{F04EAC58-919C-4CB5-9250-B38DE6FB5ED9}.Release|x86.Build.0 = Release|Any CPU
{95F2E2B2-2E06-4AC7-A86F-9B1B6369D4AD}.Debug|Any CPU.ActiveCfg = Debug|Any CPU
{95F2E2B2-2E06-4AC7-A86F-9B1B6369D4AD}.Debug|Any CPU.Build.0 = Debug|Any CPU
{95F2E2B2-2E06-4AC7-A86F-9B1B6369D4AD}.Debug|x86.ActiveCfg = Debug|Any CPU
Expand Down
21 changes: 14 additions & 7 deletions Source/Moq.NetCore.csproj
Original file line number Diff line number Diff line change
Expand Up @@ -16,17 +16,24 @@

<PropertyGroup Condition="'$(Configuration)|$(Platform)'=='Debug|AnyCPU'">
<NoWarn>1701;1702;1705;0419</NoWarn>
<DocumentationFile>bin\Debug\netstandard1.3\Moq.xml</DocumentationFile>
</PropertyGroup>

<PropertyGroup Condition="'$(Configuration)|$(Platform)'=='Release|AnyCPU'">
<NoWarn>1701;1702;1705;0419</NoWarn>
<DocumentationFile>bin\Release\netstandard1.3\Moq.xml</DocumentationFile>
</PropertyGroup>

<ItemGroup Condition=" '$(TargetFramework)' == 'netstandard1.3' ">
<PackageReference Include="Castle.Core" Version="4.0.0" />
<PackageReference Include="IFluentInterface" Version="2.0.3" />
<PackageReference Include="GitInfo" Version="1.1.48" />
<PackageReference Include="Microsoft.CSharp" Version="4.3.0" />
<PackageReference Include="System.Diagnostics.StackTrace" Version="4.3.0" />
<PackageReference Include="System.Linq.Queryable" Version="4.3.0" />
<PackageReference Include="System.Reflection.Emit" Version="4.3.0" />
<PackageReference Include="System.Reflection.TypeExtensions" Version="4.3.0" />
<PackageReference Include="IFluentInterface" Version="2.0.0" />
<PackageReference Include="GitInfo" Version="1.1.14" />
<PackageReference Include="Microsoft.CSharp" Version="4.0.1" />
<PackageReference Include="System.Diagnostics.StackTrace" Version="4.0.1" />
<PackageReference Include="System.Linq.Queryable" Version="4.0.1" />
<PackageReference Include="System.Reflection.Emit" Version="4.0.1" />
<PackageReference Include="System.Reflection.Extensions" Version="4.0.1" />
<PackageReference Include="System.Reflection.TypeExtensions" Version="4.1.0" />
</ItemGroup>

</Project>
Original file line number Diff line number Diff line change
Expand Up @@ -35,7 +35,7 @@
</ItemGroup>

<ItemGroup>
<ProjectReference Include="..\..\Source.NetCore\Moq.NetCore.csproj" />
<ProjectReference Include="..\..\Source\Moq.NetCore.csproj" />
<ProjectReference Include="..\ClassLibrary1\ClassLibrary1.csproj" />
<ProjectReference Include="..\ClassLibrary2\ClassLibrary2.csproj" />
</ItemGroup>
Expand Down
9 changes: 5 additions & 4 deletions build.proj
Original file line number Diff line number Diff line change
Expand Up @@ -16,8 +16,9 @@
<Solution Include="Moq.sln"/>
<NuSpec Include="Moq.nuspec" />
<TestProject Include="UnitTests\Moq.Tests.csproj" />
<NetCoreTestProject Include="UnitTests.NetCore\Moq.NetCore.Tests\Moq.NetCore.Tests.csproj" />
<Source Include="Source\Moq.csproj" />
<NetCoreSolution Include="Moq.NetCore.sln" />
<NetCoreTestProject Include="UnitTests.NetCore\Moq.NetCore.Tests\Moq.NetCore.Tests.csproj" />
</ItemGroup>

<Target Name="Clean">
Expand All @@ -32,7 +33,9 @@
<Target Name="Build" DependsOnTargets="GitVersion">
<MSBuild Projects="@(Solution)" Properties="$(CommonBuildProperties)" />

<Exec Command="xcopy &quot;Source.NetCore\bin\$(Configuration)\Moq.*&quot; &quot;$(DropDirectory)lib\netstandard1.3\&quot; /Y" ContinueOnError="false" />
<MSBuild Projects="@(NetCoreSolution)" BuildInParallel="false" Targets="Restore;Build" Properties="$(CommonBuildProperties)" />

<Exec Command="xcopy &quot;Source\bin\$(Configuration)\netstandard1.3\Moq.*&quot; &quot;$(DropDirectory)lib\netstandard1.3\&quot; /Y" ContinueOnError="false" />

<Exec Command="$(PackagesPath)\gitlink\lib\net45\GitLink.exe . -f &quot;$([System.String]::new('%(Solution.FullPath)').Replace('$(MSBuildProjectDirectory)', '').TrimStart('\'))&quot; -skipverify -u https://github.com/moq/moq4 -b $(GitBranch) -c $(Configuration)" />
</Target>
Expand All @@ -46,8 +49,6 @@
<TestAssembly Include="@(_TestAssembly)" Condition=" Exists('%(_TestAssembly.FullPath)') " />
</ItemGroup>

<MSBuild Projects="@(NetCoreTestProject)" BuildInParallel="false" Targets="Restore;Build" Properties="$(CommonBuildProperties)" />

<PropertyGroup>
<XunitConsole>$(PackagesPath)\xunit.runner.console\tools\xunit.console.exe</XunitConsole>
<XunitOptions>$(XunitOptions) -html $(Out)\test.html -xml $(Out)\test.xml -parallel all -noshadow</XunitOptions>
Expand Down

0 comments on commit 9b595f7

Please sign in to comment.