File: test_types.py

package info (click to toggle)
python-uiprotect 6.1.0-2.1
  • links: PTS, VCS
  • area: main
  • in suites: forky, sid
  • size: 2,848 kB
  • sloc: python: 16,451; makefile: 21
file content (11 lines) | stat: -rw-r--r-- 288 bytes parent folder | download
1
2
3
4
5
6
7
8
9
10
11
from __future__ import annotations

import pytest

from uiprotect.data.types import ModelType


@pytest.mark.asyncio()
async def test_model_type_from_string():
    assert ModelType.from_string("camera") is ModelType.CAMERA
    assert ModelType.from_string("invalid") is ModelType.UNKNOWN