Split the wine helper into it's own package.
This commit is contained in:
@@ -5,6 +5,18 @@ from cthulhu.wine_access_manager import PrefixProcess, WineAccessManager
|
||||
|
||||
|
||||
class WineAccessManagerTest(unittest.TestCase):
|
||||
@mock.patch.object(WineAccessManager, "_find_helper", return_value=None)
|
||||
@mock.patch.object(WineAccessManager, "discover_prefixes")
|
||||
def test_poll_without_installed_helper_is_a_no_op(
|
||||
self, discover_prefixes, _find_helper
|
||||
):
|
||||
manager = WineAccessManager(helperPath=None)
|
||||
|
||||
self.assertIsNone(manager.helperPath)
|
||||
self.assertTrue(manager.poll())
|
||||
discover_prefixes.assert_not_called()
|
||||
self.assertEqual(manager.prefixes, {})
|
||||
|
||||
def test_prefix_prefers_explicit_wineprefix(self):
|
||||
environment = {
|
||||
"WINEPREFIX": "/tmp/custom-prefix",
|
||||
|
||||
Reference in New Issue
Block a user