mirror of
https://github.com/microsoft/PowerToys.git
synced 2025-12-16 11:48:06 +01:00
Adjusting interop tests for 5295 (#5296)
Co-authored-by: Clint Rutkas <crutkas@microsoft.com>
This commit is contained in:
@@ -239,7 +239,7 @@ Project("{8BC9CEB8-8B4A-11D0-8D11-00A0C91BC942}") = "interop", "src\common\inter
|
||||
EndProject
|
||||
Project("{8BC9CEB8-8B4A-11D0-8D11-00A0C91BC942}") = "common-md-flag", "src\common\common-md-flag\common-md-flag.vcxproj", "{985B3F2F-CEED-4C0A-A249-69257E719145}"
|
||||
EndProject
|
||||
Project("{FAE04EC0-301F-11D3-BF4B-00C04F79EFBC}") = "interop-tests", "src\common\interop-tests\interop-tests.csproj", "{437AD818-3F1F-4CA5-A79B-25233A157026}"
|
||||
Project("{FAE04EC0-301F-11D3-BF4B-00C04F79EFBC}") = "Microsoft.Interop.Tests", "src\common\interop-tests\Microsoft.Interop.Tests.csproj", "{437AD818-3F1F-4CA5-A79B-25233A157026}"
|
||||
EndProject
|
||||
Project("{9A19103F-16F7-4668-BE54-9A1E7A4F7556}") = "Microsoft.Plugin.Folder", "src\modules\launcher\Plugins\Microsoft.Plugin.Folder\Microsoft.Plugin.Folder.csproj", "{787B8AA6-CA93-4C84-96FE-DF31110AD1C4}"
|
||||
EndProject
|
||||
|
||||
@@ -1,25 +1,25 @@
|
||||
using System;
|
||||
using Microsoft.VisualStudio.TestTools.UnitTesting;
|
||||
using System.IO.Pipes;
|
||||
using interop;
|
||||
using System.IO;
|
||||
using System.Threading;
|
||||
using System.Text;
|
||||
// Copyright (c) Microsoft Corporation
|
||||
// The Microsoft Corporation licenses this file to you under the MIT license.
|
||||
// See the LICENSE file in the project root for more information.
|
||||
|
||||
namespace interop_tests
|
||||
using System.Threading;
|
||||
using interop;
|
||||
using Microsoft.VisualStudio.TestTools.UnitTesting;
|
||||
|
||||
namespace Microsoft.Interop.Tests
|
||||
{
|
||||
[TestClass]
|
||||
public class UnitTest1
|
||||
public class InteropTests
|
||||
{
|
||||
private string SERVER_SIDE = "\\\\.\\pipe\\serverside";
|
||||
private string CLIENT_SIDE = "\\\\.\\pipe\\clientside";
|
||||
private const string ServerSidePipe = "\\\\.\\pipe\\serverside";
|
||||
private const string ClientSidePipe = "\\\\.\\pipe\\clientside";
|
||||
|
||||
private TwoWayPipeMessageIPCManaged clientPipe;
|
||||
|
||||
[TestInitialize]
|
||||
public void Initialize()
|
||||
{
|
||||
clientPipe = new TwoWayPipeMessageIPCManaged(CLIENT_SIDE, SERVER_SIDE, null);
|
||||
clientPipe = new TwoWayPipeMessageIPCManaged(ClientSidePipe, ServerSidePipe, null);
|
||||
}
|
||||
|
||||
[TestCleanup]
|
||||
@@ -35,8 +35,8 @@ namespace interop_tests
|
||||
var reset = new AutoResetEvent(false);
|
||||
|
||||
var serverPipe = new TwoWayPipeMessageIPCManaged(
|
||||
SERVER_SIDE,
|
||||
CLIENT_SIDE,
|
||||
ServerSidePipe,
|
||||
ClientSidePipe,
|
||||
(string msg) =>
|
||||
{
|
||||
Assert.AreEqual(testString, msg);
|
||||
@@ -50,6 +50,5 @@ namespace interop_tests
|
||||
|
||||
serverPipe.End();
|
||||
}
|
||||
|
||||
}
|
||||
}
|
||||
@@ -41,8 +41,8 @@
|
||||
<ProjectGuid>{437AD818-3F1F-4CA5-A79B-25233A157026}</ProjectGuid>
|
||||
<OutputType>Library</OutputType>
|
||||
<AppDesignerFolder>Properties</AppDesignerFolder>
|
||||
<RootNamespace>interop_tests</RootNamespace>
|
||||
<AssemblyName>interop-tests</AssemblyName>
|
||||
<RootNamespace>Microsoft.Interop.Tests</RootNamespace>
|
||||
<AssemblyName>Microsoft.Interop.Tests</AssemblyName>
|
||||
<TargetFrameworkVersion>v4.7.2</TargetFrameworkVersion>
|
||||
<FileAlignment>512</FileAlignment>
|
||||
<ProjectTypeGuids>{3AC096D0-A1C2-E12C-1390-A8335801FDAB};{FAE04EC0-301F-11D3-BF4B-00C04F79EFBC}</ProjectTypeGuids>
|
||||
@@ -85,14 +85,27 @@
|
||||
<Reference Include="System.Core" />
|
||||
</ItemGroup>
|
||||
<ItemGroup>
|
||||
<Compile Include="UnitTest1.cs" />
|
||||
<Compile Include="..\..\codeAnalysis\GlobalSuppressions.cs">
|
||||
<Link>GlobalSuppressions.cs</Link>
|
||||
</Compile>
|
||||
<Compile Include="InteropTests.cs" />
|
||||
<Compile Include="Generated Files\AssemblyInfo.cs">
|
||||
<SubType>Code</SubType>
|
||||
</Compile>
|
||||
</ItemGroup>
|
||||
<ItemGroup>
|
||||
<AdditionalFiles Include="..\..\codeAnalysis\StyleCop.json">
|
||||
<Link>StyleCop.json</Link>
|
||||
</AdditionalFiles>
|
||||
<None Include="packages.config" />
|
||||
</ItemGroup>
|
||||
<ItemGroup>
|
||||
<PackageReference Include="StyleCop.Analyzers">
|
||||
<Version>1.1.118</Version>
|
||||
<IncludeAssets>runtime; build; native; contentfiles; analyzers; buildtransitive</IncludeAssets>
|
||||
<PrivateAssets>all</PrivateAssets>
|
||||
</PackageReference>
|
||||
</ItemGroup>
|
||||
<ItemGroup>
|
||||
<ProjectReference Include="..\interop\interop.vcxproj">
|
||||
<Project>{f055103b-f80b-4d0c-bf48-057c55620033}</Project>
|
||||
Reference in New Issue
Block a user