Skip to content
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
26 changes: 15 additions & 11 deletions .claude/commands/cypress/cypress-run.md
Original file line number Diff line number Diff line change
Expand Up @@ -341,23 +341,27 @@ npm run cypress:run -- --headed --config video=false

Use these tags with `--env grepTags`:

**Feature Tags:**
**1. Modifier Tags:**

- `@flaky` - Tests that don't pass reliably
- `@xfail` - Tests for known bugs expected to fail
- `@slow` - Long-running e2e tests (15+ minutes)

**2. Infrastructure Tags:**

- `@acm` - Advanced Cluster Management integration tests
- `@coo` - Cluster Observability Operator functionality tests
- `@virtualization` - Virtualization integration tests
- `@ols` - OpenShift Lightspeed. Requires external installation of OLS and setup of LLM accounts through CI configuration

**3. Feature Tags** (format: `@{component}`):

- `@acm-alerting` - Alert-related tests in ACM perspective
- `@alerting` - Alert-related tests
- `@legacy-dashboards` - Legacy dashboard tests
- `@metrics` - Metrics explorer tests
- `@targets` - Targets tests
- `@perses-dashboards` - Perses dashboard tests
- `@coo` - Observability Operator tests
- `@ols` - OpenShift Lightspeed integration tests
- `@virtualization` - OpenShift Virtualization tests
- `@cluster-health-analyzer` - Incidents feature tests
- `@targets` - Targets page tests

**Modifier Tags:**

- `@slow` - Longer running tests
- `@flaky` - Known flaky tests

---

Expand Down
2 changes: 1 addition & 1 deletion web/cypress.config.ts
Original file line number Diff line number Diff line change
Expand Up @@ -5,8 +5,8 @@ import * as path from 'path';
import registerCypressGrep from '@cypress/grep/src/plugin';
import { DefinePlugin, NormalModuleReplacementPlugin } from 'webpack';
import {
writeBenchmarkReport,
injectBenchmarksIntoMochawesome,
writeBenchmarkReport,
} from './cypress/plugins/benchmark-reporter';

const getLoginCredentials = (index: number): { username: string; password: string } => {
Expand Down
15 changes: 5 additions & 10 deletions web/cypress/README.md
Original file line number Diff line number Diff line change
Expand Up @@ -214,33 +214,28 @@ Tests are organized using tags for selective execution using [@cypress/grep](htt

#### Tag Categories

**1. Basic Tags:**
**1. Modifier Tags:**

- `@flaky` - Tests that don't pass reliably
- `@xfail` - Tests for known bugs expected to fail
- `@slow` - Long-running e2e tests (15+ minutes)

**2. High-Level Component Tags:**
**2. Infrastructure Tags:**

- `@coo` - Cluster Observability Operator functionality tests (operator installation, ACM integration)
- `@acm` - Advanced Cluster Management integration tests
- `@coo` - Cluster Observability Operator functionality tests
- `@virtualization` - Virtualization integration tests
- `@ols` - OpenShift Lightspeed. Requires external installation of OLS and setup of LLM accounts through CI configuration

**3. Specific Feature Tags** (format: `@{component}`):
**3. Feature Tags** (format: `@{component}`):

- `@acm-alerting` - Alert-related tests in ACM perspective
- `@alerting` - Alert-related tests
- `@legacy-dashboards` - Legacy dashboard tests
- `@metrics` - Metrics explorer tests
- `@targets` - Targets tests
- `@perses-dashboards` - Perses dashboard tests
- `@cluster-health-analyzer` - Incidents feature tests

**4. JIRA Tags** (format: `@JIRA-{ID}`):

- Example: `@JIRA-OU-1033`
- Link tests to specific JIRA issues

#### Running Tests by Tags

**Run component-specific tests:**
Expand Down
2 changes: 1 addition & 1 deletion web/cypress/e2e/coo/01.coo_bvt.cy.ts
Original file line number Diff line number Diff line change
Expand Up @@ -18,7 +18,7 @@ const MP = {
operatorName: 'Cluster Monitoring Operator',
};

describe('BVT: COO', { tags: ['@alerting', '@acm-alerting', '@coo'] }, () => {
describe('BVT: COO', { tags: ['@alerting', '@coo'] }, () => {
before(() => {
cy.beforeBlockCOO(MCP, MP);
});
Expand Down
2 changes: 1 addition & 1 deletion web/cypress/e2e/coo/02.acm_alerting_ui.cy.ts
Original file line number Diff line number Diff line change
Expand Up @@ -24,7 +24,7 @@ const MP = {
};
const expectedAlerts = ['Watchdog', 'Watchdog-spoke', 'ClusterCPUHealth-jb'];

describe('ACM Alerting UI', { tags: ['@alerting', '@acm-alerting', '@coo'] }, () => {
describe('ACM Alerting UI', { tags: ['@alerting', '@acm', '@coo'] }, () => {
before(() => {
cy.beforeBlockACM(MCP, MP);
});
Expand Down
2 changes: 1 addition & 1 deletion web/cypress/e2e/coo/02.acm_perses.cy.ts
Original file line number Diff line number Diff line change
Expand Up @@ -18,7 +18,7 @@ const MP = {
operatorName: 'Cluster Monitoring Operator',
};

describe('ACM - Perses', { tags: ['@coo', '@perses-dashboards'] }, () => {
describe('ACM - Perses', { tags: ['@perses-dashboards', '@acm', '@coo'] }, () => {
before(() => {
cy.beforeBlockACM(MCP, MP);
cy.switchPerspective('Core platform');
Expand Down
2 changes: 1 addition & 1 deletion web/cypress/e2e/incidents/00.coo_incidents_e2e.cy.ts
Original file line number Diff line number Diff line change
Expand Up @@ -20,7 +20,7 @@ const MP = {
operatorName: 'Cluster Monitoring Operator',
};

describe('BVT: Incidents - e2e', { tags: ['@slow', '@cluster-health-analyzer', '@coo'] }, () => {
describe('BVT: Incidents - e2e', { tags: ['@cluster-health-analyzer', '@coo', '@slow'] }, () => {
let currentAlertName: string;

before(() => {
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -30,7 +30,7 @@ const MP = {

describe(
'Regression: Mixed Severity Interval Boundary Times',
{ tags: ['@cluster-health-analyzer', '@xfail', '@coo'] },
{ tags: ['@cluster-health-analyzer', '@coo', '@xfail'] },
() => {
before(() => {
cy.beforeBlockCOO(MCP, MP, { dashboards: false, troubleshootingPanel: false });
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -36,7 +36,7 @@ const MP = {

describe(
'Regression: Time-Based Alert Resolution (E2E with Firing Alerts)',
{ tags: ['@cluster-health-analyzer', '@slow', '@coo'] },
{ tags: ['@cluster-health-analyzer', '@coo', '@slow'] },
() => {
let currentAlertName: string;

Expand Down
2 changes: 1 addition & 1 deletion web/cypress/e2e/perses/05.coo_tempo_loki_admin.cy.ts
Original file line number Diff line number Diff line change
Expand Up @@ -43,7 +43,7 @@ const CLO = {

describe(
'COO - Dashboards (Perses) - Perses Global Datasources with Tempo and Loki',
{ tags: ['@perses-dashboards', '@xfail', '@coo'] },
{ tags: ['@perses-dashboards', '@coo', '@xfail'] },
() => {
before(() => {
cy.beforeBlockTempo(TEMPO);
Expand Down
8 changes: 4 additions & 4 deletions web/cypress/e2e/virtualization/00.coo_ivt.cy.ts
Original file line number Diff line number Diff line change
Expand Up @@ -34,8 +34,8 @@ const KBV = {
};

describe(
'Installation: COO and setting up Monitoring Plugin',
{ tags: ['@virtualization', '@coo', '@slow'] },
'IVT: Monitoring + Virtualization',
{ tags: ['@alerting', '@metrics', '@coo', '@virtualization', '@slow'] },
() => {
before(() => {
cy.beforeBlockCOO(MCP, MP);
Expand All @@ -47,7 +47,7 @@ describe(
},
);

describe('Installation: Virtualization', { tags: ['@virtualization', '@coo', '@slow'] }, () => {
describe('Installation: Virtualization', { tags: ['@coo', '@virtualization', '@slow'] }, () => {
before(() => {
cy.beforeBlockVirtualization(KBV);
});
Expand All @@ -61,7 +61,7 @@ describe('Installation: Virtualization', { tags: ['@virtualization', '@coo', '@s

describe(
'IVT: Monitoring + Virtualization',
{ tags: ['@metrics', '@alerting', '@virtualization', '@coo'] },
{ tags: ['@alerting', '@metrics', '@coo', '@virtualization'] },
() => {
beforeEach(() => {
cy.visit('/');
Expand Down
8 changes: 4 additions & 4 deletions web/cypress/e2e/virtualization/01.coo_ivt_alerts.cy.ts
Original file line number Diff line number Diff line change
Expand Up @@ -34,8 +34,8 @@ const KBV = {
};

describe(
'Installation: COO and setting up Monitoring Plugin',
{ tags: ['@alerting', '@virtualization', '@slow', '@coo'] },
'Regression: Monitoring - Alerts (Virtualization)',
{ tags: ['@alerting', '@coo', '@virtualization', '@slow'] },
() => {
before(() => {
cy.beforeBlockCOO(MCP, MP);
Expand All @@ -49,7 +49,7 @@ describe(

describe(
'IVT: Monitoring UIPlugin + Virtualization',
{ tags: ['@alerting', '@virtualization', '@slow', '@coo'] },
{ tags: ['@alerting', '@coo', '@virtualization', '@slow'] },
() => {
before(() => {
cy.beforeBlockVirtualization(KBV);
Expand All @@ -65,7 +65,7 @@ describe(

describe(
'Regression: Monitoring - Alerts (Virtualization)',
{ tags: ['@alerting', '@slow', '@virtualization', '@coo'] },
{ tags: ['@alerting', '@coo', '@virtualization', '@slow'] },
() => {
beforeEach(() => {
cy.visit('/');
Expand Down
10 changes: 5 additions & 5 deletions web/cypress/e2e/virtualization/02.coo_ivt_metrics_1.cy.ts
Original file line number Diff line number Diff line change
Expand Up @@ -34,8 +34,8 @@ const KBV = {
};

describe(
'Installation: COO and setting up Monitoring Plugin',
{ tags: ['@virtualization', '@slow', '@coo'] },
'Regression: Monitoring - Metrics (Virtualization)',
{ tags: ['@metrics', '@coo', '@virtualization', '@slow'] },
() => {
before(() => {
cy.beforeBlockCOO(MCP, MP);
Expand All @@ -49,7 +49,7 @@ describe(

describe(
'IVT: Monitoring UIPlugin + Virtualization',
{ tags: ['@virtualization', '@slow', '@coo'] },
{ tags: ['@coo', '@virtualization', '@slow'] },
() => {
before(() => {
cy.beforeBlockVirtualization(KBV);
Expand All @@ -65,7 +65,7 @@ describe(

describe(
'Regression: Monitoring - Metrics (Virtualization)',
{ tags: ['@metrics', '@slow', '@virtualization', '@coo'] },
{ tags: ['@metrics', '@coo', '@virtualization', '@slow'] },
() => {
beforeEach(() => {
cy.visit('/');
Expand All @@ -87,7 +87,7 @@ describe(

describe(
'Regression: Monitoring - Metrics Namespaced (Virtualization)',
{ tags: ['@metrics', '@slow', '@virtualization', '@coo'] },
{ tags: ['@metrics', '@coo', '@virtualization', '@slow'] },
() => {
beforeEach(() => {
cy.visit('/');
Expand Down
8 changes: 4 additions & 4 deletions web/cypress/e2e/virtualization/02.coo_ivt_metrics_2.cy.ts
Original file line number Diff line number Diff line change
Expand Up @@ -35,7 +35,7 @@ const KBV = {

describe(
'Installation: COO and setting up Monitoring Plugin',
{ tags: ['@virtualization', '@slow', '@coo'] },
{ tags: ['@coo', '@virtualization', '@slow'] },
() => {
before(() => {
cy.beforeBlockCOO(MCP, MP);
Expand All @@ -49,7 +49,7 @@ describe(

describe(
'IVT: Monitoring UIPlugin + Virtualization',
{ tags: ['@virtualization', '@slow', '@coo'] },
{ tags: ['@coo', '@virtualization', '@slow'] },
() => {
before(() => {
cy.beforeBlockVirtualization(KBV);
Expand All @@ -65,7 +65,7 @@ describe(

describe(
'Regression: Monitoring - Metrics (Virtualization)',
{ tags: ['@metrics', '@slow', '@virtualization', '@coo'] },
{ tags: ['@metrics', '@coo', '@virtualization', '@slow'] },
() => {
beforeEach(() => {
cy.visit('/');
Expand All @@ -87,7 +87,7 @@ describe(

describe(
'Regression: Monitoring - Metrics Namespaced (Virtualization)',
{ tags: ['@metrics', '@slow', '@virtualization', '@coo'] },
{ tags: ['@metrics', '@coo', '@virtualization', '@slow'] },
() => {
beforeEach(() => {
cy.visit('/');
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -33,8 +33,8 @@ const KBV = {
};

describe(
'Installation: COO and setting up Monitoring Plugin',
{ tags: ['@virtualization', '@slow', '@coo'] },
'Regression: Monitoring - Legacy Dashboards (Virtualization)',
{ tags: ['@legacy-dashboards', '@coo', '@virtualization', '@slow'] },
() => {
before(() => {
cy.beforeBlockCOO(MCP, MP);
Expand All @@ -48,7 +48,7 @@ describe(

describe(
'IVT: Monitoring UIPlugin + Virtualization',
{ tags: ['@virtualization', '@slow', '@coo'] },
{ tags: ['@coo', '@virtualization', '@slow'] },
() => {
before(() => {
cy.beforeBlockVirtualization(KBV);
Expand All @@ -64,7 +64,7 @@ describe(

describe(
'Regression: Monitoring - Legacy Dashboards (Virtualization)',
{ tags: ['@legacy-dashboards', '@slow', '@virtualization', '@coo'] },
{ tags: ['@legacy-dashboards', '@coo', '@virtualization', '@slow'] },
() => {
beforeEach(() => {
cy.visit('/');
Expand All @@ -84,7 +84,7 @@ describe(

describe(
'Regression: Monitoring - Legacy Dashboards Namespaced (Virtualization)',
{ tags: ['@legacy-dashboards', '@slow', '@virtualization', '@coo'] },
{ tags: ['@legacy-dashboards', '@coo', '@virtualization', '@slow'] },
() => {
beforeEach(() => {
cy.visit('/');
Expand Down
7 changes: 4 additions & 3 deletions web/cypress/e2e/virtualization/04.coo_ivt_perses.cy.ts
Original file line number Diff line number Diff line change
Expand Up @@ -33,8 +33,9 @@ const KBV = {
};

describe(
'Installation: COO and setting up Monitoring Plugin',
{ tags: ['@virtualization', '@slow'] },
'IVT: COO - Dashboards (Perses) - Virtualization perspective',
{ tags: ['@perses-dashboards', '@coo', '@virtualization', '@slow'] },

() => {
before(() => {
cy.beforeBlockCOO(MCP, MP);
Expand All @@ -61,7 +62,7 @@ describe('Installation: Virtualization', { tags: ['@virtualization', '@slow'] },

describe(
'IVT: COO - Dashboards (Perses) - Virtualization perspective',
{ tags: ['@perses-dashboards', '@slow', '@virtualization', '@coo'] },
{ tags: ['@perses-dashboards', '@coo', '@virtualization', '@slow'] },
() => {
beforeEach(() => {
cy.visit('/');
Expand Down
32 changes: 0 additions & 32 deletions web/cypress/support/test-tags.d.ts

This file was deleted.

23 changes: 23 additions & 0 deletions web/cypress/support/test-tags.ts
Original file line number Diff line number Diff line change
@@ -0,0 +1,23 @@
export const MODIFIER_TAGS = ['@flaky', '@xfail', '@slow'] as const;

export const INFRASTRUCTURE_TAGS = ['@coo', '@virtualization', '@ols', '@acm'] as const;

export const FEATURE_TAGS = [
'@alerting',
'@legacy-dashboards',
'@metrics',
'@targets',
'@perses-dashboards',
'@cluster-health-analyzer',
] as const;

export type ModifierTag = (typeof MODIFIER_TAGS)[number];

export type InfrastructureTag = (typeof INFRASTRUCTURE_TAGS)[number];

export type FeatureTag = (typeof FEATURE_TAGS)[number];

export type SpecificFeatureTag = `@${string}-${string}`;

export type AllowedTag = ModifierTag | InfrastructureTag | FeatureTag | SpecificFeatureTag;
export type TestTags = AllowedTag | AllowedTag[];
Loading