mirror of
https://github.com/pocoproject/poco.git
synced 2025-03-11 04:33:47 +01:00
Merge pull request #1105 from Kampbell/develop
NetSLL_Win: add missing WebSocketTestSuite
This commit is contained in:
commit
df61181582
@ -103,13 +103,13 @@ matrix:
|
|||||||
script:
|
script:
|
||||||
- export CC="arm-linux-gnueabi-gcc"
|
- export CC="arm-linux-gnueabi-gcc"
|
||||||
- export CXX="arm-linux-gnueabi-g++"
|
- export CXX="arm-linux-gnueabi-g++"
|
||||||
- mkdir cmake-build && cd cmake-build && cmake -DENABLE_NETSSL=OFF -DENABLE_CRYPTO=OFF -DENABLE_TESTS=ON .. && make -j2 && cd ..
|
- mkdir cmake-build && cd cmake-build && cmake -DENABLE_NETSSL=OFF -DENABLE_CRYPTO=OFF -DENABLE_TESTS=OFF .. && make -j2 && cd ..
|
||||||
|
|
||||||
- env: TEST_NAME="Linux arm-linux-gnueabihf-g++ (CMake)"
|
- env: TEST_NAME="Linux arm-linux-gnueabihf-g++ (CMake)"
|
||||||
script:
|
script:
|
||||||
- export CC="arm-linux-gnueabihf-gcc"
|
- export CC="arm-linux-gnueabihf-gcc"
|
||||||
- export CXX="arm-linux-gnueabihf-g++"
|
- export CXX="arm-linux-gnueabihf-g++"
|
||||||
- mkdir cmake-build && cd cmake-build && cmake -DENABLE_NETSSL=OFF -DENABLE_CRYPTO=OFF -DENABLE_TESTS=ON .. && make -j2 && cd ..
|
- mkdir cmake-build && cd cmake-build && cmake -DENABLE_NETSSL=OFF -DENABLE_CRYPTO=OFF -DENABLE_TESTS=OFF .. && make -j2 && cd ..
|
||||||
|
|
||||||
# TODO osx build
|
# TODO osx build
|
||||||
# TODO run test suite
|
# TODO run test suite
|
||||||
|
@ -551,6 +551,23 @@
|
|||||||
RelativePath=".\src\HTTPSStreamFactoryTest.cpp"/>
|
RelativePath=".\src\HTTPSStreamFactoryTest.cpp"/>
|
||||||
</Filter>
|
</Filter>
|
||||||
</Filter>
|
</Filter>
|
||||||
|
<Filter
|
||||||
|
Name="WebSocket">
|
||||||
|
<Filter
|
||||||
|
Name="Header Files">
|
||||||
|
<File
|
||||||
|
RelativePath=".\src\WebSocketTest.h"/>
|
||||||
|
<File
|
||||||
|
RelativePath=".\src\WebSocketTestSuite.h"/>
|
||||||
|
</Filter>
|
||||||
|
<Filter
|
||||||
|
Name="Source Files">
|
||||||
|
<File
|
||||||
|
RelativePath=".\src\WebSocketTest.cpp"/>
|
||||||
|
<File
|
||||||
|
RelativePath=".\src\WebSocketTestSuite.cpp"/>
|
||||||
|
</Filter>
|
||||||
|
</Filter>
|
||||||
</Files>
|
</Files>
|
||||||
<Globals/>
|
<Globals/>
|
||||||
</VisualStudioProject>
|
</VisualStudioProject>
|
||||||
|
@ -316,6 +316,8 @@
|
|||||||
<ClInclude Include="src\HTTPSClientSessionTest.h"/>
|
<ClInclude Include="src\HTTPSClientSessionTest.h"/>
|
||||||
<ClInclude Include="src\HTTPSClientTestSuite.h"/>
|
<ClInclude Include="src\HTTPSClientTestSuite.h"/>
|
||||||
<ClInclude Include="src\HTTPSStreamFactoryTest.h"/>
|
<ClInclude Include="src\HTTPSStreamFactoryTest.h"/>
|
||||||
|
<ClInclude Include="src\WebSocketTest.h" />
|
||||||
|
<ClInclude Include="src\WebSocketTestSuite.h" />
|
||||||
</ItemGroup>
|
</ItemGroup>
|
||||||
<ItemGroup>
|
<ItemGroup>
|
||||||
<ClCompile Include="src\HTTPSTestServer.cpp"/>
|
<ClCompile Include="src\HTTPSTestServer.cpp"/>
|
||||||
@ -328,6 +330,8 @@
|
|||||||
<ClCompile Include="src\HTTPSClientSessionTest.cpp"/>
|
<ClCompile Include="src\HTTPSClientSessionTest.cpp"/>
|
||||||
<ClCompile Include="src\HTTPSClientTestSuite.cpp"/>
|
<ClCompile Include="src\HTTPSClientTestSuite.cpp"/>
|
||||||
<ClCompile Include="src\HTTPSStreamFactoryTest.cpp"/>
|
<ClCompile Include="src\HTTPSStreamFactoryTest.cpp"/>
|
||||||
|
<ClCompile Include="src\WebSocketTest.cpp" />
|
||||||
|
<ClCompile Include="src\WebSocketTestSuite.cpp" />
|
||||||
</ItemGroup>
|
</ItemGroup>
|
||||||
<Import Project="$(VCTargetsPath)\Microsoft.Cpp.targets"/>
|
<Import Project="$(VCTargetsPath)\Microsoft.Cpp.targets"/>
|
||||||
<ImportGroup Label="ExtensionTargets"/>
|
<ImportGroup Label="ExtensionTargets"/>
|
||||||
|
@ -316,6 +316,8 @@
|
|||||||
<ClInclude Include="src\NetSSLTestSuite.h"/>
|
<ClInclude Include="src\NetSSLTestSuite.h"/>
|
||||||
<ClInclude Include="src\TCPServerTest.h"/>
|
<ClInclude Include="src\TCPServerTest.h"/>
|
||||||
<ClInclude Include="src\TCPServerTestSuite.h"/>
|
<ClInclude Include="src\TCPServerTestSuite.h"/>
|
||||||
|
<ClInclude Include="src\WebSocketTest.h" />
|
||||||
|
<ClInclude Include="src\WebSocketTestSuite.h" />
|
||||||
</ItemGroup>
|
</ItemGroup>
|
||||||
<ItemGroup>
|
<ItemGroup>
|
||||||
<ClCompile Include="src\HTTPSClientSessionTest.cpp"/>
|
<ClCompile Include="src\HTTPSClientSessionTest.cpp"/>
|
||||||
@ -328,6 +330,8 @@
|
|||||||
<ClCompile Include="src\TCPServerTest.cpp"/>
|
<ClCompile Include="src\TCPServerTest.cpp"/>
|
||||||
<ClCompile Include="src\TCPServerTestSuite.cpp"/>
|
<ClCompile Include="src\TCPServerTestSuite.cpp"/>
|
||||||
<ClCompile Include="src\WinCEDriver.cpp"/>
|
<ClCompile Include="src\WinCEDriver.cpp"/>
|
||||||
|
<ClCompile Include="src\WebSocketTest.cpp" />
|
||||||
|
<ClCompile Include="src\WebSocketTestSuite.cpp" />
|
||||||
</ItemGroup>
|
</ItemGroup>
|
||||||
<Import Project="$(VCTargetsPath)\Microsoft.Cpp.targets"/>
|
<Import Project="$(VCTargetsPath)\Microsoft.Cpp.targets"/>
|
||||||
<ImportGroup Label="ExtensionTargets"/>
|
<ImportGroup Label="ExtensionTargets"/>
|
||||||
|
@ -321,6 +321,8 @@
|
|||||||
<ClInclude Include="src\HTTPSClientSessionTest.h"/>
|
<ClInclude Include="src\HTTPSClientSessionTest.h"/>
|
||||||
<ClInclude Include="src\HTTPSClientTestSuite.h"/>
|
<ClInclude Include="src\HTTPSClientTestSuite.h"/>
|
||||||
<ClInclude Include="src\HTTPSStreamFactoryTest.h"/>
|
<ClInclude Include="src\HTTPSStreamFactoryTest.h"/>
|
||||||
|
<ClInclude Include="src\WebSocketTest.h" />
|
||||||
|
<ClInclude Include="src\WebSocketTestSuite.h" />
|
||||||
</ItemGroup>
|
</ItemGroup>
|
||||||
<ItemGroup>
|
<ItemGroup>
|
||||||
<ClCompile Include="src\HTTPSTestServer.cpp"/>
|
<ClCompile Include="src\HTTPSTestServer.cpp"/>
|
||||||
@ -333,6 +335,8 @@
|
|||||||
<ClCompile Include="src\HTTPSClientSessionTest.cpp"/>
|
<ClCompile Include="src\HTTPSClientSessionTest.cpp"/>
|
||||||
<ClCompile Include="src\HTTPSClientTestSuite.cpp"/>
|
<ClCompile Include="src\HTTPSClientTestSuite.cpp"/>
|
||||||
<ClCompile Include="src\HTTPSStreamFactoryTest.cpp"/>
|
<ClCompile Include="src\HTTPSStreamFactoryTest.cpp"/>
|
||||||
|
<ClCompile Include="src\WebSocketTest.cpp" />
|
||||||
|
<ClCompile Include="src\WebSocketTestSuite.cpp" />
|
||||||
</ItemGroup>
|
</ItemGroup>
|
||||||
<Import Project="$(VCTargetsPath)\Microsoft.Cpp.targets"/>
|
<Import Project="$(VCTargetsPath)\Microsoft.Cpp.targets"/>
|
||||||
<ImportGroup Label="ExtensionTargets"/>
|
<ImportGroup Label="ExtensionTargets"/>
|
||||||
|
@ -321,6 +321,8 @@
|
|||||||
<ClInclude Include="src\HTTPSClientSessionTest.h"/>
|
<ClInclude Include="src\HTTPSClientSessionTest.h"/>
|
||||||
<ClInclude Include="src\HTTPSClientTestSuite.h"/>
|
<ClInclude Include="src\HTTPSClientTestSuite.h"/>
|
||||||
<ClInclude Include="src\HTTPSStreamFactoryTest.h"/>
|
<ClInclude Include="src\HTTPSStreamFactoryTest.h"/>
|
||||||
|
<ClInclude Include="src\WebSocketTest.h" />
|
||||||
|
<ClInclude Include="src\WebSocketTestSuite.h" />
|
||||||
</ItemGroup>
|
</ItemGroup>
|
||||||
<ItemGroup>
|
<ItemGroup>
|
||||||
<ClCompile Include="src\HTTPSTestServer.cpp"/>
|
<ClCompile Include="src\HTTPSTestServer.cpp"/>
|
||||||
@ -333,6 +335,8 @@
|
|||||||
<ClCompile Include="src\HTTPSClientSessionTest.cpp"/>
|
<ClCompile Include="src\HTTPSClientSessionTest.cpp"/>
|
||||||
<ClCompile Include="src\HTTPSClientTestSuite.cpp"/>
|
<ClCompile Include="src\HTTPSClientTestSuite.cpp"/>
|
||||||
<ClCompile Include="src\HTTPSStreamFactoryTest.cpp"/>
|
<ClCompile Include="src\HTTPSStreamFactoryTest.cpp"/>
|
||||||
|
<ClCompile Include="src\WebSocketTest.cpp" />
|
||||||
|
<ClCompile Include="src\WebSocketTestSuite.cpp" />
|
||||||
</ItemGroup>
|
</ItemGroup>
|
||||||
<Import Project="$(VCTargetsPath)\Microsoft.Cpp.targets"/>
|
<Import Project="$(VCTargetsPath)\Microsoft.Cpp.targets"/>
|
||||||
<ImportGroup Label="ExtensionTargets"/>
|
<ImportGroup Label="ExtensionTargets"/>
|
||||||
|
@ -1,4 +1,4 @@
|
|||||||
<?xml version="1.0" encoding="UTF-8"?>
|
<?xml version="1.0" encoding="utf-8"?>
|
||||||
<Project DefaultTargets="Build" ToolsVersion="12.0" xmlns="http://schemas.microsoft.com/developer/msbuild/2003">
|
<Project DefaultTargets="Build" ToolsVersion="12.0" xmlns="http://schemas.microsoft.com/developer/msbuild/2003">
|
||||||
<ItemGroup Label="ProjectConfigurations">
|
<ItemGroup Label="ProjectConfigurations">
|
||||||
<ProjectConfiguration Include="debug_shared|Win32">
|
<ProjectConfiguration Include="debug_shared|Win32">
|
||||||
@ -32,7 +32,7 @@
|
|||||||
<RootNamespace>TestSuite</RootNamespace>
|
<RootNamespace>TestSuite</RootNamespace>
|
||||||
<Keyword>Win32Proj</Keyword>
|
<Keyword>Win32Proj</Keyword>
|
||||||
</PropertyGroup>
|
</PropertyGroup>
|
||||||
<Import Project="$(VCTargetsPath)\Microsoft.Cpp.Default.props"/>
|
<Import Project="$(VCTargetsPath)\Microsoft.Cpp.Default.props" />
|
||||||
<PropertyGroup Condition="'$(Configuration)|$(Platform)'=='release_static_md|Win32'" Label="Configuration">
|
<PropertyGroup Condition="'$(Configuration)|$(Platform)'=='release_static_md|Win32'" Label="Configuration">
|
||||||
<ConfigurationType>Application</ConfigurationType>
|
<ConfigurationType>Application</ConfigurationType>
|
||||||
<CharacterSet>MultiByte</CharacterSet>
|
<CharacterSet>MultiByte</CharacterSet>
|
||||||
@ -63,27 +63,27 @@
|
|||||||
<CharacterSet>MultiByte</CharacterSet>
|
<CharacterSet>MultiByte</CharacterSet>
|
||||||
<PlatformToolset>v120</PlatformToolset>
|
<PlatformToolset>v120</PlatformToolset>
|
||||||
</PropertyGroup>
|
</PropertyGroup>
|
||||||
<Import Project="$(VCTargetsPath)\Microsoft.Cpp.props"/>
|
<Import Project="$(VCTargetsPath)\Microsoft.Cpp.props" />
|
||||||
<ImportGroup Label="ExtensionSettings"/>
|
<ImportGroup Label="ExtensionSettings" />
|
||||||
<ImportGroup Condition="'$(Configuration)|$(Platform)'=='release_static_md|Win32'" Label="PropertySheets">
|
<ImportGroup Condition="'$(Configuration)|$(Platform)'=='release_static_md|Win32'" Label="PropertySheets">
|
||||||
<Import Condition="exists('$(UserRootDir)\Microsoft.Cpp.$(Platform).user.props')" Label="LocalAppDataPlatform" Project="$(UserRootDir)\Microsoft.Cpp.$(Platform).user.props"/>
|
<Import Condition="exists('$(UserRootDir)\Microsoft.Cpp.$(Platform).user.props')" Label="LocalAppDataPlatform" Project="$(UserRootDir)\Microsoft.Cpp.$(Platform).user.props" />
|
||||||
</ImportGroup>
|
</ImportGroup>
|
||||||
<ImportGroup Condition="'$(Configuration)|$(Platform)'=='debug_static_md|Win32'" Label="PropertySheets">
|
<ImportGroup Condition="'$(Configuration)|$(Platform)'=='debug_static_md|Win32'" Label="PropertySheets">
|
||||||
<Import Condition="exists('$(UserRootDir)\Microsoft.Cpp.$(Platform).user.props')" Label="LocalAppDataPlatform" Project="$(UserRootDir)\Microsoft.Cpp.$(Platform).user.props"/>
|
<Import Condition="exists('$(UserRootDir)\Microsoft.Cpp.$(Platform).user.props')" Label="LocalAppDataPlatform" Project="$(UserRootDir)\Microsoft.Cpp.$(Platform).user.props" />
|
||||||
</ImportGroup>
|
</ImportGroup>
|
||||||
<ImportGroup Condition="'$(Configuration)|$(Platform)'=='release_static_mt|Win32'" Label="PropertySheets">
|
<ImportGroup Condition="'$(Configuration)|$(Platform)'=='release_static_mt|Win32'" Label="PropertySheets">
|
||||||
<Import Condition="exists('$(UserRootDir)\Microsoft.Cpp.$(Platform).user.props')" Label="LocalAppDataPlatform" Project="$(UserRootDir)\Microsoft.Cpp.$(Platform).user.props"/>
|
<Import Condition="exists('$(UserRootDir)\Microsoft.Cpp.$(Platform).user.props')" Label="LocalAppDataPlatform" Project="$(UserRootDir)\Microsoft.Cpp.$(Platform).user.props" />
|
||||||
</ImportGroup>
|
</ImportGroup>
|
||||||
<ImportGroup Condition="'$(Configuration)|$(Platform)'=='debug_static_mt|Win32'" Label="PropertySheets">
|
<ImportGroup Condition="'$(Configuration)|$(Platform)'=='debug_static_mt|Win32'" Label="PropertySheets">
|
||||||
<Import Condition="exists('$(UserRootDir)\Microsoft.Cpp.$(Platform).user.props')" Label="LocalAppDataPlatform" Project="$(UserRootDir)\Microsoft.Cpp.$(Platform).user.props"/>
|
<Import Condition="exists('$(UserRootDir)\Microsoft.Cpp.$(Platform).user.props')" Label="LocalAppDataPlatform" Project="$(UserRootDir)\Microsoft.Cpp.$(Platform).user.props" />
|
||||||
</ImportGroup>
|
</ImportGroup>
|
||||||
<ImportGroup Condition="'$(Configuration)|$(Platform)'=='release_shared|Win32'" Label="PropertySheets">
|
<ImportGroup Condition="'$(Configuration)|$(Platform)'=='release_shared|Win32'" Label="PropertySheets">
|
||||||
<Import Condition="exists('$(UserRootDir)\Microsoft.Cpp.$(Platform).user.props')" Label="LocalAppDataPlatform" Project="$(UserRootDir)\Microsoft.Cpp.$(Platform).user.props"/>
|
<Import Condition="exists('$(UserRootDir)\Microsoft.Cpp.$(Platform).user.props')" Label="LocalAppDataPlatform" Project="$(UserRootDir)\Microsoft.Cpp.$(Platform).user.props" />
|
||||||
</ImportGroup>
|
</ImportGroup>
|
||||||
<ImportGroup Condition="'$(Configuration)|$(Platform)'=='debug_shared|Win32'" Label="PropertySheets">
|
<ImportGroup Condition="'$(Configuration)|$(Platform)'=='debug_shared|Win32'" Label="PropertySheets">
|
||||||
<Import Condition="exists('$(UserRootDir)\Microsoft.Cpp.$(Platform).user.props')" Label="LocalAppDataPlatform" Project="$(UserRootDir)\Microsoft.Cpp.$(Platform).user.props"/>
|
<Import Condition="exists('$(UserRootDir)\Microsoft.Cpp.$(Platform).user.props')" Label="LocalAppDataPlatform" Project="$(UserRootDir)\Microsoft.Cpp.$(Platform).user.props" />
|
||||||
</ImportGroup>
|
</ImportGroup>
|
||||||
<PropertyGroup Label="UserMacros"/>
|
<PropertyGroup Label="UserMacros" />
|
||||||
<PropertyGroup>
|
<PropertyGroup>
|
||||||
<_ProjectFileVersion>12.0.30501.0</_ProjectFileVersion>
|
<_ProjectFileVersion>12.0.30501.0</_ProjectFileVersion>
|
||||||
<TargetName Condition="'$(Configuration)|$(Platform)'=='debug_shared|Win32'">TestSuited</TargetName>
|
<TargetName Condition="'$(Configuration)|$(Platform)'=='debug_shared|Win32'">TestSuited</TargetName>
|
||||||
@ -136,7 +136,7 @@
|
|||||||
<TreatWChar_tAsBuiltInType>true</TreatWChar_tAsBuiltInType>
|
<TreatWChar_tAsBuiltInType>true</TreatWChar_tAsBuiltInType>
|
||||||
<ForceConformanceInForLoopScope>true</ForceConformanceInForLoopScope>
|
<ForceConformanceInForLoopScope>true</ForceConformanceInForLoopScope>
|
||||||
<RuntimeTypeInfo>true</RuntimeTypeInfo>
|
<RuntimeTypeInfo>true</RuntimeTypeInfo>
|
||||||
<PrecompiledHeader/>
|
<PrecompiledHeader />
|
||||||
<WarningLevel>Level3</WarningLevel>
|
<WarningLevel>Level3</WarningLevel>
|
||||||
<DebugInformationFormat>ProgramDatabase</DebugInformationFormat>
|
<DebugInformationFormat>ProgramDatabase</DebugInformationFormat>
|
||||||
<CompileAs>Default</CompileAs>
|
<CompileAs>Default</CompileAs>
|
||||||
@ -167,9 +167,9 @@
|
|||||||
<TreatWChar_tAsBuiltInType>true</TreatWChar_tAsBuiltInType>
|
<TreatWChar_tAsBuiltInType>true</TreatWChar_tAsBuiltInType>
|
||||||
<ForceConformanceInForLoopScope>true</ForceConformanceInForLoopScope>
|
<ForceConformanceInForLoopScope>true</ForceConformanceInForLoopScope>
|
||||||
<RuntimeTypeInfo>true</RuntimeTypeInfo>
|
<RuntimeTypeInfo>true</RuntimeTypeInfo>
|
||||||
<PrecompiledHeader/>
|
<PrecompiledHeader />
|
||||||
<WarningLevel>Level3</WarningLevel>
|
<WarningLevel>Level3</WarningLevel>
|
||||||
<DebugInformationFormat/>
|
<DebugInformationFormat />
|
||||||
<CompileAs>Default</CompileAs>
|
<CompileAs>Default</CompileAs>
|
||||||
</ClCompile>
|
</ClCompile>
|
||||||
<Link>
|
<Link>
|
||||||
@ -196,7 +196,7 @@
|
|||||||
<TreatWChar_tAsBuiltInType>true</TreatWChar_tAsBuiltInType>
|
<TreatWChar_tAsBuiltInType>true</TreatWChar_tAsBuiltInType>
|
||||||
<ForceConformanceInForLoopScope>true</ForceConformanceInForLoopScope>
|
<ForceConformanceInForLoopScope>true</ForceConformanceInForLoopScope>
|
||||||
<RuntimeTypeInfo>true</RuntimeTypeInfo>
|
<RuntimeTypeInfo>true</RuntimeTypeInfo>
|
||||||
<PrecompiledHeader/>
|
<PrecompiledHeader />
|
||||||
<WarningLevel>Level3</WarningLevel>
|
<WarningLevel>Level3</WarningLevel>
|
||||||
<DebugInformationFormat>ProgramDatabase</DebugInformationFormat>
|
<DebugInformationFormat>ProgramDatabase</DebugInformationFormat>
|
||||||
<CompileAs>Default</CompileAs>
|
<CompileAs>Default</CompileAs>
|
||||||
@ -227,9 +227,9 @@
|
|||||||
<TreatWChar_tAsBuiltInType>true</TreatWChar_tAsBuiltInType>
|
<TreatWChar_tAsBuiltInType>true</TreatWChar_tAsBuiltInType>
|
||||||
<ForceConformanceInForLoopScope>true</ForceConformanceInForLoopScope>
|
<ForceConformanceInForLoopScope>true</ForceConformanceInForLoopScope>
|
||||||
<RuntimeTypeInfo>true</RuntimeTypeInfo>
|
<RuntimeTypeInfo>true</RuntimeTypeInfo>
|
||||||
<PrecompiledHeader/>
|
<PrecompiledHeader />
|
||||||
<WarningLevel>Level3</WarningLevel>
|
<WarningLevel>Level3</WarningLevel>
|
||||||
<DebugInformationFormat/>
|
<DebugInformationFormat />
|
||||||
<CompileAs>Default</CompileAs>
|
<CompileAs>Default</CompileAs>
|
||||||
</ClCompile>
|
</ClCompile>
|
||||||
<Link>
|
<Link>
|
||||||
@ -256,7 +256,7 @@
|
|||||||
<TreatWChar_tAsBuiltInType>true</TreatWChar_tAsBuiltInType>
|
<TreatWChar_tAsBuiltInType>true</TreatWChar_tAsBuiltInType>
|
||||||
<ForceConformanceInForLoopScope>true</ForceConformanceInForLoopScope>
|
<ForceConformanceInForLoopScope>true</ForceConformanceInForLoopScope>
|
||||||
<RuntimeTypeInfo>true</RuntimeTypeInfo>
|
<RuntimeTypeInfo>true</RuntimeTypeInfo>
|
||||||
<PrecompiledHeader/>
|
<PrecompiledHeader />
|
||||||
<WarningLevel>Level3</WarningLevel>
|
<WarningLevel>Level3</WarningLevel>
|
||||||
<DebugInformationFormat>ProgramDatabase</DebugInformationFormat>
|
<DebugInformationFormat>ProgramDatabase</DebugInformationFormat>
|
||||||
<CompileAs>Default</CompileAs>
|
<CompileAs>Default</CompileAs>
|
||||||
@ -287,9 +287,9 @@
|
|||||||
<TreatWChar_tAsBuiltInType>true</TreatWChar_tAsBuiltInType>
|
<TreatWChar_tAsBuiltInType>true</TreatWChar_tAsBuiltInType>
|
||||||
<ForceConformanceInForLoopScope>true</ForceConformanceInForLoopScope>
|
<ForceConformanceInForLoopScope>true</ForceConformanceInForLoopScope>
|
||||||
<RuntimeTypeInfo>true</RuntimeTypeInfo>
|
<RuntimeTypeInfo>true</RuntimeTypeInfo>
|
||||||
<PrecompiledHeader/>
|
<PrecompiledHeader />
|
||||||
<WarningLevel>Level3</WarningLevel>
|
<WarningLevel>Level3</WarningLevel>
|
||||||
<DebugInformationFormat/>
|
<DebugInformationFormat />
|
||||||
<CompileAs>Default</CompileAs>
|
<CompileAs>Default</CompileAs>
|
||||||
</ClCompile>
|
</ClCompile>
|
||||||
<Link>
|
<Link>
|
||||||
@ -304,28 +304,32 @@
|
|||||||
</Link>
|
</Link>
|
||||||
</ItemDefinitionGroup>
|
</ItemDefinitionGroup>
|
||||||
<ItemGroup>
|
<ItemGroup>
|
||||||
<ClInclude Include="src\HTTPSClientSessionTest.h"/>
|
<ClInclude Include="src\HTTPSClientSessionTest.h" />
|
||||||
<ClInclude Include="src\HTTPSClientTestSuite.h"/>
|
<ClInclude Include="src\HTTPSClientTestSuite.h" />
|
||||||
<ClInclude Include="src\HTTPSServerTest.h"/>
|
<ClInclude Include="src\HTTPSServerTest.h" />
|
||||||
<ClInclude Include="src\HTTPSServerTestSuite.h"/>
|
<ClInclude Include="src\HTTPSServerTestSuite.h" />
|
||||||
<ClInclude Include="src\HTTPSStreamFactoryTest.h"/>
|
<ClInclude Include="src\HTTPSStreamFactoryTest.h" />
|
||||||
<ClInclude Include="src\HTTPSTestServer.h"/>
|
<ClInclude Include="src\HTTPSTestServer.h" />
|
||||||
<ClInclude Include="src\NetSSLTestSuite.h"/>
|
<ClInclude Include="src\NetSSLTestSuite.h" />
|
||||||
<ClInclude Include="src\TCPServerTest.h"/>
|
<ClInclude Include="src\TCPServerTest.h" />
|
||||||
<ClInclude Include="src\TCPServerTestSuite.h"/>
|
<ClInclude Include="src\TCPServerTestSuite.h" />
|
||||||
|
<ClInclude Include="src\WebSocketTest.h" />
|
||||||
|
<ClInclude Include="src\WebSocketTestSuite.h" />
|
||||||
</ItemGroup>
|
</ItemGroup>
|
||||||
<ItemGroup>
|
<ItemGroup>
|
||||||
<ClCompile Include="src\Driver.cpp"/>
|
<ClCompile Include="src\Driver.cpp" />
|
||||||
<ClCompile Include="src\HTTPSClientSessionTest.cpp"/>
|
<ClCompile Include="src\HTTPSClientSessionTest.cpp" />
|
||||||
<ClCompile Include="src\HTTPSClientTestSuite.cpp"/>
|
<ClCompile Include="src\HTTPSClientTestSuite.cpp" />
|
||||||
<ClCompile Include="src\HTTPSServerTest.cpp"/>
|
<ClCompile Include="src\HTTPSServerTest.cpp" />
|
||||||
<ClCompile Include="src\HTTPSServerTestSuite.cpp"/>
|
<ClCompile Include="src\HTTPSServerTestSuite.cpp" />
|
||||||
<ClCompile Include="src\HTTPSStreamFactoryTest.cpp"/>
|
<ClCompile Include="src\HTTPSStreamFactoryTest.cpp" />
|
||||||
<ClCompile Include="src\HTTPSTestServer.cpp"/>
|
<ClCompile Include="src\HTTPSTestServer.cpp" />
|
||||||
<ClCompile Include="src\NetSSLTestSuite.cpp"/>
|
<ClCompile Include="src\NetSSLTestSuite.cpp" />
|
||||||
<ClCompile Include="src\TCPServerTest.cpp"/>
|
<ClCompile Include="src\TCPServerTest.cpp" />
|
||||||
<ClCompile Include="src\TCPServerTestSuite.cpp"/>
|
<ClCompile Include="src\TCPServerTestSuite.cpp" />
|
||||||
|
<ClCompile Include="src\WebSocketTest.cpp" />
|
||||||
|
<ClCompile Include="src\WebSocketTestSuite.cpp" />
|
||||||
</ItemGroup>
|
</ItemGroup>
|
||||||
<Import Project="$(VCTargetsPath)\Microsoft.Cpp.targets"/>
|
<Import Project="$(VCTargetsPath)\Microsoft.Cpp.targets" />
|
||||||
<ImportGroup Label="ExtensionTargets"/>
|
<ImportGroup Label="ExtensionTargets" />
|
||||||
</Project>
|
</Project>
|
@ -52,6 +52,9 @@
|
|||||||
<Filter Include="HTTPSClient\Source Files">
|
<Filter Include="HTTPSClient\Source Files">
|
||||||
<UniqueIdentifier>{40e36c0c-5808-4c87-aa2e-04c0ffa6f35e}</UniqueIdentifier>
|
<UniqueIdentifier>{40e36c0c-5808-4c87-aa2e-04c0ffa6f35e}</UniqueIdentifier>
|
||||||
</Filter>
|
</Filter>
|
||||||
|
<Filter Include="Websocket">
|
||||||
|
<UniqueIdentifier>{9243a946-e87f-42f5-adba-efbb4823f93c}</UniqueIdentifier>
|
||||||
|
</Filter>
|
||||||
</ItemGroup>
|
</ItemGroup>
|
||||||
<ItemGroup>
|
<ItemGroup>
|
||||||
<ClInclude Include="src\HTTPSTestServer.h">
|
<ClInclude Include="src\HTTPSTestServer.h">
|
||||||
@ -81,6 +84,12 @@
|
|||||||
<ClInclude Include="src\HTTPSStreamFactoryTest.h">
|
<ClInclude Include="src\HTTPSStreamFactoryTest.h">
|
||||||
<Filter>HTTPSClient\Header Files</Filter>
|
<Filter>HTTPSClient\Header Files</Filter>
|
||||||
</ClInclude>
|
</ClInclude>
|
||||||
|
<ClInclude Include="src\WebSocketTest.h">
|
||||||
|
<Filter>Websocket</Filter>
|
||||||
|
</ClInclude>
|
||||||
|
<ClInclude Include="src\WebSocketTestSuite.h">
|
||||||
|
<Filter>Websocket</Filter>
|
||||||
|
</ClInclude>
|
||||||
</ItemGroup>
|
</ItemGroup>
|
||||||
<ItemGroup>
|
<ItemGroup>
|
||||||
<ClCompile Include="src\HTTPSTestServer.cpp">
|
<ClCompile Include="src\HTTPSTestServer.cpp">
|
||||||
@ -113,5 +122,11 @@
|
|||||||
<ClCompile Include="src\HTTPSStreamFactoryTest.cpp">
|
<ClCompile Include="src\HTTPSStreamFactoryTest.cpp">
|
||||||
<Filter>HTTPSClient\Source Files</Filter>
|
<Filter>HTTPSClient\Source Files</Filter>
|
||||||
</ClCompile>
|
</ClCompile>
|
||||||
|
<ClCompile Include="src\WebSocketTest.cpp">
|
||||||
|
<Filter>Websocket</Filter>
|
||||||
|
</ClCompile>
|
||||||
|
<ClCompile Include="src\WebSocketTestSuite.cpp">
|
||||||
|
<Filter>Websocket</Filter>
|
||||||
|
</ClCompile>
|
||||||
</ItemGroup>
|
</ItemGroup>
|
||||||
</Project>
|
</Project>
|
@ -313,6 +313,8 @@
|
|||||||
<ClInclude Include="src\NetSSLTestSuite.h"/>
|
<ClInclude Include="src\NetSSLTestSuite.h"/>
|
||||||
<ClInclude Include="src\TCPServerTest.h"/>
|
<ClInclude Include="src\TCPServerTest.h"/>
|
||||||
<ClInclude Include="src\TCPServerTestSuite.h"/>
|
<ClInclude Include="src\TCPServerTestSuite.h"/>
|
||||||
|
<ClInclude Include="src\WebSocketTest.h" />
|
||||||
|
<ClInclude Include="src\WebSocketTestSuite.h" />
|
||||||
</ItemGroup>
|
</ItemGroup>
|
||||||
<ItemGroup>
|
<ItemGroup>
|
||||||
<ClCompile Include="src\Driver.cpp"/>
|
<ClCompile Include="src\Driver.cpp"/>
|
||||||
@ -325,6 +327,8 @@
|
|||||||
<ClCompile Include="src\NetSSLTestSuite.cpp"/>
|
<ClCompile Include="src\NetSSLTestSuite.cpp"/>
|
||||||
<ClCompile Include="src\TCPServerTest.cpp"/>
|
<ClCompile Include="src\TCPServerTest.cpp"/>
|
||||||
<ClCompile Include="src\TCPServerTestSuite.cpp"/>
|
<ClCompile Include="src\TCPServerTestSuite.cpp"/>
|
||||||
|
<ClCompile Include="src\WebSocketTest.cpp" />
|
||||||
|
<ClCompile Include="src\WebSocketTestSuite.cpp" />
|
||||||
</ItemGroup>
|
</ItemGroup>
|
||||||
<Import Project="$(VCTargetsPath)\Microsoft.Cpp.targets"/>
|
<Import Project="$(VCTargetsPath)\Microsoft.Cpp.targets"/>
|
||||||
<ImportGroup Label="ExtensionTargets"/>
|
<ImportGroup Label="ExtensionTargets"/>
|
||||||
|
@ -532,6 +532,23 @@
|
|||||||
RelativePath=".\src\HTTPSStreamFactoryTest.cpp"/>
|
RelativePath=".\src\HTTPSStreamFactoryTest.cpp"/>
|
||||||
</Filter>
|
</Filter>
|
||||||
</Filter>
|
</Filter>
|
||||||
|
<Filter
|
||||||
|
Name="WebSocket">
|
||||||
|
<Filter
|
||||||
|
Name="Header Files">
|
||||||
|
<File
|
||||||
|
RelativePath=".\src\WebSocketTest.h"/>
|
||||||
|
<File
|
||||||
|
RelativePath=".\src\WebSocketTestSuite.h"/>
|
||||||
|
</Filter>
|
||||||
|
<Filter
|
||||||
|
Name="Source Files">
|
||||||
|
<File
|
||||||
|
RelativePath=".\src\WebSocketTest.cpp"/>
|
||||||
|
<File
|
||||||
|
RelativePath=".\src\WebSocketTestSuite.cpp"/>
|
||||||
|
</Filter>
|
||||||
|
</Filter>
|
||||||
</Files>
|
</Files>
|
||||||
<Globals/>
|
<Globals/>
|
||||||
</VisualStudioProject>
|
</VisualStudioProject>
|
||||||
|
@ -321,6 +321,8 @@
|
|||||||
<ClInclude Include="src\HTTPSClientSessionTest.h"/>
|
<ClInclude Include="src\HTTPSClientSessionTest.h"/>
|
||||||
<ClInclude Include="src\HTTPSClientTestSuite.h"/>
|
<ClInclude Include="src\HTTPSClientTestSuite.h"/>
|
||||||
<ClInclude Include="src\HTTPSStreamFactoryTest.h"/>
|
<ClInclude Include="src\HTTPSStreamFactoryTest.h"/>
|
||||||
|
<ClInclude Include="src\WebSocketTest.h" />
|
||||||
|
<ClInclude Include="src\WebSocketTestSuite.h" />
|
||||||
</ItemGroup>
|
</ItemGroup>
|
||||||
<ItemGroup>
|
<ItemGroup>
|
||||||
<ClCompile Include="src\HTTPSTestServer.cpp"/>
|
<ClCompile Include="src\HTTPSTestServer.cpp"/>
|
||||||
@ -333,6 +335,8 @@
|
|||||||
<ClCompile Include="src\HTTPSClientSessionTest.cpp"/>
|
<ClCompile Include="src\HTTPSClientSessionTest.cpp"/>
|
||||||
<ClCompile Include="src\HTTPSClientTestSuite.cpp"/>
|
<ClCompile Include="src\HTTPSClientTestSuite.cpp"/>
|
||||||
<ClCompile Include="src\HTTPSStreamFactoryTest.cpp"/>
|
<ClCompile Include="src\HTTPSStreamFactoryTest.cpp"/>
|
||||||
|
<ClCompile Include="src\WebSocketTest.cpp" />
|
||||||
|
<ClCompile Include="src\WebSocketTestSuite.cpp" />
|
||||||
</ItemGroup>
|
</ItemGroup>
|
||||||
<Import Project="$(VCTargetsPath)\Microsoft.Cpp.targets"/>
|
<Import Project="$(VCTargetsPath)\Microsoft.Cpp.targets"/>
|
||||||
<ImportGroup Label="ExtensionTargets"/>
|
<ImportGroup Label="ExtensionTargets"/>
|
||||||
|
@ -321,6 +321,8 @@
|
|||||||
<ClInclude Include="src\HTTPSClientSessionTest.h"/>
|
<ClInclude Include="src\HTTPSClientSessionTest.h"/>
|
||||||
<ClInclude Include="src\HTTPSClientTestSuite.h"/>
|
<ClInclude Include="src\HTTPSClientTestSuite.h"/>
|
||||||
<ClInclude Include="src\HTTPSStreamFactoryTest.h"/>
|
<ClInclude Include="src\HTTPSStreamFactoryTest.h"/>
|
||||||
|
<ClInclude Include="src\WebSocketTest.h" />
|
||||||
|
<ClInclude Include="src\WebSocketTestSuite.h" />
|
||||||
</ItemGroup>
|
</ItemGroup>
|
||||||
<ItemGroup>
|
<ItemGroup>
|
||||||
<ClCompile Include="src\HTTPSTestServer.cpp"/>
|
<ClCompile Include="src\HTTPSTestServer.cpp"/>
|
||||||
@ -333,6 +335,8 @@
|
|||||||
<ClCompile Include="src\HTTPSClientSessionTest.cpp"/>
|
<ClCompile Include="src\HTTPSClientSessionTest.cpp"/>
|
||||||
<ClCompile Include="src\HTTPSClientTestSuite.cpp"/>
|
<ClCompile Include="src\HTTPSClientTestSuite.cpp"/>
|
||||||
<ClCompile Include="src\HTTPSStreamFactoryTest.cpp"/>
|
<ClCompile Include="src\HTTPSStreamFactoryTest.cpp"/>
|
||||||
|
<ClCompile Include="src\WebSocketTest.cpp" />
|
||||||
|
<ClCompile Include="src\WebSocketTestSuite.cpp" />
|
||||||
</ItemGroup>
|
</ItemGroup>
|
||||||
<Import Project="$(VCTargetsPath)\Microsoft.Cpp.targets"/>
|
<Import Project="$(VCTargetsPath)\Microsoft.Cpp.targets"/>
|
||||||
<ImportGroup Label="ExtensionTargets"/>
|
<ImportGroup Label="ExtensionTargets"/>
|
||||||
|
@ -1,4 +1,4 @@
|
|||||||
<?xml version="1.0" encoding="UTF-8"?>
|
<?xml version="1.0" encoding="utf-8"?>
|
||||||
<Project DefaultTargets="Build" ToolsVersion="12.0" xmlns="http://schemas.microsoft.com/developer/msbuild/2003">
|
<Project DefaultTargets="Build" ToolsVersion="12.0" xmlns="http://schemas.microsoft.com/developer/msbuild/2003">
|
||||||
<ItemGroup Label="ProjectConfigurations">
|
<ItemGroup Label="ProjectConfigurations">
|
||||||
<ProjectConfiguration Include="debug_shared|x64">
|
<ProjectConfiguration Include="debug_shared|x64">
|
||||||
@ -32,7 +32,7 @@
|
|||||||
<RootNamespace>TestSuite</RootNamespace>
|
<RootNamespace>TestSuite</RootNamespace>
|
||||||
<Keyword>Win32Proj</Keyword>
|
<Keyword>Win32Proj</Keyword>
|
||||||
</PropertyGroup>
|
</PropertyGroup>
|
||||||
<Import Project="$(VCTargetsPath)\Microsoft.Cpp.Default.props"/>
|
<Import Project="$(VCTargetsPath)\Microsoft.Cpp.Default.props" />
|
||||||
<PropertyGroup Condition="'$(Configuration)|$(Platform)'=='release_static_md|x64'" Label="Configuration">
|
<PropertyGroup Condition="'$(Configuration)|$(Platform)'=='release_static_md|x64'" Label="Configuration">
|
||||||
<ConfigurationType>Application</ConfigurationType>
|
<ConfigurationType>Application</ConfigurationType>
|
||||||
<CharacterSet>MultiByte</CharacterSet>
|
<CharacterSet>MultiByte</CharacterSet>
|
||||||
@ -63,27 +63,27 @@
|
|||||||
<CharacterSet>MultiByte</CharacterSet>
|
<CharacterSet>MultiByte</CharacterSet>
|
||||||
<PlatformToolset>v120</PlatformToolset>
|
<PlatformToolset>v120</PlatformToolset>
|
||||||
</PropertyGroup>
|
</PropertyGroup>
|
||||||
<Import Project="$(VCTargetsPath)\Microsoft.Cpp.props"/>
|
<Import Project="$(VCTargetsPath)\Microsoft.Cpp.props" />
|
||||||
<ImportGroup Label="ExtensionSettings"/>
|
<ImportGroup Label="ExtensionSettings" />
|
||||||
<ImportGroup Condition="'$(Configuration)|$(Platform)'=='release_static_md|x64'" Label="PropertySheets">
|
<ImportGroup Condition="'$(Configuration)|$(Platform)'=='release_static_md|x64'" Label="PropertySheets">
|
||||||
<Import Condition="exists('$(UserRootDir)\Microsoft.Cpp.$(Platform).user.props')" Label="LocalAppDataPlatform" Project="$(UserRootDir)\Microsoft.Cpp.$(Platform).user.props"/>
|
<Import Condition="exists('$(UserRootDir)\Microsoft.Cpp.$(Platform).user.props')" Label="LocalAppDataPlatform" Project="$(UserRootDir)\Microsoft.Cpp.$(Platform).user.props" />
|
||||||
</ImportGroup>
|
</ImportGroup>
|
||||||
<ImportGroup Condition="'$(Configuration)|$(Platform)'=='debug_static_md|x64'" Label="PropertySheets">
|
<ImportGroup Condition="'$(Configuration)|$(Platform)'=='debug_static_md|x64'" Label="PropertySheets">
|
||||||
<Import Condition="exists('$(UserRootDir)\Microsoft.Cpp.$(Platform).user.props')" Label="LocalAppDataPlatform" Project="$(UserRootDir)\Microsoft.Cpp.$(Platform).user.props"/>
|
<Import Condition="exists('$(UserRootDir)\Microsoft.Cpp.$(Platform).user.props')" Label="LocalAppDataPlatform" Project="$(UserRootDir)\Microsoft.Cpp.$(Platform).user.props" />
|
||||||
</ImportGroup>
|
</ImportGroup>
|
||||||
<ImportGroup Condition="'$(Configuration)|$(Platform)'=='release_static_mt|x64'" Label="PropertySheets">
|
<ImportGroup Condition="'$(Configuration)|$(Platform)'=='release_static_mt|x64'" Label="PropertySheets">
|
||||||
<Import Condition="exists('$(UserRootDir)\Microsoft.Cpp.$(Platform).user.props')" Label="LocalAppDataPlatform" Project="$(UserRootDir)\Microsoft.Cpp.$(Platform).user.props"/>
|
<Import Condition="exists('$(UserRootDir)\Microsoft.Cpp.$(Platform).user.props')" Label="LocalAppDataPlatform" Project="$(UserRootDir)\Microsoft.Cpp.$(Platform).user.props" />
|
||||||
</ImportGroup>
|
</ImportGroup>
|
||||||
<ImportGroup Condition="'$(Configuration)|$(Platform)'=='debug_static_mt|x64'" Label="PropertySheets">
|
<ImportGroup Condition="'$(Configuration)|$(Platform)'=='debug_static_mt|x64'" Label="PropertySheets">
|
||||||
<Import Condition="exists('$(UserRootDir)\Microsoft.Cpp.$(Platform).user.props')" Label="LocalAppDataPlatform" Project="$(UserRootDir)\Microsoft.Cpp.$(Platform).user.props"/>
|
<Import Condition="exists('$(UserRootDir)\Microsoft.Cpp.$(Platform).user.props')" Label="LocalAppDataPlatform" Project="$(UserRootDir)\Microsoft.Cpp.$(Platform).user.props" />
|
||||||
</ImportGroup>
|
</ImportGroup>
|
||||||
<ImportGroup Condition="'$(Configuration)|$(Platform)'=='release_shared|x64'" Label="PropertySheets">
|
<ImportGroup Condition="'$(Configuration)|$(Platform)'=='release_shared|x64'" Label="PropertySheets">
|
||||||
<Import Condition="exists('$(UserRootDir)\Microsoft.Cpp.$(Platform).user.props')" Label="LocalAppDataPlatform" Project="$(UserRootDir)\Microsoft.Cpp.$(Platform).user.props"/>
|
<Import Condition="exists('$(UserRootDir)\Microsoft.Cpp.$(Platform).user.props')" Label="LocalAppDataPlatform" Project="$(UserRootDir)\Microsoft.Cpp.$(Platform).user.props" />
|
||||||
</ImportGroup>
|
</ImportGroup>
|
||||||
<ImportGroup Condition="'$(Configuration)|$(Platform)'=='debug_shared|x64'" Label="PropertySheets">
|
<ImportGroup Condition="'$(Configuration)|$(Platform)'=='debug_shared|x64'" Label="PropertySheets">
|
||||||
<Import Condition="exists('$(UserRootDir)\Microsoft.Cpp.$(Platform).user.props')" Label="LocalAppDataPlatform" Project="$(UserRootDir)\Microsoft.Cpp.$(Platform).user.props"/>
|
<Import Condition="exists('$(UserRootDir)\Microsoft.Cpp.$(Platform).user.props')" Label="LocalAppDataPlatform" Project="$(UserRootDir)\Microsoft.Cpp.$(Platform).user.props" />
|
||||||
</ImportGroup>
|
</ImportGroup>
|
||||||
<PropertyGroup Label="UserMacros"/>
|
<PropertyGroup Label="UserMacros" />
|
||||||
<PropertyGroup>
|
<PropertyGroup>
|
||||||
<_ProjectFileVersion>12.0.30501.0</_ProjectFileVersion>
|
<_ProjectFileVersion>12.0.30501.0</_ProjectFileVersion>
|
||||||
<TargetName Condition="'$(Configuration)|$(Platform)'=='debug_shared|x64'">TestSuited</TargetName>
|
<TargetName Condition="'$(Configuration)|$(Platform)'=='debug_shared|x64'">TestSuited</TargetName>
|
||||||
@ -136,7 +136,7 @@
|
|||||||
<TreatWChar_tAsBuiltInType>true</TreatWChar_tAsBuiltInType>
|
<TreatWChar_tAsBuiltInType>true</TreatWChar_tAsBuiltInType>
|
||||||
<ForceConformanceInForLoopScope>true</ForceConformanceInForLoopScope>
|
<ForceConformanceInForLoopScope>true</ForceConformanceInForLoopScope>
|
||||||
<RuntimeTypeInfo>true</RuntimeTypeInfo>
|
<RuntimeTypeInfo>true</RuntimeTypeInfo>
|
||||||
<PrecompiledHeader/>
|
<PrecompiledHeader />
|
||||||
<WarningLevel>Level3</WarningLevel>
|
<WarningLevel>Level3</WarningLevel>
|
||||||
<DebugInformationFormat>ProgramDatabase</DebugInformationFormat>
|
<DebugInformationFormat>ProgramDatabase</DebugInformationFormat>
|
||||||
<CompileAs>Default</CompileAs>
|
<CompileAs>Default</CompileAs>
|
||||||
@ -167,9 +167,9 @@
|
|||||||
<TreatWChar_tAsBuiltInType>true</TreatWChar_tAsBuiltInType>
|
<TreatWChar_tAsBuiltInType>true</TreatWChar_tAsBuiltInType>
|
||||||
<ForceConformanceInForLoopScope>true</ForceConformanceInForLoopScope>
|
<ForceConformanceInForLoopScope>true</ForceConformanceInForLoopScope>
|
||||||
<RuntimeTypeInfo>true</RuntimeTypeInfo>
|
<RuntimeTypeInfo>true</RuntimeTypeInfo>
|
||||||
<PrecompiledHeader/>
|
<PrecompiledHeader />
|
||||||
<WarningLevel>Level3</WarningLevel>
|
<WarningLevel>Level3</WarningLevel>
|
||||||
<DebugInformationFormat/>
|
<DebugInformationFormat />
|
||||||
<CompileAs>Default</CompileAs>
|
<CompileAs>Default</CompileAs>
|
||||||
</ClCompile>
|
</ClCompile>
|
||||||
<Link>
|
<Link>
|
||||||
@ -196,7 +196,7 @@
|
|||||||
<TreatWChar_tAsBuiltInType>true</TreatWChar_tAsBuiltInType>
|
<TreatWChar_tAsBuiltInType>true</TreatWChar_tAsBuiltInType>
|
||||||
<ForceConformanceInForLoopScope>true</ForceConformanceInForLoopScope>
|
<ForceConformanceInForLoopScope>true</ForceConformanceInForLoopScope>
|
||||||
<RuntimeTypeInfo>true</RuntimeTypeInfo>
|
<RuntimeTypeInfo>true</RuntimeTypeInfo>
|
||||||
<PrecompiledHeader/>
|
<PrecompiledHeader />
|
||||||
<WarningLevel>Level3</WarningLevel>
|
<WarningLevel>Level3</WarningLevel>
|
||||||
<DebugInformationFormat>ProgramDatabase</DebugInformationFormat>
|
<DebugInformationFormat>ProgramDatabase</DebugInformationFormat>
|
||||||
<CompileAs>Default</CompileAs>
|
<CompileAs>Default</CompileAs>
|
||||||
@ -227,9 +227,9 @@
|
|||||||
<TreatWChar_tAsBuiltInType>true</TreatWChar_tAsBuiltInType>
|
<TreatWChar_tAsBuiltInType>true</TreatWChar_tAsBuiltInType>
|
||||||
<ForceConformanceInForLoopScope>true</ForceConformanceInForLoopScope>
|
<ForceConformanceInForLoopScope>true</ForceConformanceInForLoopScope>
|
||||||
<RuntimeTypeInfo>true</RuntimeTypeInfo>
|
<RuntimeTypeInfo>true</RuntimeTypeInfo>
|
||||||
<PrecompiledHeader/>
|
<PrecompiledHeader />
|
||||||
<WarningLevel>Level3</WarningLevel>
|
<WarningLevel>Level3</WarningLevel>
|
||||||
<DebugInformationFormat/>
|
<DebugInformationFormat />
|
||||||
<CompileAs>Default</CompileAs>
|
<CompileAs>Default</CompileAs>
|
||||||
</ClCompile>
|
</ClCompile>
|
||||||
<Link>
|
<Link>
|
||||||
@ -256,7 +256,7 @@
|
|||||||
<TreatWChar_tAsBuiltInType>true</TreatWChar_tAsBuiltInType>
|
<TreatWChar_tAsBuiltInType>true</TreatWChar_tAsBuiltInType>
|
||||||
<ForceConformanceInForLoopScope>true</ForceConformanceInForLoopScope>
|
<ForceConformanceInForLoopScope>true</ForceConformanceInForLoopScope>
|
||||||
<RuntimeTypeInfo>true</RuntimeTypeInfo>
|
<RuntimeTypeInfo>true</RuntimeTypeInfo>
|
||||||
<PrecompiledHeader/>
|
<PrecompiledHeader />
|
||||||
<WarningLevel>Level3</WarningLevel>
|
<WarningLevel>Level3</WarningLevel>
|
||||||
<DebugInformationFormat>ProgramDatabase</DebugInformationFormat>
|
<DebugInformationFormat>ProgramDatabase</DebugInformationFormat>
|
||||||
<CompileAs>Default</CompileAs>
|
<CompileAs>Default</CompileAs>
|
||||||
@ -287,9 +287,9 @@
|
|||||||
<TreatWChar_tAsBuiltInType>true</TreatWChar_tAsBuiltInType>
|
<TreatWChar_tAsBuiltInType>true</TreatWChar_tAsBuiltInType>
|
||||||
<ForceConformanceInForLoopScope>true</ForceConformanceInForLoopScope>
|
<ForceConformanceInForLoopScope>true</ForceConformanceInForLoopScope>
|
||||||
<RuntimeTypeInfo>true</RuntimeTypeInfo>
|
<RuntimeTypeInfo>true</RuntimeTypeInfo>
|
||||||
<PrecompiledHeader/>
|
<PrecompiledHeader />
|
||||||
<WarningLevel>Level3</WarningLevel>
|
<WarningLevel>Level3</WarningLevel>
|
||||||
<DebugInformationFormat/>
|
<DebugInformationFormat />
|
||||||
<CompileAs>Default</CompileAs>
|
<CompileAs>Default</CompileAs>
|
||||||
</ClCompile>
|
</ClCompile>
|
||||||
<Link>
|
<Link>
|
||||||
@ -304,28 +304,32 @@
|
|||||||
</Link>
|
</Link>
|
||||||
</ItemDefinitionGroup>
|
</ItemDefinitionGroup>
|
||||||
<ItemGroup>
|
<ItemGroup>
|
||||||
<ClInclude Include="src\HTTPSClientSessionTest.h"/>
|
<ClInclude Include="src\HTTPSClientSessionTest.h" />
|
||||||
<ClInclude Include="src\HTTPSClientTestSuite.h"/>
|
<ClInclude Include="src\HTTPSClientTestSuite.h" />
|
||||||
<ClInclude Include="src\HTTPSServerTest.h"/>
|
<ClInclude Include="src\HTTPSServerTest.h" />
|
||||||
<ClInclude Include="src\HTTPSServerTestSuite.h"/>
|
<ClInclude Include="src\HTTPSServerTestSuite.h" />
|
||||||
<ClInclude Include="src\HTTPSStreamFactoryTest.h"/>
|
<ClInclude Include="src\HTTPSStreamFactoryTest.h" />
|
||||||
<ClInclude Include="src\HTTPSTestServer.h"/>
|
<ClInclude Include="src\HTTPSTestServer.h" />
|
||||||
<ClInclude Include="src\NetSSLTestSuite.h"/>
|
<ClInclude Include="src\NetSSLTestSuite.h" />
|
||||||
<ClInclude Include="src\TCPServerTest.h"/>
|
<ClInclude Include="src\TCPServerTest.h" />
|
||||||
<ClInclude Include="src\TCPServerTestSuite.h"/>
|
<ClInclude Include="src\TCPServerTestSuite.h" />
|
||||||
|
<ClInclude Include="src\WebSocketTest.h" />
|
||||||
|
<ClInclude Include="src\WebSocketTestSuite.h" />
|
||||||
</ItemGroup>
|
</ItemGroup>
|
||||||
<ItemGroup>
|
<ItemGroup>
|
||||||
<ClCompile Include="src\Driver.cpp"/>
|
<ClCompile Include="src\Driver.cpp" />
|
||||||
<ClCompile Include="src\HTTPSClientSessionTest.cpp"/>
|
<ClCompile Include="src\HTTPSClientSessionTest.cpp" />
|
||||||
<ClCompile Include="src\HTTPSClientTestSuite.cpp"/>
|
<ClCompile Include="src\HTTPSClientTestSuite.cpp" />
|
||||||
<ClCompile Include="src\HTTPSServerTest.cpp"/>
|
<ClCompile Include="src\HTTPSServerTest.cpp" />
|
||||||
<ClCompile Include="src\HTTPSServerTestSuite.cpp"/>
|
<ClCompile Include="src\HTTPSServerTestSuite.cpp" />
|
||||||
<ClCompile Include="src\HTTPSStreamFactoryTest.cpp"/>
|
<ClCompile Include="src\HTTPSStreamFactoryTest.cpp" />
|
||||||
<ClCompile Include="src\HTTPSTestServer.cpp"/>
|
<ClCompile Include="src\HTTPSTestServer.cpp" />
|
||||||
<ClCompile Include="src\NetSSLTestSuite.cpp"/>
|
<ClCompile Include="src\NetSSLTestSuite.cpp" />
|
||||||
<ClCompile Include="src\TCPServerTest.cpp"/>
|
<ClCompile Include="src\TCPServerTest.cpp" />
|
||||||
<ClCompile Include="src\TCPServerTestSuite.cpp"/>
|
<ClCompile Include="src\TCPServerTestSuite.cpp" />
|
||||||
|
<ClCompile Include="src\WebSocketTest.cpp" />
|
||||||
|
<ClCompile Include="src\WebSocketTestSuite.cpp" />
|
||||||
</ItemGroup>
|
</ItemGroup>
|
||||||
<Import Project="$(VCTargetsPath)\Microsoft.Cpp.targets"/>
|
<Import Project="$(VCTargetsPath)\Microsoft.Cpp.targets" />
|
||||||
<ImportGroup Label="ExtensionTargets"/>
|
<ImportGroup Label="ExtensionTargets" />
|
||||||
</Project>
|
</Project>
|
@ -52,6 +52,9 @@
|
|||||||
<Filter Include="HTTPSClient\Source Files">
|
<Filter Include="HTTPSClient\Source Files">
|
||||||
<UniqueIdentifier>{363ebde9-9367-44b7-aa1b-dcb421bb759c}</UniqueIdentifier>
|
<UniqueIdentifier>{363ebde9-9367-44b7-aa1b-dcb421bb759c}</UniqueIdentifier>
|
||||||
</Filter>
|
</Filter>
|
||||||
|
<Filter Include="WebSocket">
|
||||||
|
<UniqueIdentifier>{14c12fc4-d7e0-4311-a59e-f499f1993c3b}</UniqueIdentifier>
|
||||||
|
</Filter>
|
||||||
</ItemGroup>
|
</ItemGroup>
|
||||||
<ItemGroup>
|
<ItemGroup>
|
||||||
<ClInclude Include="src\HTTPSTestServer.h">
|
<ClInclude Include="src\HTTPSTestServer.h">
|
||||||
@ -81,6 +84,12 @@
|
|||||||
<ClInclude Include="src\HTTPSStreamFactoryTest.h">
|
<ClInclude Include="src\HTTPSStreamFactoryTest.h">
|
||||||
<Filter>HTTPSClient\Header Files</Filter>
|
<Filter>HTTPSClient\Header Files</Filter>
|
||||||
</ClInclude>
|
</ClInclude>
|
||||||
|
<ClInclude Include="src\WebSocketTest.h">
|
||||||
|
<Filter>WebSocket</Filter>
|
||||||
|
</ClInclude>
|
||||||
|
<ClInclude Include="src\WebSocketTestSuite.h">
|
||||||
|
<Filter>WebSocket</Filter>
|
||||||
|
</ClInclude>
|
||||||
</ItemGroup>
|
</ItemGroup>
|
||||||
<ItemGroup>
|
<ItemGroup>
|
||||||
<ClCompile Include="src\HTTPSTestServer.cpp">
|
<ClCompile Include="src\HTTPSTestServer.cpp">
|
||||||
@ -113,5 +122,11 @@
|
|||||||
<ClCompile Include="src\HTTPSStreamFactoryTest.cpp">
|
<ClCompile Include="src\HTTPSStreamFactoryTest.cpp">
|
||||||
<Filter>HTTPSClient\Source Files</Filter>
|
<Filter>HTTPSClient\Source Files</Filter>
|
||||||
</ClCompile>
|
</ClCompile>
|
||||||
|
<ClCompile Include="src\WebSocketTest.cpp">
|
||||||
|
<Filter>WebSocket</Filter>
|
||||||
|
</ClCompile>
|
||||||
|
<ClCompile Include="src\WebSocketTestSuite.cpp">
|
||||||
|
<Filter>WebSocket</Filter>
|
||||||
|
</ClCompile>
|
||||||
</ItemGroup>
|
</ItemGroup>
|
||||||
</Project>
|
</Project>
|
@ -313,6 +313,8 @@
|
|||||||
<ClInclude Include="src\NetSSLTestSuite.h"/>
|
<ClInclude Include="src\NetSSLTestSuite.h"/>
|
||||||
<ClInclude Include="src\TCPServerTest.h"/>
|
<ClInclude Include="src\TCPServerTest.h"/>
|
||||||
<ClInclude Include="src\TCPServerTestSuite.h"/>
|
<ClInclude Include="src\TCPServerTestSuite.h"/>
|
||||||
|
<ClInclude Include="src\WebSocketTest.h" />
|
||||||
|
<ClInclude Include="src\WebSocketTestSuite.h" />
|
||||||
</ItemGroup>
|
</ItemGroup>
|
||||||
<ItemGroup>
|
<ItemGroup>
|
||||||
<ClCompile Include="src\Driver.cpp"/>
|
<ClCompile Include="src\Driver.cpp"/>
|
||||||
@ -325,6 +327,8 @@
|
|||||||
<ClCompile Include="src\NetSSLTestSuite.cpp"/>
|
<ClCompile Include="src\NetSSLTestSuite.cpp"/>
|
||||||
<ClCompile Include="src\TCPServerTest.cpp"/>
|
<ClCompile Include="src\TCPServerTest.cpp"/>
|
||||||
<ClCompile Include="src\TCPServerTestSuite.cpp"/>
|
<ClCompile Include="src\TCPServerTestSuite.cpp"/>
|
||||||
|
<ClCompile Include="src\WebSocketTest.cpp" />
|
||||||
|
<ClCompile Include="src\WebSocketTestSuite.cpp" />
|
||||||
</ItemGroup>
|
</ItemGroup>
|
||||||
<Import Project="$(VCTargetsPath)\Microsoft.Cpp.targets"/>
|
<Import Project="$(VCTargetsPath)\Microsoft.Cpp.targets"/>
|
||||||
<ImportGroup Label="ExtensionTargets"/>
|
<ImportGroup Label="ExtensionTargets"/>
|
||||||
|
@ -532,6 +532,23 @@
|
|||||||
RelativePath=".\src\HTTPSStreamFactoryTest.cpp"/>
|
RelativePath=".\src\HTTPSStreamFactoryTest.cpp"/>
|
||||||
</Filter>
|
</Filter>
|
||||||
</Filter>
|
</Filter>
|
||||||
|
<Filter
|
||||||
|
Name="WebSocket">
|
||||||
|
<Filter
|
||||||
|
Name="Header Files">
|
||||||
|
<File
|
||||||
|
RelativePath=".\src\WebSocketTest.h"/>
|
||||||
|
<File
|
||||||
|
RelativePath=".\src\WebSocketTestSuite.h"/>
|
||||||
|
</Filter>
|
||||||
|
<Filter
|
||||||
|
Name="Source Files">
|
||||||
|
<File
|
||||||
|
RelativePath=".\src\WebSocketTest.cpp"/>
|
||||||
|
<File
|
||||||
|
RelativePath=".\src\WebSocketTestSuite.cpp"/>
|
||||||
|
</Filter>
|
||||||
|
</Filter>
|
||||||
</Files>
|
</Files>
|
||||||
<Globals/>
|
<Globals/>
|
||||||
</VisualStudioProject>
|
</VisualStudioProject>
|
||||||
|
@ -15,6 +15,7 @@
|
|||||||
#include "HTTPSClientTestSuite.h"
|
#include "HTTPSClientTestSuite.h"
|
||||||
#include "TCPServerTestSuite.h"
|
#include "TCPServerTestSuite.h"
|
||||||
#include "HTTPSServerTestSuite.h"
|
#include "HTTPSServerTestSuite.h"
|
||||||
|
#include "WebSocketTestSuite.h"
|
||||||
|
|
||||||
|
|
||||||
CppUnit::Test* NetSSLTestSuite::suite()
|
CppUnit::Test* NetSSLTestSuite::suite()
|
||||||
@ -24,6 +25,7 @@ CppUnit::Test* NetSSLTestSuite::suite()
|
|||||||
pSuite->addTest(HTTPSClientTestSuite::suite());
|
pSuite->addTest(HTTPSClientTestSuite::suite());
|
||||||
pSuite->addTest(TCPServerTestSuite::suite());
|
pSuite->addTest(TCPServerTestSuite::suite());
|
||||||
pSuite->addTest(HTTPSServerTestSuite::suite());
|
pSuite->addTest(HTTPSServerTestSuite::suite());
|
||||||
|
pSuite->addTest(WebSocketTestSuite::suite());
|
||||||
|
|
||||||
return pSuite;
|
return pSuite;
|
||||||
}
|
}
|
||||||
|
231
NetSSL_Win/testsuite/src/WebSocketTest.cpp
Normal file
231
NetSSL_Win/testsuite/src/WebSocketTest.cpp
Normal file
@ -0,0 +1,231 @@
|
|||||||
|
//
|
||||||
|
// WebSocketTest.cpp
|
||||||
|
//
|
||||||
|
// $Id: //poco/1.4/Net/testsuite/src/WebSocketTest.cpp#3 $
|
||||||
|
//
|
||||||
|
// Copyright (c) 2012, Applied Informatics Software Engineering GmbH.
|
||||||
|
// and Contributors.
|
||||||
|
//
|
||||||
|
// SPDX-License-Identifier: BSL-1.0
|
||||||
|
//
|
||||||
|
|
||||||
|
|
||||||
|
#include "WebSocketTest.h"
|
||||||
|
#include "CppUnit/TestCaller.h"
|
||||||
|
#include "CppUnit/TestSuite.h"
|
||||||
|
#include "Poco/Net/WebSocket.h"
|
||||||
|
#include "Poco/Net/SocketStream.h"
|
||||||
|
#include "Poco/Net/HTTPSClientSession.h"
|
||||||
|
#include "Poco/Net/HTTPServer.h"
|
||||||
|
#include "Poco/Net/HTTPServerParams.h"
|
||||||
|
#include "Poco/Net/HTTPRequestHandler.h"
|
||||||
|
#include "Poco/Net/HTTPRequestHandlerFactory.h"
|
||||||
|
#include "Poco/Net/HTTPServerRequest.h"
|
||||||
|
#include "Poco/Net/HTTPServerResponse.h"
|
||||||
|
#include "Poco/Net/SecureServerSocket.h"
|
||||||
|
#include "Poco/Net/NetException.h"
|
||||||
|
#include "Poco/Thread.h"
|
||||||
|
|
||||||
|
|
||||||
|
using Poco::Net::HTTPSClientSession;
|
||||||
|
using Poco::Net::HTTPRequest;
|
||||||
|
using Poco::Net::HTTPResponse;
|
||||||
|
using Poco::Net::HTTPServerRequest;
|
||||||
|
using Poco::Net::HTTPServerResponse;
|
||||||
|
using Poco::Net::SocketStream;
|
||||||
|
using Poco::Net::WebSocket;
|
||||||
|
using Poco::Net::WebSocketException;
|
||||||
|
|
||||||
|
|
||||||
|
namespace
|
||||||
|
{
|
||||||
|
class WebSocketRequestHandler: public Poco::Net::HTTPRequestHandler
|
||||||
|
{
|
||||||
|
public:
|
||||||
|
WebSocketRequestHandler(std::size_t bufSize = 1024): _bufSize(bufSize)
|
||||||
|
{
|
||||||
|
}
|
||||||
|
|
||||||
|
void handleRequest(HTTPServerRequest& request, HTTPServerResponse& response)
|
||||||
|
{
|
||||||
|
try
|
||||||
|
{
|
||||||
|
WebSocket ws(request, response);
|
||||||
|
std::auto_ptr<char> pBuffer(new char[_bufSize]);
|
||||||
|
int flags;
|
||||||
|
int n;
|
||||||
|
do
|
||||||
|
{
|
||||||
|
n = ws.receiveFrame(pBuffer.get(), _bufSize, flags);
|
||||||
|
ws.sendFrame(pBuffer.get(), n, flags);
|
||||||
|
}
|
||||||
|
while (n > 0 || (flags & WebSocket::FRAME_OP_BITMASK) != WebSocket::FRAME_OP_CLOSE);
|
||||||
|
}
|
||||||
|
catch (WebSocketException& exc)
|
||||||
|
{
|
||||||
|
switch (exc.code())
|
||||||
|
{
|
||||||
|
case WebSocket::WS_ERR_HANDSHAKE_UNSUPPORTED_VERSION:
|
||||||
|
response.set("Sec-WebSocket-Version", WebSocket::WEBSOCKET_VERSION);
|
||||||
|
// fallthrough
|
||||||
|
case WebSocket::WS_ERR_NO_HANDSHAKE:
|
||||||
|
case WebSocket::WS_ERR_HANDSHAKE_NO_VERSION:
|
||||||
|
case WebSocket::WS_ERR_HANDSHAKE_NO_KEY:
|
||||||
|
response.setStatusAndReason(HTTPResponse::HTTP_BAD_REQUEST);
|
||||||
|
response.setContentLength(0);
|
||||||
|
response.send();
|
||||||
|
break;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
private:
|
||||||
|
std::size_t _bufSize;
|
||||||
|
};
|
||||||
|
|
||||||
|
class WebSocketRequestHandlerFactory: public Poco::Net::HTTPRequestHandlerFactory
|
||||||
|
{
|
||||||
|
public:
|
||||||
|
WebSocketRequestHandlerFactory(std::size_t bufSize = 1024): _bufSize(bufSize)
|
||||||
|
{
|
||||||
|
}
|
||||||
|
|
||||||
|
Poco::Net::HTTPRequestHandler* createRequestHandler(const HTTPServerRequest& request)
|
||||||
|
{
|
||||||
|
return new WebSocketRequestHandler(_bufSize);
|
||||||
|
}
|
||||||
|
|
||||||
|
private:
|
||||||
|
std::size_t _bufSize;
|
||||||
|
};
|
||||||
|
}
|
||||||
|
|
||||||
|
|
||||||
|
WebSocketTest::WebSocketTest(const std::string& name): CppUnit::TestCase(name)
|
||||||
|
{
|
||||||
|
}
|
||||||
|
|
||||||
|
|
||||||
|
WebSocketTest::~WebSocketTest()
|
||||||
|
{
|
||||||
|
}
|
||||||
|
|
||||||
|
|
||||||
|
void WebSocketTest::testWebSocket()
|
||||||
|
{
|
||||||
|
Poco::Net::SecureServerSocket ss(0);
|
||||||
|
Poco::Net::HTTPServer server(new WebSocketRequestHandlerFactory, ss, new Poco::Net::HTTPServerParams);
|
||||||
|
server.start();
|
||||||
|
|
||||||
|
Poco::Thread::sleep(200);
|
||||||
|
|
||||||
|
HTTPSClientSession cs("localhost", ss.address().port());
|
||||||
|
HTTPRequest request(HTTPRequest::HTTP_GET, "/ws");
|
||||||
|
HTTPResponse response;
|
||||||
|
WebSocket ws(cs, request, response);
|
||||||
|
|
||||||
|
std::string payload("x");
|
||||||
|
ws.sendFrame(payload.data(), (int) payload.size());
|
||||||
|
char buffer[1024];
|
||||||
|
int flags;
|
||||||
|
int n = ws.receiveFrame(buffer, sizeof(buffer), flags);
|
||||||
|
assert (n == payload.size());
|
||||||
|
assert (payload.compare(0, payload.size(), buffer, 0, n) == 0);
|
||||||
|
assert (flags == WebSocket::FRAME_TEXT);
|
||||||
|
|
||||||
|
for (int i = 2; i < 20; i++)
|
||||||
|
{
|
||||||
|
payload.assign(i, 'x');
|
||||||
|
ws.sendFrame(payload.data(), (int) payload.size());
|
||||||
|
n = ws.receiveFrame(buffer, sizeof(buffer), flags);
|
||||||
|
assert (n == payload.size());
|
||||||
|
assert (payload.compare(0, payload.size(), buffer, 0, n) == 0);
|
||||||
|
assert (flags == WebSocket::FRAME_TEXT);
|
||||||
|
}
|
||||||
|
|
||||||
|
for (int i = 125; i < 129; i++)
|
||||||
|
{
|
||||||
|
payload.assign(i, 'x');
|
||||||
|
ws.sendFrame(payload.data(), (int) payload.size());
|
||||||
|
n = ws.receiveFrame(buffer, sizeof(buffer), flags);
|
||||||
|
assert (n == payload.size());
|
||||||
|
assert (payload.compare(0, payload.size(), buffer, 0, n) == 0);
|
||||||
|
assert (flags == WebSocket::FRAME_TEXT);
|
||||||
|
}
|
||||||
|
|
||||||
|
payload = "Hello, world!";
|
||||||
|
ws.sendFrame(payload.data(), (int) payload.size());
|
||||||
|
n = ws.receiveFrame(buffer, sizeof(buffer), flags);
|
||||||
|
assert (n == payload.size());
|
||||||
|
assert (payload.compare(0, payload.size(), buffer, 0, n) == 0);
|
||||||
|
assert (flags == WebSocket::FRAME_TEXT);
|
||||||
|
|
||||||
|
payload = "Hello, universe!";
|
||||||
|
ws.sendFrame(payload.data(), (int) payload.size(), WebSocket::FRAME_BINARY);
|
||||||
|
n = ws.receiveFrame(buffer, sizeof(buffer), flags);
|
||||||
|
assert (n == payload.size());
|
||||||
|
assert (payload.compare(0, payload.size(), buffer, 0, n) == 0);
|
||||||
|
assert (flags == WebSocket::FRAME_BINARY);
|
||||||
|
|
||||||
|
ws.shutdown();
|
||||||
|
n = ws.receiveFrame(buffer, sizeof(buffer), flags);
|
||||||
|
assert (n == 2);
|
||||||
|
assert ((flags & WebSocket::FRAME_OP_BITMASK) == WebSocket::FRAME_OP_CLOSE);
|
||||||
|
|
||||||
|
server.stop();
|
||||||
|
}
|
||||||
|
|
||||||
|
|
||||||
|
void WebSocketTest::testWebSocketLarge()
|
||||||
|
{
|
||||||
|
const int msgSize = 64000;
|
||||||
|
|
||||||
|
Poco::Net::SecureServerSocket ss(0);
|
||||||
|
Poco::Net::HTTPServer server(new WebSocketRequestHandlerFactory(msgSize), ss, new Poco::Net::HTTPServerParams);
|
||||||
|
server.start();
|
||||||
|
|
||||||
|
Poco::Thread::sleep(200);
|
||||||
|
|
||||||
|
HTTPSClientSession cs("localhost", ss.address().port());
|
||||||
|
HTTPRequest request(HTTPRequest::HTTP_GET, "/ws");
|
||||||
|
HTTPResponse response;
|
||||||
|
WebSocket ws(cs, request, response);
|
||||||
|
ws.setSendBufferSize(msgSize);
|
||||||
|
ws.setReceiveBufferSize(msgSize);
|
||||||
|
std::string payload(msgSize, 'x');
|
||||||
|
SocketStream sstr(ws);
|
||||||
|
sstr << payload;
|
||||||
|
sstr.flush();
|
||||||
|
|
||||||
|
char buffer[msgSize + 1];
|
||||||
|
int flags;
|
||||||
|
int n = 0;
|
||||||
|
do
|
||||||
|
{
|
||||||
|
n += ws.receiveFrame(buffer + n, sizeof(buffer) - n, flags);
|
||||||
|
} while (n > 0 && n < msgSize);
|
||||||
|
|
||||||
|
assert (n == payload.size());
|
||||||
|
assert (payload.compare(0, payload.size(), buffer, 0, n) == 0);
|
||||||
|
}
|
||||||
|
|
||||||
|
|
||||||
|
void WebSocketTest::setUp()
|
||||||
|
{
|
||||||
|
}
|
||||||
|
|
||||||
|
|
||||||
|
void WebSocketTest::tearDown()
|
||||||
|
{
|
||||||
|
}
|
||||||
|
|
||||||
|
|
||||||
|
CppUnit::Test* WebSocketTest::suite()
|
||||||
|
{
|
||||||
|
CppUnit::TestSuite* pSuite = new CppUnit::TestSuite("WebSocketTest");
|
||||||
|
|
||||||
|
CppUnit_addTest(pSuite, WebSocketTest, testWebSocket);
|
||||||
|
CppUnit_addTest(pSuite, WebSocketTest, testWebSocketLarge);
|
||||||
|
|
||||||
|
return pSuite;
|
||||||
|
}
|
41
NetSSL_Win/testsuite/src/WebSocketTest.h
Normal file
41
NetSSL_Win/testsuite/src/WebSocketTest.h
Normal file
@ -0,0 +1,41 @@
|
|||||||
|
//
|
||||||
|
// WebSocketTest.h
|
||||||
|
//
|
||||||
|
// $Id: //poco/1.4/Net/testsuite/src/WebSocketTest.h#1 $
|
||||||
|
//
|
||||||
|
// Definition of the WebSocketTest class.
|
||||||
|
//
|
||||||
|
// Copyright (c) 2012, Applied Informatics Software Engineering GmbH.
|
||||||
|
// and Contributors.
|
||||||
|
//
|
||||||
|
// SPDX-License-Identifier: BSL-1.0
|
||||||
|
//
|
||||||
|
|
||||||
|
|
||||||
|
#ifndef WebSocketTest_INCLUDED
|
||||||
|
#define WebSocketTest_INCLUDED
|
||||||
|
|
||||||
|
|
||||||
|
#include "Poco/Net/Net.h"
|
||||||
|
#include "CppUnit/TestCase.h"
|
||||||
|
|
||||||
|
|
||||||
|
class WebSocketTest: public CppUnit::TestCase
|
||||||
|
{
|
||||||
|
public:
|
||||||
|
WebSocketTest(const std::string& name);
|
||||||
|
~WebSocketTest();
|
||||||
|
|
||||||
|
void testWebSocket();
|
||||||
|
void testWebSocketLarge();
|
||||||
|
|
||||||
|
void setUp();
|
||||||
|
void tearDown();
|
||||||
|
|
||||||
|
static CppUnit::Test* suite();
|
||||||
|
|
||||||
|
private:
|
||||||
|
};
|
||||||
|
|
||||||
|
|
||||||
|
#endif // WebSocketTest_INCLUDED
|
24
NetSSL_Win/testsuite/src/WebSocketTestSuite.cpp
Normal file
24
NetSSL_Win/testsuite/src/WebSocketTestSuite.cpp
Normal file
@ -0,0 +1,24 @@
|
|||||||
|
//
|
||||||
|
// WebSocketTestSuite.cpp
|
||||||
|
//
|
||||||
|
// $Id: //poco/1.4/Net/testsuite/src/WebSocketTestSuite.cpp#1 $
|
||||||
|
//
|
||||||
|
// Copyright (c) 2012, Applied Informatics Software Engineering GmbH.
|
||||||
|
// and Contributors.
|
||||||
|
//
|
||||||
|
// SPDX-License-Identifier: BSL-1.0
|
||||||
|
//
|
||||||
|
|
||||||
|
|
||||||
|
#include "WebSocketTestSuite.h"
|
||||||
|
#include "WebSocketTest.h"
|
||||||
|
|
||||||
|
|
||||||
|
CppUnit::Test* WebSocketTestSuite::suite()
|
||||||
|
{
|
||||||
|
CppUnit::TestSuite* pSuite = new CppUnit::TestSuite("WebSocketTestSuite");
|
||||||
|
|
||||||
|
pSuite->addTest(WebSocketTest::suite());
|
||||||
|
|
||||||
|
return pSuite;
|
||||||
|
}
|
29
NetSSL_Win/testsuite/src/WebSocketTestSuite.h
Normal file
29
NetSSL_Win/testsuite/src/WebSocketTestSuite.h
Normal file
@ -0,0 +1,29 @@
|
|||||||
|
//
|
||||||
|
// WebSocketTestSuite.h
|
||||||
|
//
|
||||||
|
// $Id: //poco/1.4/Net/testsuite/src/WebSocketTestSuite.h#1 $
|
||||||
|
//
|
||||||
|
// Definition of the WebSocketTestSuite class.
|
||||||
|
//
|
||||||
|
// Copyright (c) 2012, Applied Informatics Software Engineering GmbH.
|
||||||
|
// and Contributors.
|
||||||
|
//
|
||||||
|
// SPDX-License-Identifier: BSL-1.0
|
||||||
|
//
|
||||||
|
|
||||||
|
|
||||||
|
#ifndef WebSocketTestSuite_INCLUDED
|
||||||
|
#define WebSocketTestSuite_INCLUDED
|
||||||
|
|
||||||
|
|
||||||
|
#include "CppUnit/TestSuite.h"
|
||||||
|
|
||||||
|
|
||||||
|
class WebSocketTestSuite
|
||||||
|
{
|
||||||
|
public:
|
||||||
|
static CppUnit::Test* suite();
|
||||||
|
};
|
||||||
|
|
||||||
|
|
||||||
|
#endif // WebSocketTestSuite_INCLUDED
|
@ -1,10 +1,3 @@
|
|||||||
//
|
|
||||||
// TimeHandler.cpp
|
|
||||||
//
|
|
||||||
// This file has been generated from TimeHandler.cpsp on 2010-01-28 08:49:54.
|
|
||||||
//
|
|
||||||
|
|
||||||
|
|
||||||
#include "TimeHandler.h"
|
#include "TimeHandler.h"
|
||||||
#include "Poco/Net/HTTPServerRequest.h"
|
#include "Poco/Net/HTTPServerRequest.h"
|
||||||
#include "Poco/Net/HTTPServerResponse.h"
|
#include "Poco/Net/HTTPServerResponse.h"
|
||||||
@ -28,7 +21,7 @@ void TimeHandler::handleRequest(Poco::Net::HTTPServerRequest& request, Poco::Net
|
|||||||
responseStream << "\n";
|
responseStream << "\n";
|
||||||
responseStream << "\n";
|
responseStream << "\n";
|
||||||
responseStream << "";
|
responseStream << "";
|
||||||
#line 6 "/ws/poco-1.3/PageCompiler/samples/HTTPTimeServer/src/TimeHandler.cpsp"
|
#line 6 "/cygdrive/z/git/poco/PageCompiler/samples/HTTPTimeServer/src/TimeHandler.cpsp"
|
||||||
|
|
||||||
Poco::DateTime now;
|
Poco::DateTime now;
|
||||||
std::string dt(Poco::DateTimeFormatter::format(now, "%W, %e %b %y %H:%M:%S %Z"));
|
std::string dt(Poco::DateTimeFormatter::format(now, "%W, %e %b %y %H:%M:%S %Z"));
|
||||||
@ -40,7 +33,7 @@ void TimeHandler::handleRequest(Poco::Net::HTTPServerRequest& request, Poco::Net
|
|||||||
responseStream << "</head>\n";
|
responseStream << "</head>\n";
|
||||||
responseStream << "<body>\n";
|
responseStream << "<body>\n";
|
||||||
responseStream << "<p style=\"text-align: center; font-size: 48px;\">";
|
responseStream << "<p style=\"text-align: center; font-size: 48px;\">";
|
||||||
#line 16 "/ws/poco-1.3/PageCompiler/samples/HTTPTimeServer/src/TimeHandler.cpsp"
|
#line 16 "/cygdrive/z/git/poco/PageCompiler/samples/HTTPTimeServer/src/TimeHandler.cpsp"
|
||||||
responseStream << ( dt );
|
responseStream << ( dt );
|
||||||
responseStream << "</p>\n";
|
responseStream << "</p>\n";
|
||||||
responseStream << "</body>\n";
|
responseStream << "</body>\n";
|
||||||
|
@ -1,10 +1,3 @@
|
|||||||
//
|
|
||||||
// TimeHandler.h
|
|
||||||
//
|
|
||||||
// This file has been generated from TimeHandler.cpsp on 2010-01-28 08:49:54.
|
|
||||||
//
|
|
||||||
|
|
||||||
|
|
||||||
#ifndef TimeHandler_INCLUDED
|
#ifndef TimeHandler_INCLUDED
|
||||||
#define TimeHandler_INCLUDED
|
#define TimeHandler_INCLUDED
|
||||||
|
|
||||||
|
Loading…
x
Reference in New Issue
Block a user