Commit Graph
27 Commits
Author SHA1 Message Date
4ca7a04864 test: model pricing E2E tests (13 journey flows) + Build tab timing fix (#12525)
## Summary

- **13 Playwright E2E journey tests** for the Model Pricing feature
(\`/settings/model_pricing\`), consolidating all P0–P2 scenarios into
journey-based flows
- New page object \`ModelPricingPage\` under \`pages/generalPages/\`
- API cleanup integrated into the centralized \`APICleanup\` class and
called from \`cleanup.spec.js\`
- CI matrix updated: \`ZO_MODEL_PRICING_ENABLED=true\` env var added;
\`model-pricing.spec.js\` added to the \`GeneralTests\` job
- **Bug fix**: \`waitForBuildTabLoaded\` now polls the Monaco editor for
non-empty content (Phase 3), fixing a timing race where Build tab SQL
tests read an empty query string on slower CI machines

## Test coverage

| Journey | Scenarios covered |
|---------|------------------|
| List, tabs & search | Controls, tab switching, search, built-in tab |
| Create & validation | All form validation cases + successful save |
| Edit, cancel & delete | Full lifecycle |
| Duplicate & clone | Org model duplicate + built-in clone |
| Bulk actions | Select, export JSON, bulk delete |
| Toggle | Disable/re-enable with correct visual state |
| Test match dialog | Empty state, no-result, clear, match result |
| Import | Valid JSON, correction flow, cancel |
| Editor features | Multi-tier, pricing template, pattern examples |
| Pricing drawer | Overflow link → drawer with all price keys |
| Empty state | CTA when org has no custom models |
| Cost applied | LLM span matched → cost stored correctly |
| No matching model | Unknown model name → zero cost stored |

## Bug fix: Build tab query editor timing

\`waitForBuildTabLoaded\`'s Phase 2 (chart-type-selected signal) fires
as soon as \`initializeFromQuery\` sets the chart type — before
\`makeAutoSQLQuery\` has run. On slower CI machines this left
\`queries[0].query\` empty when tests read the editor, causing the "SQL
ON + Auto mode" and "Auto → Custom" tests to receive \`""\` instead of
generated SQL.

Phase 3 polls the Monaco editor
(\`[data-test="logs-search-bar-query-editor"]\`) for non-empty content,
confirming \`onBuildQueryGenerated\` has been called and the query is
ready.

## Test plan

- [x] All 13 model pricing tests pass locally
- [x] \`logsQueryBuilder-editor.spec.js\` (23 tests) — all pass with
Phase 3 fix applied
- [x] Sentinel code audit passed (no blocking issues)
- [x] API cleanup added to \`cleanup.spec.js\` via
\`apiCleanup.cleanupModelPricingModels()\` — 404-safe for instances
where the feature is disabled

🤖 Generated with [Claude Code](https://claude.com/claude-code)

---------

Co-authored-by: Claude Sonnet 4.6 <noreply@anthropic.com>
Co-authored-by: github-actions[bot] <github-actions[bot]@users.noreply.github.com>
2026-06-09 18:33:07 +00:00
Neha PandClaude Opus 4.7 ab86391649 test: add E2E tests for report folders functionality (#11985)
## Summary
- **Add `reportFoldersPage.js`** page object with 30+ methods for folder
CRUD, report move, search, and cross-folder toggle
- **Add `reportFolders.spec.js`** with 12 tests covering:
  - **P0 Smoke**: Sidebar renders with default folder, create new folder
- **P1 Functional**: Create report via API (creates temp dashboard from
scratch), move report between folders, cross-folder search, folder
sidebar search filter
- **P2 Edge Cases**: Move button disabled when source=destination, save
disabled for empty name, cancel closes dialog, default folder has no
edit/delete options, special characters allowed in folder names
- **Cleanup**: Deletes all test reports, folders, and leaves no
resources behind
- **Add `createDashboardViaApi`** to apiCleanup.js — creates a minimal
v8 dashboard from scratch, removing dependency on pre-existing
dashboards
- **Add `createReportViaApi`**, `fetchReportFolders`,
`deleteReportFolder`, `cleanupReportFolders` methods to apiCleanup.js
- Register ReportFoldersPage in PageManager

## Approach
- Everything created from scratch — unique report via API, unique
folders via UI, all cleaned up afterward
- No dependency on pre-existing dashboards or reports
- Zero `waitForTimeout` calls — all waits use `waitForLoadState`,
`waitFor({ state: 'visible/hidden' })`, or role-based waits
- Serial execution (tests build on each other: create folder → create
report → move report → cleanup)

## Test Results
```
12 passed (2.1m)
```

## CI Integration
- Added to `.github/workflows/playwright.yml` under `Reports` testfolder
alongside existing report tests

🤖 Generated with [Claude Code](https://claude.com/claude-code)

---------

Co-authored-by: Claude Opus 4.7 <noreply@anthropic.com>
2026-05-20 07:53:49 +00:00
79b86199a4 test: Alerts cloud compatibility for alpha1 E2E (Set2) (#10813)
## Summary
- Make all 8 Alerts spec files cloud-compatible for alpha1 environment
- Replace `process.env.ORGNAME` with `getOrgIdentifier()` from
cloud-auth.js
- Replace `getAuthToken()` (email:password) with `getAuthHeaders()` for
cloud passcode-based auth in 3 files with API calls
(alerts-scheduled-features, alerts-incident-correlation,
alerts-vrl-encoding)

## Test plan
- [ ] All existing self-hosted E2E tests still pass
- [ ] Alpha1 cloud E2E Alerts shard passes

---------

Co-authored-by: Claude Opus 4.6 <noreply@anthropic.com>
Co-authored-by: claude[bot] <41898282+claude[bot]@users.noreply.github.com>
Co-authored-by: Shrinath Rao <undefined@users.noreply.github.com>
2026-03-10 18:33:58 +05:30
befa1883a0 test: add alpha1 cloud compatibility for E2E logs tests (#10763)
## Summary
- Add cloud auth infrastructure (`cloud-env.js`, `cloud-auth.js`) for
cloud/self-hosted switching
- Centralize ingestion auth via `getAuthHeaders()` across all ingestion
utilities (data, trace, service-graph, metrics)
- Refactor `commonActions.js` from `exec(curl)` to `page.request.post()`
for cloud cookie compatibility
- Enhance `cloudLoginPage.js` + `page-manager.js` for conditional cloud
page objects
- Update `global-setup-alpha1.js` to fetch org identifier and passcode
from cloud session
- Fix `global-teardown.js` race condition with proper error handling
- Replace `console.log` with `testLogger` in `commonActions.js`,
`ingest-service-graph.spec.js`, `scripts/ingest-service-graph.js`
- Replace raw selectors with POM methods (`applyQueryButton`, VRL
editor, pagination, time range)
- Add missing test tags to `searchpartition`, `unflattened`,
`ingest-service-graph` specs
- Fix `networkidle` → `domcontentloaded` across multiple spec files

## Companion PR
- Enterprise: sets `IS_CLOUD=true` in alpha1 E2E workflow

## Test plan
- [ ] Self-hosted E2E tests pass (no behavioral changes — only routing
through POM + testLogger)
- [ ] Alpha1 cloud E2E tests pass with cloud auth enabled
- [ ] Verify no credential leaks in logs (passcode/password values never
logged)

---------

Co-authored-by: Claude Opus 4.6 <noreply@anthropic.com>
Co-authored-by: claude[bot] <41898282+claude[bot]@users.noreply.github.com>
Co-authored-by: Shrinath Rao <undefined@users.noreply.github.com>
2026-03-07 07:00:07 +05:30
Shrinath Rao 06f095a628 test: add E2E Playwright tests for Service Graph feature (#10653) 2026-02-26 22:36:21 +08:00
Shrinath Rao dac030f64d test: add cleanup patterns for RBAC test artifacts (#10245)
## Summary
- Add enrichment table cleanup patterns for orphaned RBAC test data:
  - `viewer_created_et_*`, `partial_access_et_*`, `health_check_*`
- `enrich_basic_*`, `enrich_duplicate_*`, `enrich_invalid_*`,
`enrich_protocols_*`
- `enrich_table_*`, `enrich_update_append_*`, `enrich_update_replace_*`
  - `editor_create_test_*`
- Add alert cleanup prefixes for RBAC test alerts:
  - `user_delete_test_*`, `user_update_test_*`
  - `viewer_delete_test_*`, `viewer_update_test_*`
  - `editor_create_test_*`, `editor_delete_test_*`
- Add stream cleanup patterns: `backfill_source_*`, `backfill_dest_*`
- Add log response body on URL enrichment table fetch failure for
debugging
- Fix precise regex for cleanup-only detection in global-setup.js
- Fix null check before Object.keys() in cleanupUrlEnrichmentTables

## Why
These patterns clean up orphaned test data from o2-enterprise RBAC tests
when individual test teardown fails due to:
- Test crashes/failures mid-execution
- CI/CD timeouts killing jobs before teardown
- API deletion failures during teardown

The Playwright cleanup.spec.js serves as a safety net for all orphaned
data.

## Test plan
- [x] Patterns validated against actual orphaned data on
dev2.internal.zinclabs.dev
- [x] Source tests identified in o2-enterprise RBAC test files
2026-01-29 16:05:12 +05:30
Shrinath Rao d1d643814e test: enhance cleanup patterns for orphaned test data (#10232)
### **User description**
## Summary

- Add URL enrichment tables cleanup support via new
`/api/{org}/enrichment_tables/status` endpoint
- Add cleanup patterns for orphaned streams, functions, pipelines, and
enrichment tables
- Skip data ingestion when running cleanup.spec.js alone (optimization
for cleanup-only runs)

## Changes

### URL Enrichment Tables (apiCleanup.js)
- `fetchUrlEnrichmentTables()` - Fetches URL-based tables from status
API
- `cleanupUrlEnrichmentTables(patterns)` - Cleans up tables showing "NaN
MB" in UI

### New Cleanup Patterns (cleanup.spec.js)

**Streams:**
- `e2e_apostrophe_*` - Bug #9475 apostrophe test streams
- `e2e_traces_pipeline_test`
- `e2e_traces_<timestamp>_<suffix>`

**Functions:**
- `vrl_func_*` - Pipeline VRL function tests
- `vrl_traces_func_*` - Traces VRL function tests
- `vrl_metrics_func_*` - Metrics VRL function tests

**Pipelines:**
- `metrics-pipeline-*`
- `traces-pipeline-*`
- `condition-pipeline-*`
- `metrics-condition-pipeline-*`

**URL Enrichment Tables:**
- `schema_mismatch_*`, `schema_view_*`, `url_404_*`, `url_lifecycle_*`
- `invalid_url_*`, `cancel_test_*`, `toggle_test_*`, `edit_form_*`

### Global Setup Optimization (global-setup.js)
- Auto-detect cleanup-only runs via `process.argv`
- Skip logs, metrics, and traces ingestion for cleanup runs

## Test plan
- [ ] Run cleanup.spec.js standalone and verify no data ingestion occurs
- [ ] Verify orphaned test data is cleaned up correctly


___

### **PR Type**
Enhancement, Tests


___

### **Description**
- Add URL enrichment tables cleanup methods

- Extend cleanup.spec.js with new regex patterns

- Invoke cleanupUrlEnrichmentTables in tests

- Skip data ingestion on cleanup-only runs


___



<details> <summary><h3> File Walkthrough</h3></summary>

<table><thead><tr><th></th><th align="left">Relevant
files</th></tr></thead><tbody><tr><td><strong>Enhancement</strong></td><td><table>
<tr>
  <td>
    <details>
<summary><strong>apiCleanup.js</strong><dd><code>Add URL enrichment
tables cleanup</code>&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp;
&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp;
&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; </dd></summary>
<hr>

tests/ui-testing/pages/apiCleanup.js

<ul><li>Added fetchUrlEnrichmentTables method<br> <li> Added
cleanupUrlEnrichmentTables method<br> <li> Handled fetch and delete
errors</ul>


</details>


  </td>
<td><a
href="https://github.com/openobserve/openobserve/pull/10232/files#diff-537fe76c0d8e26e81c5f77c83bd0ee35daaa973822105c809bf83171a26b33c5">+79/-0</a>&nbsp;
&nbsp; </td>

</tr>

<tr>
  <td>
    <details>
<summary><strong>global-setup.js</strong><dd><code>Skip ingestion in
cleanup-only runs</code>&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp;
&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp;
&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; </dd></summary>
<hr>

tests/ui-testing/playwright-tests/utils/global-setup.js

<ul><li>Introduced isCleanupOnly flag<br> <li> Skipped data ingestion
for cleanup-only runs<br> <li> Retained conditional ingestion logic</ul>


</details>


  </td>
<td><a
href="https://github.com/openobserve/openobserve/pull/10232/files#diff-06323dad7214f86b41b62e121e716eeea0054bc4d950c6bcf4a0efe53894acc8">+20/-14</a>&nbsp;
</td>

</tr>
</table></td></tr><tr><td><strong>Tests</strong></td><td><table>
<tr>
  <td>
    <details>
<summary><strong>cleanup.spec.js</strong><dd><code>Extend cleanup test
patterns and URL tables</code>&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp;
&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; </dd></summary>
<hr>

tests/ui-testing/playwright-tests/cleanup.spec.js

<ul><li>Updated pipeline cleanup regex patterns<br> <li> Extended
function cleanup patterns<br> <li> Modified enrichment tables
patterns<br> <li> Added cleanupUrlEnrichmentTables invocation</ul>


</details>


  </td>
<td><a
href="https://github.com/openobserve/openobserve/pull/10232/files#diff-c214275a512fa285a7e4f2ab61dfcb42d71a0436b0e4241f94d7b45693587983">+27/-4</a>&nbsp;
&nbsp; </td>

</tr>
</table></td></tr></tr></tbody></table>

</details>

___
2026-01-29 12:21:35 +05:30
Shrinath RaoandClaude Opus 4.5 7300708a46 test: add E2E tests for Correlation Settings page + fix CI TestDino rerun issue (#10124)
## Summary
- Adds E2E tests for Correlation Settings page (#9790)
- Fixes CI failure when TestDino rerun optimization skips tests

## CI Fix Details

### Problem
When TestDino's rerun optimization skips tests (because they already
passed in a previous run), the `merge_and_upload_reports` job was
failing:

1. Tests skip → no blob reports uploaded
2. Merge step found no artifacts, checked job status, saw all succeeded
3. Old code just did `exit 0` without creating `report.json`
4. Upload step failed: "JSON report not found"

This happened on:
- https://github.com/openobserve/openobserve/actions/runs/21205291873
- https://github.com/openobserve/openobserve/actions/runs/21207884853

### Root Cause
The TestDino rerun optimization works across different `run_id`s (based
on cache), not just attempts. So even a "fresh" run (attempt 1) can have
all tests skip if a previous run for the same PR/branch cached that all
tests passed.

### Fix
1. **Merge Reports step**: Create empty `report.json` and HTML when all
tests skip (aligns with ENT repo which already has this fix)
2. **Cache step**: Changed error message to notice for graceful handling
3. **Upload step**: Added safety check to skip if `report.json` doesn't
exist

## Test plan
- [x] Correlation Settings E2E tests pass locally
- [ ] CI workflow handles rerun scenarios gracefully

---------

Co-authored-by: Claude Opus 4.5 <noreply@anthropic.com>
2026-01-22 06:47:46 +05:30
Shrinath Rao 791914fb44 test: add cleanup pattern for destination1-999 in alert and pipeline destinations (#10085)
## Summary
- Add regex pattern `/^destination\d{1,3}$/` to alert destinations
cleanup in `cleanup.spec.js`
- Update pipeline destinations pattern from `\d{2,3}` to `\d{1,3}` to
cover 1-3 digits
- Update `apiCleanup.js` `completeCascadeCleanup()` to support both
string prefixes and RegExp patterns

This cleans up leftover test destinations like `destination4`,
`destination44`, `destination444`, etc.

## Changes

### cleanup.spec.js
- Added `/^destination\d{1,3}$/` pattern to alert destinations array
(line 35)
- Updated pipeline destinations pattern to `/^destination\d{1,3}$/`
(line 128)

### apiCleanup.js
- Updated `completeCascadeCleanup()` to handle both string prefixes and
RegExp patterns in `destinationPrefixes` parameter
- Updated JSDoc to reflect new parameter type: `Array<string|RegExp>`
- Filter logic now checks `instanceof RegExp` to use `.test()` for regex
or `.startsWith()` for strings

## Test plan
- [x] Verified patterns match intended destination names
(destination1-999)
- [ ] Run cleanup spec to verify alert destinations are deleted
- [ ] Run cleanup spec to verify pipeline destinations are deleted
2026-01-19 12:39:53 +05:30
priyabrata-stackandClaude Sonnet 4.5 0cf0e8937c fix(tests): implement POM compliance for metrics tests (72% complete)
Major refactoring to fix Page Object Model violations in metrics test suite.
This addresses critical code quality issues identified in the Sentinel audit.

## Changes

### Page Objects Enhanced
- **metricsPage.js**: Added 350+ lines of new methods
  - Data visualization verification methods
  - Config sidebar operations
  - Stream selection, date ranges, notifications
  - Chart types, inputs, and generic UI helpers

### Test Files Fixed (5/8 - 62.5%)
- ✅ **metrics-advanced.spec.js**: Fixed 13 POM violations
- ✅ **metrics-aggregations.spec.js**: Fixed 8 POM violations
- ✅ **metrics-config-tabs.spec.js**: Fixed 31/33 POM violations
- ✅ **metrics-queries.spec.js**: Fixed 28 POM violations
- ✅ **metrics-visualizations.spec.js**: Fixed 44 POM violations

### Additional Fixes
- **apiCleanup.js**: Fixed error handling consistency
  - Unified error response format (message vs error field)
  - Added explicit code: 200 for successful responses

## Statistics
- **Violations Fixed**: 132/184 (72%)
- **Helper Functions Refactored**: 3 (eliminated 200+ lines of duplication)
- **All fixed files**: ✓ Syntax validated

## Remaining Work
- metrics-config.spec.js: 28 violations
- metrics.spec.js: 30 violations
- See POM_COMPLIANCE_FIXES_SUMMARY.md for completion guide

🤖 Generated with [Claude Code](https://claude.com/claude-code)

Co-Authored-By: Claude Sonnet 4.5 <noreply@anthropic.com>
2026-01-16 18:48:25 +05:30
priyabrata-stackandClaude Sonnet 4.5 a7f2d458d1 fix: correct deleteMetricsStream API call parameters
- Add delete_all=true parameter for complete stream deletion
- Change error return format to use 'message' field (consistent with logs cleanup)
- Ensures metrics cleanup matches logs cleanup pattern

🤖 Generated with [Claude Code](https://claude.com/claude-code)

Co-Authored-By: Claude Sonnet 4.5 <noreply@anthropic.com>
2026-01-16 18:48:25 +05:30
priyabrata-stackandClaude Sonnet 4.5 626e7bd9fa fix: add safety check to metrics cleanup to prevent accidental deletion
Add validation to ensure patterns array is not empty before attempting
to clean up metrics streams. This prevents accidental deletion of all
metrics streams if the method is called without proper patterns.

Safety improvement for cleanupMetricsStreams() method.

🤖 Generated with [Claude Code](https://claude.com/claude-code)

Co-Authored-By: Claude Sonnet 4.5 <noreply@anthropic.com>
2026-01-16 18:48:25 +05:30
priyabrata-stackandClaude Sonnet 4.5 0a8d1e4312 test: add metrics streams cleanup to pre-test cleanup
Add metrics-specific cleanup methods to handle test metrics data:
- Add fetchMetricsStreams() to fetch metrics streams via API
- Add deleteMetricsStream() to delete individual metrics streams
- Add cleanupMetricsStreams() to clean up test metrics streams

Update cleanup.spec.js to include metrics cleanup:
- Clean up test metrics streams matching patterns
- Protect 'default' metrics stream (primary test stream)
- Support patterns: test_*_metrics, e2e_metrics_*, otlp_test_*, etc.

This ensures metrics test data is cleaned up between test runs,
similar to existing logs stream cleanup.

🤖 Generated with [Claude Code](https://claude.com/claude-code)

Co-Authored-By: Claude Sonnet 4.5 <noreply@anthropic.com>
2026-01-16 18:48:25 +05:30
Shrinath Rao 8bf9eac8a2 test: Functions test suite rework - 67% reduction with full validation coverage (#9957)
## Summary

Rework of the Functions test suite to reduce test count while
maintaining 100% validation coverage.

| Metric | Before | After | Change |
|--------|--------|-------|--------|
| **UI Tests** | 36 | 12 | **-67%** |
| **API Tests (Python)** | 0 | 16 | +16 new |
| **Validation coverage** | 100% | 100% | Preserved |
| **CI Integration** | ❌ | ✅ | Added |

**Cleanup performed:**
- 3 placeholder tests removed (only had logging, no assertions)
- 1 duplicate test removed
- 4 cross-file duplicates deduplicated

## What Changed

### Test File Consolidation

| Original Spec Files | Final Spec File | Original | Final | Reduction |
|---------------------|-----------------|----------|-------|-----------|
| `meta-org-js-restriction.spec.js` + `javascript-functions.spec.js` |
`js-transform-type.spec.js` | 22 | 6 | 73% |
| `result-array-functions.spec.js` | `row-expansion.spec.js` | 14 | 6 |
57% |
| **Total** | **2 files** | **36** | **12** | **67%** |

### New Python API Tests

Added 16 comprehensive API tests in
`tests/api-testing/tests/test_functions_meta_org_restriction.py`:

| Category | Count | Tests |
|----------|-------|-------|
| JS Restriction (blocked in default org) | 5 | create/test/update
blocked |
| VRL Functions (work in default org) | 4 | create/test/update works |
| Auto-Detection | 2 | trans_type auto-detection |
| Error Messages | 2 | content and consistency |
| Edge Cases | 3 | empty/invalid/case-sensitivity |

### Critical Bugs Fixed

1. **Missing `_meta` org navigation** - JavaScript functions are ONLY
allowed in `_meta` organization. Tests were navigating to default org.
2. **Python API tests using wrong field names** - Create/Update use
`transType` (camelCase), Test endpoint uses `trans_type` (snake_case).
3. **Missing pipeline cleanup pattern** - Added `realfile*` pattern that
was causing 409 errors.

## Files Modified

### UI Tests (Final)
-
`tests/ui-testing/playwright-tests/Functions/js-transform-type.spec.js`
(6 tests)
- `tests/ui-testing/playwright-tests/Functions/row-expansion.spec.js` (6
tests)

### UI Tests (Removed/Consolidated)
- `meta-org-js-restriction.spec.js` → merged into
`js-transform-type.spec.js`
- `javascript-functions.spec.js` → merged into
`js-transform-type.spec.js`
- `result-array-functions.spec.js` → renamed to `row-expansion.spec.js`

### Cleanup Infrastructure
- `tests/ui-testing/playwright-tests/cleanup.spec.js` - Consolidated
function cleanup, added realfile* pattern
- `tests/ui-testing/pages/apiCleanup.js` - Added org-aware cleanup
methods

### API Tests (New)
- `tests/api-testing/tests/test_functions_meta_org_restriction.py` - 16
new tests

### CI Integration
- `.github/workflows/playwright.yml` - Added Functions test matrix entry

## Final Test List (12 UI Tests)

### js-transform-type.spec.js (6 tests)
| # | Test | Priority |
|---|------|----------|
| 1 | P0: JavaScript function creation flow in _meta org | @smoke, @P0 |
| 2 | P0: JS function creation and validation flow | @smoke, @P0 |
| 3 | P1: JS function execution and error handling | @P1 |
| 4 | P1: JS function error cases | @P1 |
| 5 | P0: Default org - JS hidden, VRL works | @smoke, @P0 |
| 6 | P1: Radio visibility across orgs | @P1 |

### row-expansion.spec.js (6 tests)
| # | Test | Priority |
|---|------|----------|
| 1 | P0: VRL row expansion creation and validation flow | @smoke, @P0 |
| 2 | P2: VRL row expansion edge cases | @P2 |
| 3 | P0: JS row expansion creation and validation flow | @smoke, @P0 |
| 4 | P1: JS row expansion edge cases and transformations | @P1 |
| 5 | P1: Compare VRL and JS row expansion output | @P1 |
| 6 | P1: Pipeline integration and error handling | @P1 |

## Test plan

- [x] All 12 UI tests passing locally
- [x] All 16 Python API tests passing locally
- [x] Sentinel audit passed (POM compliant, no raw selectors)
- [x] Hard assertions applied (no soft assertions)
- [ ] CI pipeline runs successfully
2026-01-10 07:49:28 +05:30
Shrinath RaoandClaude Opus 4.5 d852e7656b test: refactor alerts module with POM architecture and comprehensive e2e coverage (#9717)
### **User description**
## Summary
Complete refactoring of the Alerts UI testing module with Page Object
Model architecture, comprehensive E2E test coverage, and improved test
stability.

## Key Changes

### 🏗️ Architecture Refactoring
Refactored monolithic `AlertsPage` (2300+ lines) into modular Page
Object classes:

| Module | Responsibility |
|--------|---------------|
| `AlertCreationWizard` | Alert creation flows (real-time, scheduled,
multi-condition, deduplication) |
| `AlertManagement` | CRUD operations (update, clone, pause, resume,
delete, search) |
| `AlertBulkOperations` | Bulk operations (select, pause/unpause, move
across folders) |
| `AlertsPage` | Main entry point, folder operations, UI validations,
import/export |

### 🧪 Test Coverage
All 12 Alerts tests passing:

| Spec File | Tests | Coverage |
|-----------|-------|----------|
| `alerts-e2e-flow.spec.js` | 1 | Complete E2E flow: CRUD, clone,
pause/resume, move, search |
| `alerts-ui-operations.spec.js` | 4 | Template/destination CRUD,
scheduled alerts, UI validations |
| `alerts-import.spec.js` | 3 | Import/export alerts, templates,
destinations (URL + file) |
| `alerts-advanced.spec.js` | 4 | Multi-condition alerts, AND/OR toggle,
bulk operations, deduplication |

### 🔧 Stability Fixes
- Added `test.slow()` for long-running E2E flow test
- Fixed `moveAllAlertsToFolder` with proper success message assertion
- Fixed `deleteAllAlertsInFolder` by removing redundant verification
- Fixed `verifyAlertCreated` with navigation fallback for reliability
- Fixed `selectMultipleAlerts` with visibility check and search fallback
- Added post-creation waits in alert wizard to handle async UI updates

### 📝 Code Quality
- Cleaned up redundant comments across all alerts files
- Removed obvious "what" comments, kept meaningful "why" explanations
- Preserved section dividers for navigation in long methods
- Maintained JSDoc for method documentation

## New Page Object Methods

### AlertCreationWizard
- `createAlert()` - Standard real-time alert with column/operator/value
- `createAlertWithDefaults()` - Resilient creation using first available
column
- `createScheduledAlertWithSQL()` - Scheduled alert with SQL query
- `createAlertWithMultipleConditions()` - Multi-condition alert with AND
operator
- `createScheduledAlertWithDeduplication()` - Scheduled alert with dedup
config
- `testConditionOperatorToggle()` - Tests AND/OR toggle functionality

### AlertManagement
- `updateAlert()` - Edit alert via wizard
- `cloneAlert()` - Clone with stream selection
- `pauseAlert()` / `resumeAlert()` - Toggle alert state
- `deleteAlertByRow()` / `deleteImportedAlert()` - Delete operations
- `searchAlert()` / `searchAndDeleteAlert()` - Search operations

### AlertBulkOperations
- `selectMultipleAlerts()` - Select multiple alerts for bulk ops
- `bulkPauseAlerts()` / `bulkUnpauseAlerts()` - Bulk state toggle
- `moveAllAlertsToFolder()` - Move alerts between folders
- `deleteAllAlertsInFolder()` - Clean folder contents

## Test Results
```
Running 12 tests using 4 workers
12 passed (~6.2m)
```

## Test Plan
- [x] All 12 alerts tests passing locally
- [x] Tests are independent and cleanup after themselves
- [x] No regressions in existing functionality


___

### **PR Type**
Enhancement, Tests


___

### **Description**
- Refactor AlertsPage into modular PageObjects

- Centralize and expose locators in a map

- Delegate creation, management, bulk operations

- Add advanced E2E tests for multi-condition, bulk, dedup features

- Enhance LogsPage.selectStream with configurable wait


___

### Diagram Walkthrough


```mermaid
flowchart LR
  AP["AlertsPage"]
  ACW["AlertCreationWizard"]
  AM["AlertManagement"]
  ABO["AlertBulkOperations"]

  AP -- "delegates to" --> ACW
  AP -- "delegates to" --> AM
  AP -- "delegates to" --> ABO
```



<details> <summary><h3> File Walkthrough</h3></summary>

<table><thead><tr><th></th><th align="left">Relevant
files</th></tr></thead><tbody><tr><td><strong>Enhancement</strong></td><td><details><summary>5
files</summary><table>
<tr>
<td><strong>alertsPage.js</strong><dd><code>Modularize AlertsPage with
submodules and locators</code>&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp;
&nbsp; </dd></td>
<td><a
href="https://github.com/openobserve/openobserve/pull/9717/files#diff-79ee01d6d7f145f19207b93b87143b545a1188cfc6a82bc8c45fecfbf68f8a1d">+569/-1059</a></td>

</tr>

<tr>
<td><strong>alertManagement.js</strong><dd><code>Introduce
AlertManagement module for CRUD</code>&nbsp; &nbsp; &nbsp; &nbsp; &nbsp;
&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp;
&nbsp; </dd></td>
<td><a
href="https://github.com/openobserve/openobserve/pull/9717/files#diff-53afe97106daddb1fb35c3624ccedc99f21476946edc181f6287f7e8fd1bbf37">+509/-0</a>&nbsp;
</td>

</tr>

<tr>
<td><strong>alertCreationWizard.js</strong><dd><code>Introduce
AlertCreationWizard module</code>&nbsp; &nbsp; &nbsp; &nbsp; &nbsp;
&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp;
&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; </dd></td>
<td><a
href="https://github.com/openobserve/openobserve/pull/9717/files#diff-3b0a08b55d132502596d17c9d5f197de6d4779684de96ce570282e2402942e2e">+1024/-0</a></td>

</tr>

<tr>
<td><strong>alertBulkOperations.js</strong><dd><code>Introduce
AlertBulkOperations module</code>&nbsp; &nbsp; &nbsp; &nbsp; &nbsp;
&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp;
&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; </dd></td>
<td><a
href="https://github.com/openobserve/openobserve/pull/9717/files#diff-dea39c18fea38783c9ef4ae71e11021eaa3663b7012ae1c481a30277139a6907">+299/-0</a>&nbsp;
</td>

</tr>

<tr>
<td><strong>logsPage.js</strong><dd><code>Enhance selectStream with
apiWaitMs parameter</code>&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp;
&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; </dd></td>
<td><a
href="https://github.com/openobserve/openobserve/pull/9717/files#diff-8045b343491d8943869c1af74cdafab204dc49c02a70294417e73f47d35e0b59">+10/-6</a>&nbsp;
&nbsp; </td>

</tr>

</table></details></td></tr><tr><td><strong>Tests</strong></td><td><details><summary>1
files</summary><table>
<tr>
<td><strong>alerts-advanced.spec.js</strong><dd><code>Add advanced E2E
tests for alerts features</code>&nbsp; &nbsp; &nbsp; &nbsp; &nbsp;
&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp;
</dd></td>
<td><a
href="https://github.com/openobserve/openobserve/pull/9717/files#diff-710af4a4eaad54a1ddd5acf0d62f977bfa18c95462b38c4f84593a970297754d">+194/-0</a>&nbsp;
</td>

</tr>
</table></details></td></tr><tr><td><strong>Additional
files</strong></td><td><details><summary>8 files</summary><table>
<tr>
  <td><strong>alertDestinationsPage.js</strong></td>
<td><a
href="https://github.com/openobserve/openobserve/pull/9717/files#diff-57e5c53b4ef998b3d8708149620ff94dcc46807927f1a3a9e9f28ed3ebe25b0a">+95/-0</a>&nbsp;
&nbsp; </td>

</tr>

<tr>
  <td><strong>alertTemplatesPage.js</strong></td>
<td><a
href="https://github.com/openobserve/openobserve/pull/9717/files#diff-f4ebd248b2140051e74dbbbd1aabe344f01c80704ce5857e9c28a04350e018f3">+74/-4</a>&nbsp;
&nbsp; </td>

</tr>

<tr>
  <td><strong>apiCleanup.js</strong></td>
<td><a
href="https://github.com/openobserve/openobserve/pull/9717/files#diff-537fe76c0d8e26e81c5f77c83bd0ee35daaa973822105c809bf83171a26b33c5">+133/-221</a></td>

</tr>

<tr>
  <td><strong>commonActions.js</strong></td>
<td><a
href="https://github.com/openobserve/openobserve/pull/9717/files#diff-4d726dd2bdb34b2c90a31798ff49b6df5bc952bd049b7c38bebb18b6db0076e2">+156/-0</a>&nbsp;
</td>

</tr>

<tr>
  <td><strong>alerts-e2e-flow.spec.js</strong></td>
<td><a
href="https://github.com/openobserve/openobserve/pull/9717/files#diff-32972e38c1fe0e8bb887f9f254b3130916a36f96ea924f9987493d44efefeab9">+38/-23</a>&nbsp;
</td>

</tr>

<tr>
  <td><strong>alerts-import.spec.js</strong></td>
<td><a
href="https://github.com/openobserve/openobserve/pull/9717/files#diff-62b6ec4818685eacc0a934d68aaadfd73b512ef4f4be25fcd5135b97c2844912">+54/-106</a></td>

</tr>

<tr>
  <td><strong>alerts-ui-operations.spec.js</strong></td>
<td><a
href="https://github.com/openobserve/openobserve/pull/9717/files#diff-c9b523b5f5dea834b69abdf20f4acef361bdf37b1585c450e10238b1d1984f2e">+38/-82</a>&nbsp;
</td>

</tr>

<tr>
  <td><strong>cleanup.spec.js</strong></td>
<td><a
href="https://github.com/openobserve/openobserve/pull/9717/files#diff-c214275a512fa285a7e4f2ab61dfcb42d71a0436b0e4241f94d7b45693587983">+3/-1</a>&nbsp;
&nbsp; &nbsp; </td>

</tr>
</table></details></td></tr></tr></tbody></table>

</details>

___

---------

Co-authored-by: Claude Opus 4.5 <noreply@anthropic.com>
2025-12-29 21:07:00 +05:30
ktx-akshayandktx-abhay e96db6332b test(dashboard): fix flaky tests in deployed environment (#9511)
### **User description**
…riables


___

### **PR Type**
Tests, Enhancement


___

### **Description**
- Refine chart-render wait logic with class checks

- Integrate values-stream helper in variable dropdown

- Standardize relative time ranges to 30m

- Improve streaming test with API wait loops


___



<details> <summary><h3> File Walkthrough</h3></summary>

<table><thead><tr><th></th><th align="left">Relevant
files</th></tr></thead><tbody><tr><td><strong>Formatting</strong></td><td><details><summary>2
files</summary><table>
<tr>
<td><strong>apiCleanup.js</strong><dd><code>Remove extraneous newline at
EOF</code>&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp;
&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp;
&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; </dd></td>
<td><a
href="https://github.com/openobserve/openobserve/pull/9511/files#diff-537fe76c0d8e26e81c5f77c83bd0ee35daaa973822105c809bf83171a26b33c5">+1/-1</a>&nbsp;
&nbsp; &nbsp; </td>

</tr>

<tr>
<td><strong>cleanup.spec.js</strong><dd><code>Remove trailing blank
line</code>&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp;
&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp;
&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp;
&nbsp; &nbsp; &nbsp; </dd></td>
<td><a
href="https://github.com/openobserve/openobserve/pull/9511/files#diff-c214275a512fa285a7e4f2ab61dfcb42d71a0436b0e4241f94d7b45693587983">+1/-0</a>&nbsp;
&nbsp; &nbsp; </td>

</tr>

</table></details></td></tr><tr><td><strong>Enhancement</strong></td><td><details><summary>4
files</summary><table>
<tr>
<td><strong>dashboard-panel-actions.js</strong><dd><code>Refine
waitForChartToRender class checks</code>&nbsp; &nbsp; &nbsp; &nbsp;
&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp;
&nbsp; &nbsp; &nbsp; </dd></td>
<td><a
href="https://github.com/openobserve/openobserve/pull/9511/files#diff-d29713fdcc11cbc93bda29da5261da389226cd718e4292a1c2cd96629f573a80">+27/-10</a>&nbsp;
</td>

</tr>

<tr>
<td><strong>dashboard-variables.js</strong><dd><code>Add stream helper
and input typing delay</code>&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp;
&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp;
&nbsp; </dd></td>
<td><a
href="https://github.com/openobserve/openobserve/pull/9511/files#diff-67d38d39bb67f4a0cbfa473ee81ad50b1fffebc40c635417e58905f3c865a6e2">+18/-3</a>&nbsp;
&nbsp; </td>

</tr>

<tr>
<td><strong>dashboard-streaming.spec.js</strong><dd><code>Add API wait
loops in streaming test</code>&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp;
&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp;
&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; </dd></td>
<td><a
href="https://github.com/openobserve/openobserve/pull/9511/files#diff-92f44296937f53cb448371d1c61510c8c910fbecab83b02b8e89490d5832be19">+36/-4</a>&nbsp;
&nbsp; </td>

</tr>

<tr>
<td><strong>streaming-helpers.js</strong><dd><code>Implement
waitForValuesStreamComplete utility</code>&nbsp; &nbsp; &nbsp; &nbsp;
&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; </dd></td>
<td><a
href="https://github.com/openobserve/openobserve/pull/9511/files#diff-ba793998d7c077815ee18543001a519b7d45a9236990b60d256124a4b30d48cb">+65/-1</a>&nbsp;
&nbsp; </td>

</tr>

</table></details></td></tr><tr><td><strong>Tests</strong></td><td><details><summary>6
files</summary><table>
<tr>
<td><strong>dashboard-geoMap.spec.js</strong><dd><code>Update time range
to 30m</code>&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp;
&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp;
&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp;
&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; </dd></td>
<td><a
href="https://github.com/openobserve/openobserve/pull/9511/files#diff-6ae8394cd6b915e6d55a179cf6c7dc32992b8ebbd5d9aac177c0cbd1b9f351b3">+1/-1</a>&nbsp;
&nbsp; &nbsp; </td>

</tr>

<tr>
<td><strong>dashboard-html-chart.spec.js</strong><dd><code>Set html
chart time to 30m</code>&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp;
&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp;
&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp;
&nbsp; &nbsp; &nbsp; &nbsp; </dd></td>
<td><a
href="https://github.com/openobserve/openobserve/pull/9511/files#diff-02c503aa87193168f5aa83c8105c376ea0c4dc45e6c7bd6f255b693bf7ebc462">+1/-1</a>&nbsp;
&nbsp; &nbsp; </td>

</tr>

<tr>
<td><strong>dashboard-multi-y-axis.spec.js</strong><dd><code>Update
multi-y-axis time to 30m</code>&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp;
&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp;
&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp;
</dd></td>
<td><a
href="https://github.com/openobserve/openobserve/pull/9511/files#diff-e90516a105c0b17c8e04c18e2b67ac10af213dbdd208fa4414cdcb7e377e6ee5">+2/-2</a>&nbsp;
&nbsp; &nbsp; </td>

</tr>

<tr>
<td><strong>dashboard-transpose.spec.js</strong><dd><code>Change
transpose time range to 30m</code>&nbsp; &nbsp; &nbsp; &nbsp; &nbsp;
&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp;
&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; </dd></td>
<td><a
href="https://github.com/openobserve/openobserve/pull/9511/files#diff-da631007cea76a4bc59e4acd1195b59ae4131cd5208d21a9c1f94d3913911dc4">+1/-1</a>&nbsp;
&nbsp; &nbsp; </td>

</tr>

<tr>
<td><strong>dashboard.spec.js</strong><dd><code>Adjust gauge and table
time ranges to 15m</code>&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp;
&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp;
</dd></td>
<td><a
href="https://github.com/openobserve/openobserve/pull/9511/files#diff-d0fa0042783dc109334b05266edce228bad97adcb568dd1e447920596238e9b4">+5/-5</a>&nbsp;
&nbsp; &nbsp; </td>

</tr>

<tr>
<td><strong>dashboard2.spec.js</strong><dd><code>Standardize dashboard2
time to 30m</code>&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp;
&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp;
&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; </dd></td>
<td><a
href="https://github.com/openobserve/openobserve/pull/9511/files#diff-8c9189e9e3950fff987c45ee8116d89f15f8fdec5baad209bef6f5858f3b3045">+7/-7</a>&nbsp;
&nbsp; &nbsp; </td>

</tr>
</table></details></td></tr><tr><td><strong>Configuration
changes</strong></td><td><details><summary>1 files</summary><table>
<tr>
<td><strong>playwright.yml</strong><dd><code>Fix typo in run_files
list</code>&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp;
&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp;
&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp;
&nbsp; &nbsp; &nbsp; </dd></td>
<td><a
href="https://github.com/openobserve/openobserve/pull/9511/files#diff-7afcd2d8f7b49bda74843f209eefb7b2da45f7e7803bf2e4bd636699b76aa2d3">+1/-0</a>&nbsp;
&nbsp; &nbsp; </td>

</tr>
</table></details></td></tr></tr></tbody></table>

</details>

___

---------

Co-authored-by: ktx-abhay <abhay.padamani@kiara.tech>
2025-12-17 15:23:43 +05:30
Shrinath Rao e0d23c42a7 fix(e2e): resolve SDR test failures with test isolation and retry logic (#9632)
## Summary
- Add unique testRunId to pattern and stream names for test isolation
during parallel execution
- Add retry logic to `checkPatternExists` for backend indexing delays (3
attempts with 2s wait)
- Add search box filtering in `selectStream` for reliable stream
selection in long lists
- Add retry logic for Stream Detail button in stream association page
- Fix ingestion retry with exponential backoff for "stream being
deleted" errors
- Update regexPatternManagement test with unique pattern names to avoid
conflicts

## Test plan
- [x] All 23 SDR tests pass reliably in parallel execution
- [x] Verified tests pass when run individually and as a suite
- [x] No regressions in other test suites
2025-12-15 15:55:46 +05:30
Shrinath Rao 790bd9a0bd test: e2e streams race condition fix (#9631) 2025-12-13 10:18:20 +05:30
Shrinath Rao d1dc54ff42 test: updated cleanup spec file to follow framework and add more pipe… (#9543)
…line patterns
2025-12-09 21:52:08 +05:30
Shrinath Rao 6ae38d5ce2 test(e2e): refactor pipeline condition tests and fix data ingestion timeout (#9528)
## Summary
Refactored pipeline condition tests into 2 new spec files for better
organization and maintainability, fixed data ingestion timeout issue,
and added comprehensive test coverage for pipeline conditions.

## Changes
- Refactored pipeline condition tests into 2 new spec files for better
organization
- Added 14 new comprehensive test cases (7 UI-based + 7 API-based
validation tests)
- Fixed beforeEach timeout issue by reducing data ingestion from 3,800+
to 10 records per stream
- Added cleanup patterns for `e2e_conditions_*` streams to prevent data
accumulation
- Updated apiCleanup.js to include 7 new stream names in pipeline
cleanup
- Removed outdated comments referencing conditional wait logic
- Added page object methods for condition testing in pipelinesPage.js,
logsPage.js, and streamsPage.js

## Test Coverage

### pipeline-conditions.spec.js (7 tests - all passing ✅)
- Basic condition operations with multiple operators (=, !=, Contains,
NotContains, >=)
- Condition groups, nesting, and reordering
- Field validation and error messages
- Complex operator precedence (A OR B AND C)
- Multiple conditions (A, B, C, D)
- Condition node deletion
- Comparison operators validation

### pipeline-conditions-validation.spec.js (7 tests - API-based)
- Operator precedence validation
- Nested groups with AND/OR logic
- Numeric comparisons
- String operators (case-insensitive Contains)

## Performance
- Reduced test execution time from 180s timeout to ~4.6 minutes for full
suite
- 100% pass rate for active UI tests (7/7)

## Files Changed
- `.github/workflows/playwright.yml` - Updated test configuration
- `tests/test-data/data_100.json` - Added test data for validation tests
- `tests/test-data/sample_pipeline_template.json` - Added pipeline
template
- `tests/ui-testing/pages/apiCleanup.js` - Added stream cleanup patterns
- `tests/ui-testing/pages/pipelinesPages/pipelinesPage.js` - Added
condition testing methods
- `tests/ui-testing/pages/logsPages/logsPage.js` - Added data ingestion
helpers
- `tests/ui-testing/pages/streamsPages/streamsPage.js` - Added stream
management helpers
-
`tests/ui-testing/playwright-tests/Pipelines/pipeline-conditions.spec.js`
- Refactored UI tests
-
`tests/ui-testing/playwright-tests/Pipelines/pipeline-conditions-validation.spec.js`
- New API validation tests
- `tests/ui-testing/playwright-tests/cleanup.spec.js` - Added
e2e_conditions_* pattern

## Testing
All 7 UI-based tests passing with 100% pass rate.
2025-12-09 15:49:28 +05:30
Shrinath Rao b3ed038bc4 test: updated cleanup spec file (#9487) 2025-12-05 08:47:24 +05:30
Shrinath Rao 7c3ed151fe test: added saved view cleanup to cleanup spec file (#9451) 2025-12-03 21:14:46 +05:30
Shrinath Rao f74c90413b test: stabilising logs core, reports, pipelines import tests for env (#9246) 2025-11-25 10:55:20 +05:30
Shrinath Rao 264316516d test: env runs stabilisation fix, sdr, reports (#9242) 2025-11-22 15:39:20 +05:30
Shrinath Rao 7a37f760e9 test: stabilised logo management test and added cleanup for logo mana… (#9234)
…gement
2025-11-21 17:28:06 +05:30
Shrinath RaoandYashodhan Joshi 98e35c1632 test: added ent tags to all enterprise tests (#9040)
Co-authored-by: Yashodhan Joshi <yashodhan@openobserve.ai>
2025-11-11 15:14:33 +05:30
Shrinath Rao f61b715a1e test: Cleanup Mechanism and ENV Runs for e2e tests (#8839)
### **PR Type**
Enhancement, Tests


___

### **Description**
- Add robust alerts cleanup utilities

- Improve UI flows and resiliency

- Support deployed env testing delays

- Add CI cleanup and health checks


___

### Diagram Walkthrough


```mermaid
flowchart LR
  UI["Playwright UI flows hardened"]
  API["APICleanup cascade (Alerts→Folders→Destinations→Templates)"]
  CI["CI workflow targets deployed env"]
  Delay["Configurable test step delay"]
  Data["Global ingestion more robust"]

  UI -- "uses" --> API
  CI -- "runs cleanup.spec" --> API
  CI -- "health checks + env vars" --> Data
  Delay -- "slows page ops" --> UI
  Data -- "ingest logs with parsing" --> UI
```



<details> <summary><h3> File Walkthrough</h3></summary>

<table><thead><tr><th></th><th align="left">Relevant
files</th></tr></thead><tbody><tr><td><strong>Enhancement</strong></td><td><details><summary>7
files</summary><table>
<tr>
<td><strong>alertDestinationsPage.js</strong><dd><code>Add search,
cascade-safe delete, bulk prefix cleanup</code>&nbsp; &nbsp; &nbsp;
&nbsp; &nbsp; </dd></td>
<td><a
href="https://github.com/openobserve/openobserve/pull/8839/files#diff-57e5c53b4ef998b3d8708149620ff94dcc46807927f1a3a9e9f28ed3ebe25b0a">+178/-0</a>&nbsp;
</td>

</tr>

<tr>
<td><strong>alertTemplatesPage.js</strong><dd><code>Add template search,
in-use handling, prefix cleanup</code>&nbsp; &nbsp; &nbsp; &nbsp; &nbsp;
</dd></td>
<td><a
href="https://github.com/openobserve/openobserve/pull/8839/files#diff-f4ebd248b2140051e74dbbbd1aabe344f01c80704ce5857e9c28a04350e018f3">+177/-2</a>&nbsp;
</td>

</tr>

<tr>
<td><strong>alertsPage.js</strong><dd><code>Harden alert actions, bulk
deletion, search across folders</code></dd></td>
<td><a
href="https://github.com/openobserve/openobserve/pull/8839/files#diff-79ee01d6d7f145f19207b93b87143b545a1188cfc6a82bc8c45fecfbf68f8a1d">+280/-9</a>&nbsp;
</td>

</tr>

<tr>
<td><strong>apiCleanup.js</strong><dd><code>New API-based cascade
cleanup utility</code>&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp;
&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp;
&nbsp; &nbsp; &nbsp; </dd></td>
<td><a
href="https://github.com/openobserve/openobserve/pull/8839/files#diff-537fe76c0d8e26e81c5f77c83bd0ee35daaa973822105c809bf83171a26b33c5">+399/-0</a>&nbsp;
</td>

</tr>

<tr>
<td><strong>page-manager.js</strong><dd><code>Wire APICleanup into
PageManager</code>&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp;
&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp;
&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; </dd></td>
<td><a
href="https://github.com/openobserve/openobserve/pull/8839/files#diff-565eab8b3c767ae50c9d05e591621d14f66b81af84d6b5ea6efe136c1c3933df">+4/-0</a>&nbsp;
&nbsp; &nbsp; </td>

</tr>

<tr>
<td><strong>baseFixtures.js</strong><dd><code>Add configurable test step
delay hooks</code>&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp;
&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp;
&nbsp; &nbsp; </dd></td>
<td><a
href="https://github.com/openobserve/openobserve/pull/8839/files#diff-c4c5ee7fbb248d1ab14d3d4e33ffb9626f9aab74c9e0207fcfc08051c8c3c7ee">+46/-0</a>&nbsp;
&nbsp; </td>

</tr>

<tr>
<td><strong>global-setup.js</strong><dd><code>Harden login and ingestion
with diagnostics</code>&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp;
&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; </dd></td>
<td><a
href="https://github.com/openobserve/openobserve/pull/8839/files#diff-06323dad7214f86b41b62e121e716eeea0054bc4d950c6bcf4a0efe53894acc8">+61/-22</a>&nbsp;
</td>

</tr>
</table></details></td></tr><tr><td><strong>Bug
fix</strong></td><td><details><summary>1 files</summary><table>
<tr>
<td><strong>commonActions.js</strong><dd><code>Fix ingestion URLs to use
org variable</code>&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp;
&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp;
&nbsp; &nbsp; </dd></td>
<td><a
href="https://github.com/openobserve/openobserve/pull/8839/files#diff-4d726dd2bdb34b2c90a31798ff49b6df5bc952bd049b7c38bebb18b6db0076e2">+4/-4</a>&nbsp;
&nbsp; &nbsp; </td>

</tr>

</table></details></td></tr><tr><td><strong>Tests</strong></td><td><details><summary>4
files</summary><table>
<tr>
<td><strong>alerts-e2e-flow.spec.js</strong><dd><code>Pre-move folder
cleanup and stabilization</code>&nbsp; &nbsp; &nbsp; &nbsp; &nbsp;
&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp;
&nbsp; </dd></td>
<td><a
href="https://github.com/openobserve/openobserve/pull/8839/files#diff-32972e38c1fe0e8bb887f9f254b3130916a36f96ea924f9987493d44efefeab9">+13/-3</a>&nbsp;
&nbsp; </td>

</tr>

<tr>
<td><strong>alerts-import.spec.js</strong><dd><code>Use dedicated
invalid import test data</code>&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp;
&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp;
&nbsp; &nbsp; &nbsp; </dd></td>
<td><a
href="https://github.com/openobserve/openobserve/pull/8839/files#diff-62b6ec4818685eacc0a934d68aaadfd73b512ef4f4be25fcd5135b97c2844912">+1/-1</a>&nbsp;
&nbsp; &nbsp; </td>

</tr>

<tr>
<td><strong>cleanup.spec.js</strong><dd><code>New pre-test API cleanup
spec</code>&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp;
&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp;
&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp;
</dd></td>
<td><a
href="https://github.com/openobserve/openobserve/pull/8839/files#diff-c214275a512fa285a7e4f2ab61dfcb42d71a0436b0e4241f94d7b45693587983">+29/-0</a>&nbsp;
&nbsp; </td>

</tr>

<tr>
<td><strong>invalid-alert.json</strong><dd><code>Add invalid alert
sample for import tests</code>&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp;
&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp;
</dd></td>
<td><a
href="https://github.com/openobserve/openobserve/pull/8839/files#diff-c695f71048e9393a45d3e3e3e415696559fecf3ba85712e7c3f366092f53f424">+24/-0</a>&nbsp;
&nbsp; </td>

</tr>
</table></details></td></tr><tr><td><strong>Configuration
changes</strong></td><td><details><summary>1 files</summary><table>
<tr>
<td><strong>playwright.yml</strong><dd><code>Target deployed env; add
cleanup job and health checks</code>&nbsp; &nbsp; &nbsp; </dd></td>
<td><a
href="https://github.com/openobserve/openobserve/pull/8839/files#diff-7afcd2d8f7b49bda74843f209eefb7b2da45f7e7803bf2e4bd636699b76aa2d3">+123/-65</a></td>

</tr>
</table></details></td></tr></tr></tbody></table>

</details>

___
2025-11-04 23:54:54 +05:30