diff options
| author | feldsherov <[email protected]> | 2022-02-10 16:49:29 +0300 |
|---|---|---|
| committer | Daniil Cherednik <[email protected]> | 2022-02-10 16:49:29 +0300 |
| commit | e73723ec73b27276cd45b9b46b752138a51d669c (patch) | |
| tree | 055f8efa1a290665c7be6bb571131e050cd9517a /library/cpp/http/server/http_ut.cpp | |
| parent | 4d75b7f76712a8150bd526a7ef43d279d9892eb7 (diff) | |
Restoring authorship annotation for <[email protected]>. Commit 1 of 2.
Diffstat (limited to 'library/cpp/http/server/http_ut.cpp')
| -rw-r--r-- | library/cpp/http/server/http_ut.cpp | 74 |
1 files changed, 37 insertions, 37 deletions
diff --git a/library/cpp/http/server/http_ut.cpp b/library/cpp/http/server/http_ut.cpp index cc62bb988e7..16f72df9723 100644 --- a/library/cpp/http/server/http_ut.cpp +++ b/library/cpp/http/server/http_ut.cpp @@ -481,29 +481,29 @@ Y_UNIT_TEST_SUITE(THttpServerTest) { ExceptionMessage = CurrentExceptionMessage(); } - TString ExceptionMessage; - }; - - class TResetConnectionServer: public THttpServer::ICallBack { - class TRequest: public TClientRequest { - public: - bool Reply(void* /*tsr*/) override { - Output() << "HTTP/1.1"; - ResetConnection(); - - return true; - } - }; - + TString ExceptionMessage; + }; + + class TResetConnectionServer: public THttpServer::ICallBack { + class TRequest: public TClientRequest { + public: + bool Reply(void* /*tsr*/) override { + Output() << "HTTP/1.1"; + ResetConnection(); + + return true; + } + }; + public: - TClientRequest* CreateClient() override { - return new TRequest(); - } - - void OnException() override { - ExceptionMessage = CurrentExceptionMessage(); - } - + TClientRequest* CreateClient() override { + return new TRequest(); + } + + void OnException() override { + ExceptionMessage = CurrentExceptionMessage(); + } + TString ExceptionMessage; }; @@ -526,21 +526,21 @@ Y_UNIT_TEST_SUITE(THttpServerTest) { } }; - Y_UNIT_TEST(TTestResetConnection) { - TPortManager pm; - const ui16 port = pm.GetPort(); - - TResetConnectionServer serverImpl; - THttpServer server(&serverImpl, THttpServer::TOptions(port)); - UNIT_ASSERT(server.Start()); - - TTestRequest r(port, "request"); - - UNIT_ASSERT_EXCEPTION_CONTAINS(r.Execute(), TSystemError, "Connection reset by peer"); - - server.Stop(); - }; - + Y_UNIT_TEST(TTestResetConnection) { + TPortManager pm; + const ui16 port = pm.GetPort(); + + TResetConnectionServer serverImpl; + THttpServer server(&serverImpl, THttpServer::TOptions(port)); + UNIT_ASSERT(server.Start()); + + TTestRequest r(port, "request"); + + UNIT_ASSERT_EXCEPTION_CONTAINS(r.Execute(), TSystemError, "Connection reset by peer"); + + server.Stop(); + }; + Y_UNIT_TEST(TTestReleaseConnection) { TPortManager pm; const ui16 port = pm.GetPort(); |
