diff options
| author | maxim-yurchuk <[email protected]> | 2024-10-09 12:29:46 +0300 |
|---|---|---|
| committer | maxim-yurchuk <[email protected]> | 2024-10-09 13:14:22 +0300 |
| commit | 9731d8a4bb7ee2cc8554eaf133bb85498a4c7d80 (patch) | |
| tree | a8fb3181d5947c0d78cf402aa56e686130179049 /contrib/python/websocket-client/py2 | |
| parent | a44b779cd359f06c3ebbef4ec98c6b38609d9d85 (diff) | |
publishFullContrib: true for ydb
<HIDDEN_URL>
commit_hash:c82a80ac4594723cebf2c7387dec9c60217f603e
Diffstat (limited to 'contrib/python/websocket-client/py2')
| -rw-r--r-- | contrib/python/websocket-client/py2/patches/01-fix-tests.patch | 33 |
1 files changed, 33 insertions, 0 deletions
diff --git a/contrib/python/websocket-client/py2/patches/01-fix-tests.patch b/contrib/python/websocket-client/py2/patches/01-fix-tests.patch new file mode 100644 index 00000000000..83acc3d9c6a --- /dev/null +++ b/contrib/python/websocket-client/py2/patches/01-fix-tests.patch @@ -0,0 +1,33 @@ +--- contrib/python/websocket-client/py2/websocket/tests/test_http.py (index) ++++ contrib/python/websocket-client/py2/websocket/tests/test_http.py (working tree) +@@ -66,7 +66,8 @@ class HeaderSockMock(SockMock): + + def __init__(self, fname): + SockMock.__init__(self) +- path = os.path.join(os.path.dirname(__file__), fname) ++ import yatest.common ++ path = yatest.common.source_path(os.path.join('contrib/python/websocket-client/py2/websocket/tests', fname)) + with open(path, "rb") as f: + self.add_packet(f.read()) + +@@ -91,7 +92,7 @@ class HttpTest(unittest.TestCase): + self.assertRaises(ws.WebSocketProxyException, _tunnel, HeaderSockMock("data/header01.txt"), "example.com", 80, ("username", "password")) + self.assertRaises(ws.WebSocketProxyException, _tunnel, HeaderSockMock("data/header02.txt"), "example.com", 80, ("username", "password")) + +- def testConnect(self): ++ def _testConnect(self): + # Not currently testing an actual proxy connection, so just check whether TypeError is raised + self.assertRaises(TypeError, _open_proxied_socket, "wss://example.com", OptsList(), proxy_info(http_proxy_host="example.com", http_proxy_port="8080", proxy_type="http")) + self.assertRaises(TypeError, _open_proxied_socket, "wss://example.com", OptsList(), proxy_info(http_proxy_host="example.com", http_proxy_port="8080", proxy_type="socks4")) +--- contrib/python/websocket-client/py2/websocket/tests/test_websocket.py (index) ++++ contrib/python/websocket-client/py2/websocket/tests/test_websocket.py (working tree) +@@ -99,7 +99,8 @@ class HeaderSockMock(SockMock): + + def __init__(self, fname): + SockMock.__init__(self) +- path = os.path.join(os.path.dirname(__file__), fname) ++ import yatest.common ++ path = yatest.common.source_path(os.path.join('contrib/python/websocket-client/py2/websocket/tests', fname)) + with open(path, "rb") as f: + self.add_packet(f.read()) + |
