Skip to content
This repository was archived by the owner on Jun 21, 2023. It is now read-only.

Commit fec41ac

Browse files
authored
Merge pull request #1760 from github/fixes/1759-trip-project-references
Trim project references to GitHub.VisualStudio
2 parents 24b03a3 + 6366921 commit fec41ac

File tree

10 files changed

+15
-89
lines changed

10 files changed

+15
-89
lines changed

test/GitHub.Api.UnitTests/GitHub.Api.UnitTests.csproj

Lines changed: 0 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -113,10 +113,6 @@
113113
<Project>{7f5ed78b-74a3-4406-a299-70cfb5885b8b}</Project>
114114
<Name>GitHub.InlineReviews</Name>
115115
</ProjectReference>
116-
<ProjectReference Include="..\..\src\GitHub.VisualStudio\GitHub.VisualStudio.csproj">
117-
<Project>{11569514-5ae5-4b5b-92a2-f10b0967de5f}</Project>
118-
<Name>GitHub.VisualStudio</Name>
119-
</ProjectReference>
120116
</ItemGroup>
121117
<ItemGroup>
122118
<None Include="packages.config">

test/GitHub.Api.UnitTests/SimpleApiClientFactoryTests.cs

Lines changed: 11 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -3,7 +3,7 @@
33
using GitHub.Api;
44
using GitHub.Primitives;
55
using GitHub.Services;
6-
using GitHub.VisualStudio;
6+
using GitHub.Models;
77
using NSubstitute;
88
using Octokit;
99
using NUnit.Framework;
@@ -16,7 +16,7 @@ public class TheCreateMethod
1616
public async Task CreatesNewInstanceOfSimpleApiClient()
1717
{
1818
const string url = "https://github.com/github/CreatesNewInstanceOfSimpleApiClient";
19-
var program = new Program();
19+
var program = CreateProgram();
2020
var keychain = Substitute.For<IKeychain>();
2121
var enterpriseProbe = Substitute.For<IEnterpriseProbe>();
2222
var wikiProbe = Substitute.For<IWikiProbe>();
@@ -30,7 +30,7 @@ public async Task CreatesNewInstanceOfSimpleApiClient()
3030

3131
Assert.That(url, Is.EqualTo(client.OriginalUrl));
3232
Assert.That(HostAddress.GitHubDotComHostAddress, Is.EqualTo(client.HostAddress));
33-
Assert.That(client,Is.SameAs(await factory.Create(url))); // Tests caching.
33+
Assert.That(client, Is.SameAs(await factory.Create(url))); // Tests caching.
3434
}
3535
}
3636

@@ -40,7 +40,7 @@ public class TheClearFromCacheMethod
4040
public async Task RemovesClientFromCache()
4141
{
4242
const string url = "https://github.com/github/RemovesClientFromCache";
43-
var program = new Program();
43+
var program = CreateProgram();
4444
var enterpriseProbe = Substitute.For<IEnterpriseProbe>();
4545
var wikiProbe = Substitute.For<IWikiProbe>();
4646
var factory = new SimpleApiClientFactory(
@@ -56,6 +56,13 @@ public async Task RemovesClientFromCache()
5656
}
5757
}
5858

59+
static IProgram CreateProgram()
60+
{
61+
var program = Substitute.For<IProgram>();
62+
program.ProductHeader.Returns(new ProductHeaderValue("ProductName"));
63+
return program;
64+
}
65+
5966
static IKeychain CreateKeychain()
6067
{
6168
var result = Substitute.For<IKeychain>();

test/GitHub.Exports.Reactive.UnitTests/GitHub.Exports.Reactive.UnitTests.csproj

Lines changed: 0 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -203,14 +203,6 @@
203203
<Project>{9AEA02DB-02B5-409C-B0CA-115D05331A6B}</Project>
204204
<Name>GitHub.Exports</Name>
205205
</ProjectReference>
206-
<ProjectReference Include="..\..\src\GitHub.InlineReviews\GitHub.InlineReviews.csproj">
207-
<Project>{7f5ed78b-74a3-4406-a299-70cfb5885b8b}</Project>
208-
<Name>GitHub.InlineReviews</Name>
209-
</ProjectReference>
210-
<ProjectReference Include="..\..\src\GitHub.VisualStudio\GitHub.VisualStudio.csproj">
211-
<Project>{11569514-5ae5-4b5b-92a2-f10b0967de5f}</Project>
212-
<Name>GitHub.VisualStudio</Name>
213-
</ProjectReference>
214206
</ItemGroup>
215207
<Import Project="$(VSToolsPath)\TeamTest\Microsoft.TestTools.targets" Condition="Exists('$(VSToolsPath)\TeamTest\Microsoft.TestTools.targets')" />
216208
<Import Project="$(MSBuildToolsPath)\Microsoft.CSharp.targets" />

test/GitHub.Exports.UnitTests/GitHub.Exports.UnitTests.csproj

Lines changed: 0 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -188,10 +188,6 @@
188188
<Project>{252ce1c2-027a-4445-a3c2-e4d6c80a935a}</Project>
189189
<Name>Splat-Net45</Name>
190190
</ProjectReference>
191-
<ProjectReference Include="..\..\src\GitHub.Api\GitHub.Api.csproj">
192-
<Project>{b389adaf-62cc-486e-85b4-2d8b078df763}</Project>
193-
<Name>GitHub.Api</Name>
194-
</ProjectReference>
195191
<ProjectReference Include="..\..\src\GitHub.App\GitHub.App.csproj">
196192
<Project>{1A1DA411-8D1F-4578-80A6-04576BEA2DC5}</Project>
197193
<Name>GitHub.App</Name>

test/GitHub.Extensions.UnitTests/GitHub.Extensions.UnitTests.csproj

Lines changed: 0 additions & 12 deletions
Original file line numberDiff line numberDiff line change
@@ -97,22 +97,10 @@
9797
<Project>{252ce1c2-027a-4445-a3c2-e4d6c80a935a}</Project>
9898
<Name>Splat-Net45</Name>
9999
</ProjectReference>
100-
<ProjectReference Include="..\..\src\GitHub.App\GitHub.App.csproj">
101-
<Project>{1A1DA411-8D1F-4578-80A6-04576BEA2DC5}</Project>
102-
<Name>GitHub.App</Name>
103-
</ProjectReference>
104100
<ProjectReference Include="..\..\src\GitHub.Extensions\GitHub.Extensions.csproj">
105101
<Project>{6afe2e2d-6db0-4430-a2ea-f5f5388d2f78}</Project>
106102
<Name>GitHub.Extensions</Name>
107103
</ProjectReference>
108-
<ProjectReference Include="..\..\src\GitHub.InlineReviews\GitHub.InlineReviews.csproj">
109-
<Project>{7f5ed78b-74a3-4406-a299-70cfb5885b8b}</Project>
110-
<Name>GitHub.InlineReviews</Name>
111-
</ProjectReference>
112-
<ProjectReference Include="..\..\src\GitHub.VisualStudio\GitHub.VisualStudio.csproj">
113-
<Project>{11569514-5ae5-4b5b-92a2-f10b0967de5f}</Project>
114-
<Name>GitHub.VisualStudio</Name>
115-
</ProjectReference>
116104
</ItemGroup>
117105
<ItemGroup>
118106
<None Include="packages.config">

test/GitHub.Primitives.UnitTests/GitHub.Primitives.UnitTests.csproj

Lines changed: 0 additions & 34 deletions
Original file line numberDiff line numberDiff line change
@@ -41,40 +41,14 @@
4141
<HintPath>..\..\packages\LibGit2Sharp.0.23.1\lib\net40\LibGit2Sharp.dll</HintPath>
4242
<Private>True</Private>
4343
</Reference>
44-
<Reference Include="Microsoft.Reactive.Testing, Version=2.2.5.0, Culture=neutral, PublicKeyToken=62aa029873c516b4, processorArchitecture=MSIL">
45-
<HintPath>..\..\packages\Rx-Testing.2.2.5-custom\lib\net45\Microsoft.Reactive.Testing.dll</HintPath>
46-
<Private>True</Private>
47-
</Reference>
4844
<Reference Include="nunit.framework, Version=3.9.0.0, Culture=neutral, PublicKeyToken=2638cd05610744eb, processorArchitecture=MSIL">
4945
<HintPath>..\..\packages\NUnit.3.9.0\lib\net45\nunit.framework.dll</HintPath>
5046
</Reference>
51-
<Reference Include="PresentationCore" />
5247
<Reference Include="System" />
5348
<Reference Include="System.Core" />
5449
<Reference Include="System.IO.Compression.FileSystem" />
55-
<Reference Include="System.Reactive.Core, Version=2.2.5.0, Culture=neutral, PublicKeyToken=62aa029873c516b4, processorArchitecture=MSIL">
56-
<HintPath>..\..\packages\Rx-Core.2.2.5-custom\lib\net45\System.Reactive.Core.dll</HintPath>
57-
<Private>True</Private>
58-
</Reference>
59-
<Reference Include="System.Reactive.Interfaces, Version=2.2.5.0, Culture=neutral, PublicKeyToken=62aa029873c516b4, processorArchitecture=MSIL">
60-
<HintPath>..\..\packages\Rx-Interfaces.2.2.5-custom\lib\net45\System.Reactive.Interfaces.dll</HintPath>
61-
<Private>True</Private>
62-
</Reference>
63-
<Reference Include="System.Reactive.Linq, Version=2.2.5.0, Culture=neutral, PublicKeyToken=62aa029873c516b4, processorArchitecture=MSIL">
64-
<HintPath>..\..\packages\Rx-Linq.2.2.5-custom\lib\net45\System.Reactive.Linq.dll</HintPath>
65-
<Private>True</Private>
66-
</Reference>
67-
<Reference Include="System.Reactive.PlatformServices, Version=2.2.5.0, Culture=neutral, PublicKeyToken=62aa029873c516b4, processorArchitecture=MSIL">
68-
<HintPath>..\..\packages\Rx-PlatformServices.2.2.5-custom\lib\net45\System.Reactive.PlatformServices.dll</HintPath>
69-
<Private>True</Private>
70-
</Reference>
71-
<Reference Include="System.Reactive.Windows.Threading, Version=2.2.5.0, Culture=neutral, PublicKeyToken=62aa029873c516b4, processorArchitecture=MSIL">
72-
<HintPath>..\..\packages\Rx-XAML.2.2.5-custom\lib\net45\System.Reactive.Windows.Threading.dll</HintPath>
73-
<Private>True</Private>
74-
</Reference>
7550
<Reference Include="System.Xaml" />
7651
<Reference Include="System.Xml" />
77-
<Reference Include="WindowsBase" />
7852
</ItemGroup>
7953
<ItemGroup>
8054
<Compile Include="..\Helpers\SplatModeDetectorSetUp.cs">
@@ -97,14 +71,6 @@
9771
<Project>{9AEA02DB-02B5-409C-B0CA-115D05331A6B}</Project>
9872
<Name>GitHub.Exports</Name>
9973
</ProjectReference>
100-
<ProjectReference Include="..\..\src\GitHub.InlineReviews\GitHub.InlineReviews.csproj">
101-
<Project>{7f5ed78b-74a3-4406-a299-70cfb5885b8b}</Project>
102-
<Name>GitHub.InlineReviews</Name>
103-
</ProjectReference>
104-
<ProjectReference Include="..\..\src\GitHub.VisualStudio\GitHub.VisualStudio.csproj">
105-
<Project>{11569514-5ae5-4b5b-92a2-f10b0967de5f}</Project>
106-
<Name>GitHub.VisualStudio</Name>
107-
</ProjectReference>
10874
</ItemGroup>
10975
<ItemGroup>
11076
<None Include="packages.config">

test/GitHub.Primitives.UnitTests/packages.config

Lines changed: 0 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -3,11 +3,4 @@
33
<package id="LibGit2Sharp" version="0.23.1" targetFramework="net461" />
44
<package id="LibGit2Sharp.NativeBinaries" version="1.0.164" targetFramework="net461" />
55
<package id="NUnit" version="3.9.0" targetFramework="net461" />
6-
<package id="Rx-Core" version="2.2.5-custom" targetFramework="net45" />
7-
<package id="Rx-Interfaces" version="2.2.5-custom" targetFramework="net45" />
8-
<package id="Rx-Linq" version="2.2.5-custom" targetFramework="net45" />
9-
<package id="Rx-Main" version="2.2.5-custom" targetFramework="net45" />
10-
<package id="Rx-PlatformServices" version="2.2.5-custom" targetFramework="net45" />
11-
<package id="Rx-Testing" version="2.2.5-custom" targetFramework="net45" />
12-
<package id="Rx-XAML" version="2.2.5-custom" targetFramework="net45" />
136
</packages>

test/GitHub.TeamFoundation.UnitTests/GitHub.TeamFoundation.UnitTests.csproj

Lines changed: 0 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -191,18 +191,10 @@
191191
<Project>{9AEA02DB-02B5-409C-B0CA-115D05331A6B}</Project>
192192
<Name>GitHub.Exports</Name>
193193
</ProjectReference>
194-
<ProjectReference Include="..\..\src\GitHub.InlineReviews\GitHub.InlineReviews.csproj">
195-
<Project>{7f5ed78b-74a3-4406-a299-70cfb5885b8b}</Project>
196-
<Name>GitHub.InlineReviews</Name>
197-
</ProjectReference>
198194
<ProjectReference Include="..\..\src\GitHub.TeamFoundation.14\GitHub.TeamFoundation.14.csproj">
199195
<Project>{161DBF01-1DBF-4B00-8551-C5C00F26720D}</Project>
200196
<Name>GitHub.TeamFoundation.14</Name>
201197
</ProjectReference>
202-
<ProjectReference Include="..\..\src\GitHub.VisualStudio\GitHub.VisualStudio.csproj">
203-
<Project>{11569514-5ae5-4b5b-92a2-f10b0967de5f}</Project>
204-
<Name>GitHub.VisualStudio</Name>
205-
</ProjectReference>
206198
</ItemGroup>
207199
<ItemGroup>
208200
<None Include="packages.config">

test/GitHub.UI.UnitTests/GitHub.UI.UnitTests.csproj

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -77,6 +77,10 @@
7777
</None>
7878
</ItemGroup>
7979
<ItemGroup>
80+
<ProjectReference Include="..\..\src\GitHub.VisualStudio.UI\GitHub.VisualStudio.UI.csproj">
81+
<Project>{d1dfbb0c-b570-4302-8f1e-2e3a19c41961}</Project>
82+
<Name>GitHub.VisualStudio.UI</Name>
83+
</ProjectReference>
8084
<ProjectReference Include="..\..\submodules\octokit.net\Octokit\Octokit.csproj">
8185
<Project>{08dd4305-7787-4823-a53f-4d0f725a07f3}</Project>
8286
<Name>Octokit</Name>
@@ -93,10 +97,6 @@
9397
<Project>{346384dd-2445-4a28-af22-b45f3957bd89}</Project>
9498
<Name>GitHub.UI</Name>
9599
</ProjectReference>
96-
<ProjectReference Include="..\..\src\GitHub.VisualStudio\GitHub.VisualStudio.csproj">
97-
<Project>{11569514-5ae5-4b5b-92a2-f10b0967de5f}</Project>
98-
<Name>GitHub.VisualStudio</Name>
99-
</ProjectReference>
100100
</ItemGroup>
101101
<ItemGroup>
102102
<Page Include="Helpers\SharedDictionary.xaml">

test/GitHub.VisualStudio.UnitTests/GitHub.VisualStudio.UnitTests.csproj

Lines changed: 0 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -243,10 +243,6 @@
243243
<Project>{9AEA02DB-02B5-409C-B0CA-115D05331A6B}</Project>
244244
<Name>GitHub.Exports</Name>
245245
</ProjectReference>
246-
<ProjectReference Include="..\..\src\GitHub.InlineReviews\GitHub.InlineReviews.csproj">
247-
<Project>{7f5ed78b-74a3-4406-a299-70cfb5885b8b}</Project>
248-
<Name>GitHub.InlineReviews</Name>
249-
</ProjectReference>
250246
<ProjectReference Include="..\..\src\GitHub.Extensions\GitHub.Extensions.csproj">
251247
<Project>{6afe2e2d-6db0-4430-a2ea-f5f5388d2f78}</Project>
252248
<Name>GitHub.Extensions</Name>

0 commit comments

Comments
 (0)