smbmc/tests/unit/test_client.py
2020-11-01 05:57:30 +13:00

19 lines
508 B
Python

"""Unit tests for smbmc.Client class."""
import pytest
from smbmc import Client
# TODO stub out request call
client = Client("", "", "")
def test_duplicate_metrics():
"""Check for duplicate metrics."""
with pytest.raises(Exception, match="duplicates"):
assert client.get_metrics(["dupe", "dupe"])
def test_invalid_metrics():
"""Check for invalid metrics."""
with pytest.raises(Exception, match="invalid metric"):
assert client.get_metrics([None, 1, "magic_school_bus"])