Allow tor files to be in /usr/share or /usr/local/share in tests

This commit is contained in:
Micah Lee 2020-08-20 22:37:25 -07:00
parent e68266fe63
commit 9e9dfb86e3
No known key found for this signature in database
GPG Key ID: 403C2657CD994F73

View File

@ -235,8 +235,14 @@ class TestGetTorPaths:
) = common_obj.get_tor_paths()
assert os.path.basename(tor_path) == "tor"
assert tor_geo_ip_file_path == "/usr/share/tor/geoip"
assert tor_geo_ipv6_file_path == "/usr/share/tor/geoip6"
assert (
tor_geo_ip_file_path == "/usr/share/tor/geoip"
or tor_geo_ip_file_path == "/usr/local/share/tor/geoip"
)
assert (
tor_geo_ipv6_file_path == "/usr/share/tor/geoip6"
or tor_geo_ipv6_file_path == "/usr/local/share/tor/geoip6"
)
# @pytest.mark.skipif(sys.platform != 'Windows', reason='requires Windows') ?
def test_get_tor_paths_windows(self, platform_windows, common_obj, sys_frozen):