def test_list_sock_stat_files(self, mock_get_listener): mock_get_listener.return_value = LISTENER_IDS health_daemon.list_sock_stat_files() files = health_daemon.list_sock_stat_files(BASE_PATH) expected_files = { LISTENER_ID1: BASE_PATH + '/' + LISTENER_ID1 + '.sock', LISTENER_ID2: BASE_PATH + '/' + LISTENER_ID2 + '.sock' } self.assertEqual(files, expected_files)
def test_list_sock_stat_files(self, mock_get_listener): mock_get_listener.return_value = LISTENER_IDS health_daemon.list_sock_stat_files() files = health_daemon.list_sock_stat_files(BASE_PATH) expected_files = {LISTENER_ID1: BASE_PATH + '/' + LISTENER_ID1 + '.sock', LISTENER_ID2: BASE_PATH + '/' + LISTENER_ID2 + '.sock'} self.assertEqual(files, expected_files)