mirror of
https://github.com/matrix-org/pantalaimon.git
synced 2025-01-21 21:01:00 -05:00
27 lines
640 B
Python
27 lines
640 B
Python
import pytest
|
|
from janus import Queue
|
|
|
|
from conftest import faker
|
|
from pantalaimon.config import ServerConfig
|
|
from pantalaimon.ui import Control, IdCounter
|
|
|
|
|
|
class TestClass(object):
|
|
def test_server_account_storing(self, panstore):
|
|
domain = faker.domain_name()
|
|
|
|
server_list = [
|
|
ServerConfig(
|
|
domain,
|
|
faker.url("http"),
|
|
faker.ipv4(),
|
|
8080,
|
|
)
|
|
]
|
|
|
|
queue = Queue()
|
|
counter = IdCounter()
|
|
control = Control(queue.sync_q, panstore, server_list, counter)
|
|
|
|
assert control.ListServers() == {domain: []}
|