This commit is contained in:
Carlos Castro 2019-10-16 11:16:42 -07:00
Родитель 48f94df79b e7e3541ca2
Коммит 1329624d83
4 изменённых файлов: 12 добавлений и 23 удалений

Просмотреть файл

@ -146,12 +146,6 @@ Project("{9A19103F-16F7-4668-BE54-9A1E7A4F7556}") = "Microsoft.Bot.Builder.Dialo
EndProject
Project("{9A19103F-16F7-4668-BE54-9A1E7A4F7556}") = "Microsoft.Bot.Streaming", "libraries\Microsoft.Bot.Streaming\Microsoft.Bot.Streaming.csproj", "{4C82FD14-418F-43E4-AC59-3D926B55CEA3}"
EndProject
Project("{9A19103F-16F7-4668-BE54-9A1E7A4F7556}") = "Microsoft.Bot.Builder.Streaming.Tests", "tests\Microsoft.Bot.Builder.Streaming.Tests\Microsoft.Bot.Builder.Streaming.Tests.csproj", "{77BD3C7F-34D9-47FC-AFC0-6D92A2081770}"
ProjectSection(ProjectDependencies) = postProject
{ADA8AB8B-2066-4193-B8F7-985669B23E00} = {ADA8AB8B-2066-4193-B8F7-985669B23E00}
{053BD8B8-B5C1-4C45-81D4-C9BA8D5B3CE2} = {053BD8B8-B5C1-4C45-81D4-C9BA8D5B3CE2}
EndProjectSection
EndProject
Project("{9A19103F-16F7-4668-BE54-9A1E7A4F7556}") = "Microsoft.Bot.Streaming.Tests", "tests\Microsoft.Bot.Streaming.Tests\Microsoft.Bot.Streaming.Tests.csproj", "{D243AC2D-7823-4177-9D8A-23FDFDA274D2}"
ProjectSection(ProjectDependencies) = postProject
{ADA8AB8B-2066-4193-B8F7-985669B23E00} = {ADA8AB8B-2066-4193-B8F7-985669B23E00}
@ -597,14 +591,6 @@ Global
{4C82FD14-418F-43E4-AC59-3D926B55CEA3}.Release|Any CPU.Build.0 = Release|Any CPU
{4C82FD14-418F-43E4-AC59-3D926B55CEA3}.Release-Windows|Any CPU.ActiveCfg = Release|Any CPU
{4C82FD14-418F-43E4-AC59-3D926B55CEA3}.Release-Windows|Any CPU.Build.0 = Release|Any CPU
{77BD3C7F-34D9-47FC-AFC0-6D92A2081770}.Debug|Any CPU.ActiveCfg = Debug|Any CPU
{77BD3C7F-34D9-47FC-AFC0-6D92A2081770}.Debug|Any CPU.Build.0 = Debug|Any CPU
{77BD3C7F-34D9-47FC-AFC0-6D92A2081770}.Debug-Windows|Any CPU.ActiveCfg = Debug|Any CPU
{77BD3C7F-34D9-47FC-AFC0-6D92A2081770}.Debug-Windows|Any CPU.Build.0 = Debug|Any CPU
{77BD3C7F-34D9-47FC-AFC0-6D92A2081770}.Release|Any CPU.ActiveCfg = Release|Any CPU
{77BD3C7F-34D9-47FC-AFC0-6D92A2081770}.Release|Any CPU.Build.0 = Release|Any CPU
{77BD3C7F-34D9-47FC-AFC0-6D92A2081770}.Release-Windows|Any CPU.ActiveCfg = Release|Any CPU
{77BD3C7F-34D9-47FC-AFC0-6D92A2081770}.Release-Windows|Any CPU.Build.0 = Release|Any CPU
{D243AC2D-7823-4177-9D8A-23FDFDA274D2}.Debug|Any CPU.ActiveCfg = Debug|Any CPU
{D243AC2D-7823-4177-9D8A-23FDFDA274D2}.Debug|Any CPU.Build.0 = Debug|Any CPU
{D243AC2D-7823-4177-9D8A-23FDFDA274D2}.Debug-Windows|Any CPU.ActiveCfg = Debug|Any CPU
@ -678,7 +664,6 @@ Global
{6E39C647-902F-4CFF-A4E4-194B295E3AF4} = {E8CD434A-306F-41D9-B67D-BFFF3287354D}
{EFAA1D3D-3102-4307-A5DD-EAB4DB9B0386} = {AD743B78-D61F-4FBF-B620-FA83CE599A50}
{4C82FD14-418F-43E4-AC59-3D926B55CEA3} = {4269F3C3-6B42-419B-B64A-3E6DC0F1574A}
{77BD3C7F-34D9-47FC-AFC0-6D92A2081770} = {AD743B78-D61F-4FBF-B620-FA83CE599A50}
{D243AC2D-7823-4177-9D8A-23FDFDA274D2} = {AD743B78-D61F-4FBF-B620-FA83CE599A50}
EndGlobalSection
GlobalSection(ExtensibilityGlobals) = postSolution

Просмотреть файл

@ -6,6 +6,12 @@
<IsPackable>false</IsPackable>
</PropertyGroup>
<ItemGroup>
<Compile Remove="BuildReports\**" />
<EmbeddedResource Remove="BuildReports\**" />
<None Remove="BuildReports\**" />
</ItemGroup>
<ItemGroup>
<PackageReference Include="coverlet.msbuild" Version="2.7.0">
<PrivateAssets>all</PrivateAssets>
@ -30,9 +36,5 @@
<ProjectReference Include="..\..\libraries\Microsoft.Bot.Builder\Microsoft.Bot.Builder.csproj" />
<ProjectReference Include="..\Microsoft.Bot.Streaming.Tests\Microsoft.Bot.Streaming.Tests.csproj" />
</ItemGroup>
<ItemGroup>
<Folder Include="BuildReports\Coverage\" />
<Folder Include="BuildReports\UnitTests\" />
</ItemGroup>
</Project>

Просмотреть файл

@ -9,6 +9,7 @@ using System.Threading.Tasks;
using Microsoft.Bot.Builder.Integration.AspNet.Core;
using Microsoft.Bot.Builder.Streaming;
using Microsoft.Bot.Streaming.Transport.NamedPipes;
using Microsoft.Bot.Streaming.UnitTests.Mocks;
using Xunit;
namespace Microsoft.Bot.Streaming.UnitTests
@ -21,9 +22,9 @@ namespace Microsoft.Bot.Streaming.UnitTests
var pipeName = Guid.NewGuid().ToString();
var readStream = new NamedPipeServerStream(pipeName, PipeDirection.In, NamedPipeServerStream.MaxAllowedServerInstances, PipeTransmissionMode.Byte, PipeOptions.WriteThrough | PipeOptions.Asynchronous);
var writeStream = new NamedPipeClientStream(Guid.NewGuid().ToString(), pipeName, PipeDirection.Out, PipeOptions.WriteThrough | PipeOptions.Asynchronous);
new StreamingRequestHandler(new Microsoft.Bot.Streaming.UnitTests.Mocks.MockBot(), new BotFrameworkHttpAdapter(), pipeName);
var reader = new NamedPipeClient(pipeName);
var writer = new NamedPipeServer(pipeName, new StreamingRequestHandler(null, new BotFrameworkHttpAdapter(), pipeName));
var writer = new NamedPipeServer(pipeName, new StreamingRequestHandler(new MockBot(), new BotFrameworkHttpAdapter(), pipeName));
try
{

Просмотреть файл

@ -14,6 +14,7 @@ using Microsoft.Bot.Builder.Integration.AspNet.Core;
using Microsoft.Bot.Builder.Streaming;
using Microsoft.Bot.Streaming.Transport.NamedPipes;
using Microsoft.Bot.Streaming.Transport.WebSockets;
using Microsoft.Bot.Streaming.UnitTests.Mocks;
using Xunit;
namespace Microsoft.Bot.Streaming.UnitTests
@ -24,7 +25,7 @@ namespace Microsoft.Bot.Streaming.UnitTests
public async Task WebSocketServer_Connects()
{
var sock = new FauxSock();
var writer = new WebSocketServer(sock, new StreamingRequestHandler(null, new BotFrameworkHttpAdapter(), sock));
var writer = new WebSocketServer(sock, new StreamingRequestHandler(new MockBot(), new BotFrameworkHttpAdapter(), sock));
writer.StartAsync();
Assert.True(writer.IsConnected);
@ -34,7 +35,7 @@ namespace Microsoft.Bot.Streaming.UnitTests
public async Task WebSocketServer_BackAndForth()
{
var sock = new FauxSock();
var writer = new WebSocketServer(sock, new StreamingRequestHandler(null, new BotFrameworkHttpAdapter(), sock));
var writer = new WebSocketServer(sock, new StreamingRequestHandler(new MockBot(), new BotFrameworkHttpAdapter(), sock));
writer.StartAsync();
}