Skip to content

Commit

Permalink
Fix tests for Python 3.6 and 3.7
Browse files Browse the repository at this point in the history
  • Loading branch information
abhinavsingh committed Apr 18, 2024
1 parent 6d0313a commit cda63e4
Show file tree
Hide file tree
Showing 2 changed files with 5 additions and 7 deletions.
5 changes: 1 addition & 4 deletions proxy/proxy.py
Original file line number Diff line number Diff line change
Expand Up @@ -30,7 +30,6 @@
DEFAULT_PID_FILE, DEFAULT_LOG_LEVEL, DEFAULT_BASIC_AUTH,
DEFAULT_LOG_FORMAT, DEFAULT_WORK_KLASS, DEFAULT_OPEN_FILE_LIMIT,
DEFAULT_ENABLE_DASHBOARD, DEFAULT_ENABLE_SSH_TUNNEL,
DEFAULT_DATA_DIRECTORY_PATH,
)


Expand Down Expand Up @@ -150,9 +149,7 @@
'--data-dir',
type=str,
default=None,
help='Default: {0}. Path to proxypy data directory.'.format(
DEFAULT_DATA_DIRECTORY_PATH,
),
help='Default: ~/.proxypy. Path to proxypy data directory.',
)


Expand Down
7 changes: 4 additions & 3 deletions tests/test_main.py
Original file line number Diff line number Diff line change
Expand Up @@ -33,9 +33,9 @@
DEFAULT_ENABLE_SSH_TUNNEL, DEFAULT_ENABLE_WEB_SERVER,
DEFAULT_DISABLE_HTTP_PROXY, PLUGIN_WEBSOCKET_TRANSPORT,
DEFAULT_CA_SIGNING_KEY_FILE, DEFAULT_CLIENT_RECVBUF_SIZE,
DEFAULT_SERVER_RECVBUF_SIZE, DEFAULT_CACHE_DIRECTORY_PATH,
DEFAULT_ENABLE_REVERSE_PROXY, DEFAULT_ENABLE_STATIC_SERVER,
_env_threadless_compliant,
DEFAULT_DATA_DIRECTORY_PATH, DEFAULT_SERVER_RECVBUF_SIZE,
DEFAULT_CACHE_DIRECTORY_PATH, DEFAULT_ENABLE_REVERSE_PROXY,
DEFAULT_ENABLE_STATIC_SERVER, _env_threadless_compliant,
)


Expand Down Expand Up @@ -83,6 +83,7 @@ def mock_default_args(mock_args: mock.Mock) -> None:
mock_args.enable_ssh_tunnel = DEFAULT_ENABLE_SSH_TUNNEL
mock_args.enable_reverse_proxy = DEFAULT_ENABLE_REVERSE_PROXY
mock_args.unix_socket_path = None
mock_args.data_dir = DEFAULT_DATA_DIRECTORY_PATH
mock_args.cache_dir = DEFAULT_CACHE_DIRECTORY_PATH

@mock.patch('os.remove')
Expand Down

0 comments on commit cda63e4

Please sign in to comment.