Files
cozystack/packages/system/cozystack-controller/tests/gpuclass_crd_test.yaml
T
Aleksei Sviridkin 7554abf715 feat(api): add the GPUClass catalog to cozystack.io
GPU offers need stable names for tenant budgets and billing while the
host layer can change its device-plugin resource names. Publish the
offer metadata and a UID-scoped acknowledgement of the underlying resource name,
separate from readiness and from GPU capacity.

Keep immutable offer details on the class, require a profile for vGPU,
and retain the CRD on chart uninstall. The shipped-schema tests exercise
create, update and status preparation through the apiserver strategies,
including malformed fields and status isolation.

Assisted-by: LLM
Signed-off-by: Aleksei Sviridkin <f@lex.la>
2026-11-28 07:07:54 +03:00

25 lines
695 B
YAML

suite: GPUClass CRD
templates:
- templates/crds/crds.yaml
# The chart installs every file in definitions/, so a GPUClass type in
# api/v1alpha1 ships with no template of its own.
tests:
- it: installs the cluster-scoped GPUClass CRD in cozystack.io and keeps it on uninstall
documentSelector:
path: metadata.name
value: gpuclasses.cozystack.io
asserts:
- equal:
path: spec.group
value: cozystack.io
- equal:
path: spec.scope
value: Cluster
- equal:
path: metadata.annotations["helm.sh/resource-policy"]
value: keep
- equal:
path: spec.versions[0].served
value: true