Skip to content

Commit b1445a7

Browse files
committed
Target .NET Standard 2.0
- simplify .NET Standard projects and use Microsoft.NET.Sdk in test project - depend on Newtonsoft.Json v10 and Newtonsoft.Json.Bson v1 packages - Newtonsoft.Json v9.0.1 has a reduced API when targeting .NET Standard - adjust a few tests to handle changes between v9 and v10 - test .NET Standard library on both .NET 4.6.1 and .NET Core 2.0 - update test/Directory.Build.targets to handle testing with .NET Core; use it from Runtime.msbuild - adjust a few tests to handle .NET Core 2.0 differences and gaps - found and fixed a broken test in `HttpValueCollectionTest`
1 parent 63c080b commit b1445a7

17 files changed

+131
-557
lines changed

Runtime.msbuild

Lines changed: 7 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -100,8 +100,7 @@
100100
<ItemGroup>
101101
<_TestDLLsXunit Include="bin\$(Configuration)\test\*.Test.dll" />
102102
<_TestDLLsXunit Include="bin\$(Configuration)\test\*.Test.*.dll" />
103-
<_TestDLLsXunit Include="bin\$(Configuration)\Test\NetCore\*.Test.dll" />
104-
<_TestDLLsXunit Include="bin\$(Configuration)\Test\NetStandard\*.Test.dll" />
103+
<_TestDLLsXunit Include="bin\$(Configuration)\Test\NetCore\*.Test.dll" Condition="'$(BuildPortable)' == 'true'" />
105104
<_XunitProject Include="tools\WebStack.xunit.targets">
106105
<Properties>TestAssembly=%(_TestDLLsXunit.FullPath);XmlPath=$(TestResultsDirectory)%(_TestDLLsXunit.FileName)-XunitResults.xml</Properties>
107106
</_XunitProject>
@@ -112,6 +111,12 @@
112111
<MakeDir Directories="$(TestResultsDirectory)" />
113112

114113
<MSBuild Projects="@(_XunitProject)" BuildInParallel="$(TestInParallel)" Targets="Xunit" />
114+
115+
<!-- Failures in this project will fail build. But, results will not be included in test run summary. -->
116+
<MSBuild
117+
Projects="test\System.Net.Http.Formatting.NetStandard.Test\System.Net.Http.Formatting.NetStandard.Test.csproj"
118+
Targets="Test"
119+
Condition="'$(BuildPortable)' == 'true'" />
115120
</Target>
116121

117122
<Target Name="CheckSkipStrongNames" DependsOnTargets="RestoreSkipStrongNames">

RuntimePortable.sln

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,7 @@
11

22
Microsoft Visual Studio Solution File, Format Version 12.00
33
# Visual Studio 15
4-
VisualStudioVersion = 15.0.27019.1
4+
VisualStudioVersion = 15.0.27116.1
55
MinimumVisualStudioVersion = 15.0
66
Project("{2150E333-8FDC-42A3-9474-1A3956D46DE8}") = "src", "src", "{A9836F9E-6DB3-4D9F-ADCA-CF42D8C8BA93}"
77
EndProject
@@ -15,7 +15,7 @@ Project("{FAE04EC0-301F-11D3-BF4B-00C04F79EFBC}") = "System.Net.Http.Formatting.
1515
EndProject
1616
Project("{9A19103F-16F7-4668-BE54-9A1E7A4F7556}") = "System.Net.Http.Formatting.NetStandard", "src\System.Net.Http.Formatting.NetStandard\System.Net.Http.Formatting.NetStandard.csproj", "{636CA76A-C85C-42E2-B4AA-88046279B3CA}"
1717
EndProject
18-
Project("{FAE04EC0-301F-11D3-BF4B-00C04F79EFBC}") = "System.Net.Http.Formatting.NetStandard.Test", "test\System.Net.Http.Formatting.NetStandard.Test\System.Net.Http.Formatting.NetStandard.Test.csproj", "{DECB05DF-B33A-44A0-B5DE-B14A8CE0740F}"
18+
Project("{9A19103F-16F7-4668-BE54-9A1E7A4F7556}") = "System.Net.Http.Formatting.NetStandard.Test", "test\System.Net.Http.Formatting.NetStandard.Test\System.Net.Http.Formatting.NetStandard.Test.csproj", "{DECB05DF-B33A-44A0-B5DE-B14A8CE0740F}"
1919
EndProject
2020
Project("{2150E333-8FDC-42A3-9474-1A3956D46DE8}") = "Solution Items", "Solution Items", "{A72045D4-B048-4697-9535-C3A6EDCA85B9}"
2121
ProjectSection(SolutionItems) = preProject

src/Directory.Build.props

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -4,6 +4,6 @@
44
<PropertyGroup>
55
<IsPackable>true</IsPackable>
66
<IsTestProject>false</IsTestProject>
7-
<TargetFrameworkVersion>v4.5</TargetFrameworkVersion>
7+
<TargetFrameworkVersion Condition="'$(MSBuildProjectName)' != 'System.Net.Http.Formatting.NetStandard'">v4.5</TargetFrameworkVersion>
88
</PropertyGroup>
99
</Project>

src/System.Net.Http.Formatting.NetStandard/System.Net.Http.Formatting.NetStandard.csproj

Lines changed: 20 additions & 208 deletions
Original file line numberDiff line numberDiff line change
@@ -1,39 +1,36 @@
11
<Project Sdk="Microsoft.NET.Sdk">
22
<Import Project="$([MSBuild]::GetDirectoryNameOfFileAbove($(MSBuildThisFileDirectory),Runtime.sln))\tools\WebStack.settings.targets" />
33
<PropertyGroup>
4-
<TargetFramework>netstandard1.1</TargetFramework>
4+
<TargetFramework>netstandard2.0</TargetFramework>
55
<RootNamespace>System.Net.Http</RootNamespace>
66
<AssemblyName>System.Net.Http.Formatting</AssemblyName>
77
<OutputPath>$(OutputPath)NetStandard\</OutputPath>
88
<DocumentationFile>$(OutputPath)$(AssemblyName).xml</DocumentationFile>
9-
<NetStandardImplicitPackageVersion>1.6.0</NetStandardImplicitPackageVersion>
10-
<RunCodeAnalysis>$(CodeAnalysis)</RunCodeAnalysis>
11-
<CodeAnalysisRuleSet>..\Strict.ruleset</CodeAnalysisRuleSet>
12-
<CodeAnalysisAdditionalOptions> /assemblycomparemode:StrongNameIgnoringVersion</CodeAnalysisAdditionalOptions>
13-
<CodeAnalysisSearchGlobalAssemblyCache>false</CodeAnalysisSearchGlobalAssemblyCache>
14-
<DefineConstants>$(DefineConstants);NETFX_CORE;ASPNETMVC;NOT_CLS_COMPLIANT;NETSTANDARD1_1</DefineConstants>
9+
<RunCodeAnalysis>false</RunCodeAnalysis>
10+
<DefineConstants>$(DefineConstants);ASPNETMVC;NEWTONSOFTJSON10</DefineConstants>
1511
<NoWarn>1591</NoWarn>
16-
<TargetFrameworkVersion></TargetFrameworkVersion>
1712
<AppendTargetFrameworkToOutputPath>false</AppendTargetFrameworkToOutputPath>
1813
<Configurations>$(Configurations);CodeAnalysis</Configurations>
1914
<GenerateAssemblyInfo>false</GenerateAssemblyInfo>
2015
</PropertyGroup>
21-
2216
<ItemGroup>
23-
<PackageReference Include="Newtonsoft.Json" Version="9.0.1" />
24-
<PackageReference Include="System.ComponentModel.EventBasedAsync" Version="4.0.11" />
25-
<PackageReference Include="System.Diagnostics.Contracts" Version="4.0.1" />
26-
<PackageReference Include="System.Runtime.Serialization.Xml" Version="4.1.1" />
27-
<PackageReference Include="System.Xml.XmlSerializer" Version="4.0.11" />
17+
<PackageReference Include="Newtonsoft.Json" Version="10.0.1" />
18+
<PackageReference Include="Newtonsoft.Json.Bson" Version="1.0.1" />
2819
</ItemGroup>
29-
3020
<ItemGroup>
3121
<Compile Include="..\CommonAssemblyInfo.cs">
3222
<Link>Properties\CommonAssemblyInfo.cs</Link>
3323
</Compile>
24+
25+
<Compile Include="..\Common\CollectionExtensions.cs">
26+
<Link>Common\CollectionExtensions.cs</Link>
27+
</Compile>
3428
<Compile Include="..\Common\Error.cs">
3529
<Link>Common\Error.cs</Link>
3630
</Compile>
31+
<Compile Include="..\Common\ListWrapperCollection.cs">
32+
<Link>Common\ListWrapperCollection.cs</Link>
33+
</Compile>
3734
<Compile Include="..\Common\TaskHelpers.cs">
3835
<Link>Common\TaskHelpers.cs</Link>
3936
</Compile>
@@ -43,197 +40,9 @@
4340
<Compile Include="..\Common\UriQueryUtility.cs">
4441
<Link>Common\UriQueryUtility.cs</Link>
4542
</Compile>
46-
<Compile Include="..\Common\CollectionExtensions.cs">
47-
<Link>Common\CollectionExtensions.cs</Link>
48-
</Compile>
49-
<Compile Include="..\Common\ListWrapperCollection.cs">
50-
<Link>Common\ListWrapperCollection.cs</Link>
51-
</Compile>
52-
<Compile Include="..\System.Net.Http.Formatting\FormattingUtilities.cs">
53-
<Link>FormattingUtilities.cs</Link>
54-
</Compile>
55-
<Compile Include="..\System.Net.Http.Formatting\Formatting\BaseJsonMediaTypeFormatter.cs">
56-
<Link>Formatting\BaseJsonMediaTypeFormatter.cs</Link>
57-
</Compile>
58-
<Compile Include="..\System.Net.Http.Formatting\Formatting\BsonMediaTypeFormatter.cs">
59-
<Link>Formatting\BsonMediaTypeFormatter.cs</Link>
60-
</Compile>
61-
<Compile Include="..\System.Net.Http.Formatting\Formatting\DelegatingEnumerable.cs">
62-
<Link>Formatting\DelegatingEnumerable.cs</Link>
63-
</Compile>
64-
<Compile Include="..\System.Net.Http.Formatting\Formatting\FormDataCollection.cs">
65-
<Link>Formatting\FormDataCollection.cs</Link>
66-
</Compile>
67-
<Compile Include="..\System.Net.Http.Formatting\Formatting\FormUrlEncodedJson.cs">
68-
<Link>Formatting\FormUrlEncodedJson.cs</Link>
69-
</Compile>
70-
<Compile Include="..\System.Net.Http.Formatting\Formatting\FormUrlEncodedMediaTypeFormatter.cs">
71-
<Link>Formatting\FormUrlEncodedMediaTypeFormatter.cs</Link>
72-
</Compile>
73-
<Compile Include="..\System.Net.Http.Formatting\Formatting\IFormatterLogger.cs">
74-
<Link>Formatting\IFormatterLogger.cs</Link>
75-
</Compile>
76-
<Compile Include="..\System.Net.Http.Formatting\Formatting\JsonMediaTypeFormatter.cs">
77-
<Link>Formatting\JsonMediaTypeFormatter.cs</Link>
78-
</Compile>
79-
<Compile Include="..\System.Net.Http.Formatting\Formatting\MediaTypeConstants.cs">
80-
<Link>Formatting\MediaTypeConstants.cs</Link>
81-
</Compile>
82-
<Compile Include="..\System.Net.Http.Formatting\Formatting\MediaTypeFormatter.cs">
83-
<Link>Formatting\MediaTypeFormatter.cs</Link>
84-
</Compile>
85-
<Compile Include="..\System.Net.Http.Formatting\Formatting\MediaTypeFormatterCollection.cs">
86-
<Link>Formatting\MediaTypeFormatterCollection.cs</Link>
87-
</Compile>
88-
<Compile Include="..\System.Net.Http.Formatting\Formatting\MediaTypeHeaderValueExtensions.cs">
89-
<Link>Formatting\MediaTypeHeaderValueExtensions.cs</Link>
90-
</Compile>
91-
<Compile Include="..\System.Net.Http.Formatting\Formatting\MediaTypeHeaderValueRange.cs">
92-
<Link>Formatting\MediaTypeHeaderValueRange.cs</Link>
93-
</Compile>
94-
<Compile Include="..\System.Net.Http.Formatting\Formatting\ParsedMediaTypeHeaderValue.cs">
95-
<Link>Formatting\ParsedMediaTypeHeaderValue.cs</Link>
96-
</Compile>
97-
<Compile Include="..\System.Net.Http.Formatting\Formatting\Parsers\FormUrlEncodedParser.cs">
98-
<Link>Formatting\Parsers\FormUrlEncodedParser.cs</Link>
99-
</Compile>
100-
<Compile Include="..\System.Net.Http.Formatting\Formatting\Parsers\HttpRequestHeaderParser.cs">
101-
<Link>Formatting\Parsers\HttpRequestHeaderParser.cs</Link>
102-
</Compile>
103-
<Compile Include="..\System.Net.Http.Formatting\Formatting\Parsers\HttpRequestLineParser.cs">
104-
<Link>Formatting\Parsers\HttpRequestLineParser.cs</Link>
105-
</Compile>
106-
<Compile Include="..\System.Net.Http.Formatting\Formatting\Parsers\HttpResponseHeaderParser.cs">
107-
<Link>Formatting\Parsers\HttpResponseHeaderParser.cs</Link>
108-
</Compile>
109-
<Compile Include="..\System.Net.Http.Formatting\Formatting\Parsers\HttpStatusLineParser.cs">
110-
<Link>Formatting\Parsers\HttpStatusLineParser.cs</Link>
111-
</Compile>
112-
<Compile Include="..\System.Net.Http.Formatting\Formatting\Parsers\InternetMessageFormatHeaderParser.cs">
113-
<Link>Formatting\Parsers\InternetMessageFormatHeaderParser.cs</Link>
114-
</Compile>
115-
<Compile Include="..\System.Net.Http.Formatting\Formatting\Parsers\MimeMultipartBodyPartParser.cs">
116-
<Link>Formatting\Parsers\MimeMultipartBodyPartParser.cs</Link>
117-
</Compile>
118-
<Compile Include="..\System.Net.Http.Formatting\Formatting\Parsers\MimeMultipartParser.cs">
119-
<Link>Formatting\Parsers\MimeMultipartParser.cs</Link>
120-
</Compile>
121-
<Compile Include="..\System.Net.Http.Formatting\Formatting\Parsers\ParserState.cs">
122-
<Link>Formatting\Parsers\ParserState.cs</Link>
123-
</Compile>
124-
<Compile Include="..\System.Net.Http.Formatting\Formatting\StringComparisonHelper.cs">
125-
<Link>Formatting\StringComparisonHelper.cs</Link>
126-
</Compile>
127-
<Compile Include="..\System.Net.Http.Formatting\Formatting\XmlMediaTypeFormatter.cs">
128-
<Link>Formatting\XmlMediaTypeFormatter.cs</Link>
129-
</Compile>
130-
<Compile Include="..\System.Net.Http.Formatting\HttpContentFormDataExtensions.cs">
131-
<Link>HttpContentFormDataExtensions.cs</Link>
132-
</Compile>
133-
<Compile Include="..\System.Net.Http.Formatting\Internal\HttpValueCollection.cs">
134-
<Link>Internal\HttpValueCollection.cs</Link>
135-
</Compile>
136-
<Compile Include="..\System.Net.Http.Formatting\UriExtensions.cs">
137-
<Link>UriExtensions.cs</Link>
138-
</Compile>
139-
<Compile Include="..\System.Net.Http.Formatting.NetCore\GlobalSuppressions.cs">
140-
<Link>GlobalSuppressions.cs</Link>
141-
</Compile>
142-
<Compile Include="..\System.Net.Http.Formatting\Handlers\HttpProgressEventArgs.cs">
143-
<Link>Handlers\HttpProgressEventArgs.cs</Link>
144-
</Compile>
145-
<Compile Include="..\System.Net.Http.Formatting\Handlers\ProgressContent.cs">
146-
<Link>Handlers\ProgressContent.cs</Link>
147-
</Compile>
148-
<Compile Include="..\System.Net.Http.Formatting\Handlers\ProgressMessageHandler.cs">
149-
<Link>Handlers\ProgressMessageHandler.cs</Link>
150-
</Compile>
151-
<Compile Include="..\System.Net.Http.Formatting\Handlers\ProgressStream.cs">
152-
<Link>Handlers\ProgressStream.cs</Link>
153-
</Compile>
154-
<Compile Include="..\System.Net.Http.Formatting\HttpClientExtensions.cs">
155-
<Link>HttpClientExtensions.cs</Link>
156-
</Compile>
157-
<Compile Include="..\System.Net.Http.Formatting\HttpClientFactory.cs">
158-
<Link>HttpClientFactory.cs</Link>
159-
</Compile>
160-
<Compile Include="..\System.Net.Http.Formatting\HttpContentExtensions.cs">
161-
<Link>HttpContentExtensions.cs</Link>
162-
</Compile>
163-
<Compile Include="..\System.Net.Http.Formatting\HttpContentMessageExtensions.cs">
164-
<Link>HttpContentMessageExtensions.cs</Link>
165-
</Compile>
166-
<Compile Include="..\System.Net.Http.Formatting\HttpContentMultipartExtensions.cs">
167-
<Link>HttpContentMultipartExtensions.cs</Link>
168-
</Compile>
169-
<Compile Include="..\System.Net.Http.Formatting\HttpHeaderExtensions.cs">
170-
<Link>HttpHeaderExtensions.cs</Link>
171-
</Compile>
172-
<Compile Include="..\System.Net.Http.Formatting\HttpMessageContent.cs">
173-
<Link>HttpMessageContent.cs</Link>
174-
</Compile>
175-
<Compile Include="..\System.Net.Http.Formatting\HttpUnsortedHeaders.cs">
176-
<Link>HttpUnsortedHeaders.cs</Link>
177-
</Compile>
178-
<Compile Include="..\System.Net.Http.Formatting\HttpUnsortedRequest.cs">
179-
<Link>HttpUnsortedRequest.cs</Link>
180-
</Compile>
181-
<Compile Include="..\System.Net.Http.Formatting\HttpUnsortedResponse.cs">
182-
<Link>HttpUnsortedResponse.cs</Link>
183-
</Compile>
184-
<Compile Include="..\System.Net.Http.Formatting\Internal\AsyncResult.cs">
185-
<Link>Internal\AsyncResult.cs</Link>
186-
</Compile>
187-
<Compile Include="..\System.Net.Http.Formatting\Internal\DelegatingStream.cs">
188-
<Link>Internal\DelegatingStream.cs</Link>
189-
</Compile>
190-
<Compile Include="..\System.Net.Http.Formatting\Internal\ReadOnlyStreamWithEncodingPreamble.cs">
191-
<Link>Internal\ReadOnlyStreamWithEncodingPreamble.cs</Link>
192-
</Compile>
193-
<Compile Include="..\System.Net.Http.Formatting\Internal\TypeExtensions.cs">
194-
<Link>Internal\TypeExtensions.cs</Link>
195-
</Compile>
196-
<Compile Include="..\System.Net.Http.Formatting\MimeBodyPart.cs">
197-
<Link>MimeBodyPart.cs</Link>
198-
</Compile>
199-
<Compile Include="..\System.Net.Http.Formatting\MultipartFileData.cs">
200-
<Link>MultipartFileData.cs</Link>
201-
</Compile>
202-
<Compile Include="..\System.Net.Http.Formatting\MultipartMemoryStreamProvider.cs">
203-
<Link>MultipartMemoryStreamProvider.cs</Link>
204-
</Compile>
205-
<Compile Include="..\System.Net.Http.Formatting\MultipartRelatedStreamProvider.cs">
206-
<Link>MultipartRelatedStreamProvider.cs</Link>
207-
</Compile>
208-
<Compile Include="..\System.Net.Http.Formatting\MultipartStreamProvider.cs">
209-
<Link>MultipartStreamProvider.cs</Link>
210-
</Compile>
211-
<Compile Include="..\System.Net.Http.Formatting\ObjectContent.cs">
212-
<Link>ObjectContent.cs</Link>
213-
</Compile>
214-
<Compile Include="..\System.Net.Http.Formatting\ObjectContentOfT.cs">
215-
<Link>ObjectContentOfT.cs</Link>
216-
</Compile>
217-
<Compile Include="..\System.Net.Http.Formatting\PushStreamContent.cs">
218-
<Link>PushStreamContent.cs</Link>
219-
</Compile>
220-
<Compile Include="..\System.Net.Http.Formatting\Properties\AssemblyInfo.cs">
221-
<Link>Properties\AssemblyInfo.cs</Link>
222-
</Compile>
223-
<Compile Include="..\System.Net.Http.Formatting\Properties\Resources.Designer.cs">
224-
<Link>Properties\Resources.Designer.cs</Link>
225-
<AutoGen>True</AutoGen>
226-
<DesignTime>True</DesignTime>
227-
<DependentUpon>Resources.resx</DependentUpon>
228-
</Compile>
229-
<Compile Include="..\System.Net.Http.Formatting\UnsupportedMediaTypeException.cs">
230-
<Link>UnsupportedMediaTypeException.cs</Link>
231-
</Compile>
232-
<Compile Include="..\System.Net.Http.Formatting.NetCore\Internal\ConcurrentDictionary.cs">
233-
<Link>Internal\ConcurrentDictionary.cs</Link>
234-
</Compile>
235-
<Compile Include="..\System.Net.Http.Formatting.NetCore\MediaTypeHeaderValueExtensions.cs">
236-
<Link>MediaTypeHeaderValueExtensions.cs</Link>
43+
44+
<Compile Include="..\System.Net.Http.Formatting\**\*.cs">
45+
<Link>%(RecursiveDir)\%(Filename).cs</Link>
23746
</Compile>
23847
</ItemGroup>
23948
<ItemGroup>
@@ -243,15 +52,18 @@
24352
<DesignTime>True</DesignTime>
24453
<DependentUpon>CommonWebApiResources.resx</DependentUpon>
24554
</Compile>
246-
</ItemGroup>
247-
<ItemGroup>
24855
<EmbeddedResource Include="..\Common\CommonWebApiResources.resx">
24956
<Link>Properties\CommonWebApiResources.resx</Link>
25057
<Generator>ResXFileCodeGenerator</Generator>
25158
<LastGenOutput>CommonWebApiResources.Designer.cs</LastGenOutput>
25259
</EmbeddedResource>
25360
</ItemGroup>
25461
<ItemGroup>
62+
<Compile Update="..\System.Net.Http.Formatting\Properties\Resources.Designer.cs">
63+
<AutoGen>True</AutoGen>
64+
<DesignTime>True</DesignTime>
65+
<DependentUpon>Resources.resx</DependentUpon>
66+
</Compile>
25567
<EmbeddedResource Include="..\System.Net.Http.Formatting\Properties\Resources.resx">
25668
<Link>Properties\Resources.resx</Link>
25769
<Generator>ResXFileCodeGenerator</Generator>

src/System.Net.Http.Formatting/Formatting/BsonMediaTypeFormatter.cs

Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -11,7 +11,12 @@
1111
using System.Threading.Tasks;
1212
using System.Web.Http;
1313
using Newtonsoft.Json;
14+
#if NEWTONSOFTJSON10
15+
using BsonReader = Newtonsoft.Json.Bson.BsonDataReader;
16+
using BsonWriter = Newtonsoft.Json.Bson.BsonDataWriter;
17+
#else
1418
using Newtonsoft.Json.Bson;
19+
#endif
1520

1621
namespace System.Net.Http.Formatting
1722
{

src/System.Net.Http.Formatting/Properties/AssemblyInfo.cs

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -3,7 +3,7 @@
33

44
using System.Reflection;
55
using System.Runtime.CompilerServices;
6-
#if !NETFX_CORE || NETSTANDARD1_1
6+
#if !NETFX_CORE
77
using System.Runtime.InteropServices;
88
#endif
99

@@ -14,11 +14,11 @@
1414
[assembly: AssemblyTitle("System.Net.Http.Formatting")]
1515
[assembly: AssemblyDescription("")]
1616

17-
#if !NETFX_CORE || NETSTANDARD1_1 // GuidAttibute is not supported in portable libraries but is in .NET Standard.
17+
#if !NETFX_CORE // GuidAttibute is not supported in portable libraries.
1818
[assembly: Guid("7fa1ae84-36e2-46b6-812c-c985a8e65e9a")]
1919
#endif
2020

21-
#if NETSTANDARD1_1
21+
#if NETSTANDARD2_0
2222
[assembly: InternalsVisibleTo("System.Net.Http.Formatting.NetStandard.Test, PublicKey=0024000004800000940000000602000000240000525341310004000001000100b5fc90e7027f67871e773a8fde8938c81dd402ba65b9201d60593e96c492651e889cc13f1415ebb53fac1131ae0bd333c5ee6021672d9718ea31a8aebd0da0072f25d87dba6fc90ffd598ed4da35e44c398c454307e8e33b8426143daec9f596836f97c8f74750e5975c64e2189f45def46b2a2b1247adc3652bf5c308055da9")]
2323
#elif NETFX_CORE
2424
[assembly: InternalsVisibleTo("System.Net.Http.Formatting.NetCore.Test, PublicKey=0024000004800000940000000602000000240000525341310004000001000100b5fc90e7027f67871e773a8fde8938c81dd402ba65b9201d60593e96c492651e889cc13f1415ebb53fac1131ae0bd333c5ee6021672d9718ea31a8aebd0da0072f25d87dba6fc90ffd598ed4da35e44c398c454307e8e33b8426143daec9f596836f97c8f74750e5975c64e2189f45def46b2a2b1247adc3652bf5c308055da9")]

test/Directory.Build.props

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -4,6 +4,6 @@
44
<PropertyGroup>
55
<IsPackable>false</IsPackable>
66
<IsTestProject>true</IsTestProject>
7-
<TargetFrameworkVersion>v4.5.2</TargetFrameworkVersion>
7+
<TargetFrameworkVersion Condition="'$(MSBuildProjectName)' != 'System.Net.Http.Formatting.NetStandard.Test'">v4.5.2</TargetFrameworkVersion>
88
</PropertyGroup>
99
</Project>

0 commit comments

Comments
 (0)