Files
Infrastruktur-Monitoring-Sy…/frontend/e2e/cluster.spec.ts
Dennis Nemec 8f36a54da0
Some checks failed
CI / backend (push) Has been cancelled
CI / frontend (push) Has been cancelled
CI / ui (push) Has been cancelled
WP-12: Kubernetes overview and workload actions
kube-rs gateway (nodes, namespaces, deployments/statefulsets/daemonsets with
images, PVCs; rollout restart, scale, set image via patches) using the
microk8s kubeconfig by default, fake gateway for dev, /api/cluster routes,
Kubernetes page with node cards, workload table with admin actions and PVC
list. Also implements the streaming command runner that WP-11 relied on.

Co-Authored-By: Claude Fable 5.1 <noreply@anthropic.com>
2026-09-02 22:33:57 +02:00

22 lines
881 B
TypeScript

import { test, expect } from '@playwright/test'
test('cluster page shows node, workloads and lets an admin restart a workload', async ({
page,
}) => {
await page.goto('/login')
await page.getByLabel('Email').fill('admin@example.com')
await page.getByLabel('Password').fill('admin-password-123')
await page.getByRole('button', { name: 'Sign in' }).click()
await page.getByRole('link', { name: 'Kubernetes' }).click()
await expect(page.getByTestId('node-version')).toContainText('v1.32')
const row = page.getByRole('row', { name: /^gitea gitea-postgresql statefulset/ })
await expect(row).toContainText('statefulset')
page.once('dialog', (d) => d.accept())
await page
.getByRole('row', { name: /^gitea deployment/ })
.getByRole('button', { name: 'Restart' })
.click()
await expect(page.getByRole('status')).toContainText('Restart requested')
})