File: test_comm.py

package info (click to toggle)
jupyter-comm 0.2.1-1
  • links: PTS, VCS
  • area: main
  • in suites: forky, sid, trixie
  • size: 116 kB
  • sloc: python: 249; makefile: 2
file content (25 lines) | stat: -rw-r--r-- 471 bytes parent folder | download
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
from typing import Any

from comm.base_comm import BaseComm, CommManager


class MyComm(BaseComm):
    def publish_msg(
        self,
        msg_type: str,
        data: Any = None,
        metadata: Any = None,
        buffers: Any = None,
        **keys: Any,
    ) -> None:
        pass


def test_comm_manager() -> None:
    test = CommManager()
    assert test.targets == {}


def test_base_comm() -> None:
    test = MyComm()
    assert test.target_name == "comm"