ariadne/tests/test_k8s_manifests.py

17 lines
469 B
Python

from __future__ import annotations
import pytest
from ariadne.k8s.manifests import load_cronjob_manifest
def test_load_cronjob_manifest_ok() -> None:
manifest = load_cronjob_manifest("comms/guest-name-job.yaml")
assert manifest["kind"] == "CronJob"
assert manifest["metadata"]["name"] == "guest-name-randomizer"
def test_load_cronjob_manifest_missing() -> None:
with pytest.raises(FileNotFoundError):
load_cronjob_manifest("missing.yaml")