Skip to content

feat(dcm): add Playwright E2E test suite for DCM RHDH plugin#3249

Open
hardengl wants to merge 3 commits into
redhat-developer:mainfrom
hardengl:feature/dcm-e2e-tests
Open

feat(dcm): add Playwright E2E test suite for DCM RHDH plugin#3249
hardengl wants to merge 3 commits into
redhat-developer:mainfrom
hardengl:feature/dcm-e2e-tests

Conversation

@hardengl
Copy link
Copy Markdown
Contributor

Summary

Adds a comprehensive Playwright E2E test suite (46 tests) for the DCM (Data Center Management) RHDH plugin, covering all major UI workflows verified against a live deployment.

  • Smoke tests (9): Plugin skeleton navigation, all 6 tabs load with data, API proxy validation
  • Providers CRUD (7): Register, edit name/URL, search, delete with confirmation guard
  • Policies CRUD (6): Create GLOBAL/USER policies, toggle enabled/disabled, edit, delete
  • Catalog Items (9): Pet Clinic seed verification, create/edit/delete items, YAML file import (valid + invalid)
  • Instances (2): Create dialog from catalog item, empty state display
  • Regressions (13): Deep-link routing, delete confirmation guard, search + pagination, toggle persistence, chip/switch sync, read-only name field, whitespace validation, success snackbar, empty table rows (FLPATH-4111), rows-per-page persistence (FLPATH-4112)

Files Added

File Purpose
playwright.config.ts Playwright configuration with guest auth fixture
e2e-tests/pages/DcmPage.ts Page object with helpers for all DCM tabs
e2e-tests/fixtures/auth.ts performGuestLogin auth setup
e2e-tests/fixtures/dcm/*.yaml Test data fixtures for catalog item import
e2e-tests/dcm-smoke.test.ts Navigation and data-loading smoke tests
e2e-tests/dcm-providers.test.ts Provider CRUD lifecycle
e2e-tests/dcm-policies.test.ts Policy CRUD lifecycle
e2e-tests/dcm-catalog-items.test.ts Catalog item CRUD + YAML import
e2e-tests/dcm-regressions.test.ts Regression tests for fixed bugs
e2e-tests/app.test.ts Basic app shell test
package.json Added @playwright/test dev dependency

JIRA Coverage

All tests are tagged with JIRA IDs. Covers verification of 21 ON_QA stories under FLPATH-3241, including regression tests for FLPATH-4111 and FLPATH-4112.

Test plan

  • npx playwright test passes against a live RHDH deployment with DCM plugin
  • Tests are isolated — each creates/cleans up its own data
  • No changes to production plugin code (test-only PR)

Made with Cursor

46 browser-based E2E tests covering the full DCM Data Center UI:
- Smoke tests: navigation, 6 tabs, seed data verification, API proxy
- Providers CRUD: register, edit, search, delete
- Policies CRUD: create GLOBAL/USER, toggle, edit, delete
- Catalog items: Pet Clinic, create/edit/delete, YAML import
- Instances: create dialog, empty state
- Regressions: deep link, delete guard, search+pagination, toggle
  persistence, chip/switch sync, read-only name, whitespace validation,
  success snackbar, empty table rows, rows-per-page persistence

Includes Playwright config, page object (DcmPage), auth fixture, and
YAML test data fixtures. Follows rhdh-plugins workspace conventions.

Ref: FLPATH-3241, FLPATH-4200
Co-authored-by: Cursor <cursoragent@cursor.com>
@rhdh-gh-app
Copy link
Copy Markdown

rhdh-gh-app Bot commented May 28, 2026

Changed Packages

Package Name Package Path Changeset Bump Current Version
app workspaces/dcm/packages/app none v0.0.1

hardengl and others added 2 commits May 29, 2026 13:49
Addresses SonarQube security hotspots (typescript:S2245) flagging
Math.random() as weak PRNG. Uses globalThis.crypto to satisfy both
SonarQube and ESLint no-restricted-globals rule.

Co-authored-by: Cursor <cursoragent@cursor.com>
Add missing lockfile entries for @playwright/test, playwright, and
playwright-core to fix immutable install failure in CI.

Co-authored-by: Cursor <cursoragent@cursor.com>
@sonarqubecloud
Copy link
Copy Markdown

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant