Add an 'external_server' controller

This commit is contained in:
2021-08-10 18:15:45 +02:00
committed by Val Lorentz
parent c37ed0f218
commit 42e10c3848
3 changed files with 56 additions and 3 deletions

View File

@ -7,12 +7,13 @@ import socket
import subprocess
import tempfile
import time
from typing import IO, Any, Callable, Dict, List, Optional, Set, Type
from typing import IO, Any, Callable, Dict, List, Optional, Set, Tuple, Type
import irctest
from . import authentication, tls
from .client_mock import ClientMock
from .irc_utils.junkdrawer import find_hostname_and_port
from .irc_utils.message_parser import Message
from .runner import NotImplementedByController
@ -187,6 +188,9 @@ class BaseServerController(_BaseController):
extban_mute_char: Optional[str] = None
"""Character used for the 'mute' extban"""
def get_hostname_and_port(self) -> Tuple[str, int]:
return find_hostname_and_port()
def run(
self,
hostname: str,