Files
openobserve/.github/workflows
Shrinath Rao 65c3ccbaff test(e2e): fix and enable scheduled pipeline query builder tests (#10161)
### **User description**
## Summary
This PR fixes a previously skipped E2E test and makes the scheduled
pipeline query builder tests fully functional.

### Root Cause Analysis
The PromQL tab test was skipped because the selectors were incorrect:
- **Issue**: Test used `getByRole('button', { name: /PromQL/i })` but
AppTabs.vue renders tabs as `<div>` elements, not buttons
- **Fix**: Updated POM methods to use `[data-test="tab-promql"]` and
`[data-test="tab-sql"]` selectors
- **Active state check**: Changed from `aria-selected` to CSS class
`active` (how AppTabs indicates selected tab)

### Changes

**pipelinesPage.js**
- Added `clickPromqlTab()` - clicks PromQL tab using correct selector
- Added `clickSqlTab()` - clicks SQL tab using correct selector  
- Added `expectPromqlTabActive()` - verifies PromQL tab is active via
CSS class
- Added `expectSqlTabActive()` - verifies SQL tab is active via CSS
class
- Added `selectFirstAvailableStreamOption()` - helper for stream
selection

**scheduled-pipeline-query-builder.spec.js** (renamed from
scheduled-pipeline-stream-auto-update.spec.js)
- Renamed file to better reflect what it tests (query builder behavior,
not stream auto-update)
- Updated test.describe name to match
- Enabled previously skipped PromQL tab test
- Added metrics data ingestion to ensure metrics streams exist for
PromQL testing

**playwright.yml**
- Added `scheduled-pipeline-query-builder.spec.js` to Pipelines CI
run_files

## Test Results
```
✅ should auto-generate SELECT * query when stream changes - PASSED
✅ should handle initial stream selection (existing behavior) - PASSED
✅ should not update PromQL tab when stream changes - PASSED

3 passed (2.0m)
```

Tested on both local and deployed environment
(test.internal.zinclabs.dev).

## Test Plan
- [x] All 3 tests pass locally
- [x] All 3 tests pass on deployed environment
- [x] Sentinel code quality audit passed (0 critical issues)
- [x] No validation logic or test flow changes - only selector fixes


___

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


___

### **Description**
- Add POM methods for pipeline tab interactions

- Rename and enable scheduled pipeline query builder tests

- Replace raw selectors with POM methods

- Include new spec in CI workflow


___

### Diagram Walkthrough


```mermaid
flowchart LR
  POM["pipelinesPage POM"]
  Spec["Scheduled pipeline query builder spec"]
  CI["playwright.yml CI workflow"]
  POM -- "add tab & stream methods" --> Spec
  Spec -- "included in run_files" --> CI
```



<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>pipelinesPage.js</strong><dd><code>Add POM methods for
scheduled pipeline tabs</code>&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp;
&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; </dd></summary>
<hr>

tests/ui-testing/pages/pipelinesPages/pipelinesPage.js

<ul><li>Added <code>selectFirstAvailableStreamOption</code> helper<br>
<li> Added <code>clickPromqlTab</code> and <code>clickSqlTab</code>
methods<br> <li> Added <code>expectPromqlTabActive</code> and
<code>expectSqlTabActive</code> checks</ul>


</details>


  </td>
<td><a
href="https://github.com/openobserve/openobserve/pull/10161/files#diff-d5f2771fd1139c174c46d09a9ab2da0ea4588b853e2b87e4728322d072542f49">+59/-0</a>&nbsp;
&nbsp; </td>

</tr>
</table></td></tr><tr><td><strong>Tests</strong></td><td><table>
<tr>
  <td>
    <details>

<summary><strong>scheduled-pipeline-query-builder.spec.js</strong><dd><code>Update
scheduled pipeline query builder tests</code>&nbsp; &nbsp; &nbsp; &nbsp;
&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; </dd></summary>
<hr>


tests/ui-testing/playwright-tests/Pipelines/scheduled-pipeline-query-builder.spec.js

<ul><li>Renamed describe to "Scheduled Pipeline Query Builder"<br> <li>
Enabled PromQL tab test, removed skip<br> <li> Added metrics ingestion
step before testing<br> <li> Replaced raw selectors with new POM
methods</ul>


</details>


  </td>
<td><a
href="https://github.com/openobserve/openobserve/pull/10161/files#diff-768a5111c2ae61d07a0be65e6cbdf0ce91040df2fbb0f8a82d257daa49b1b2c0">+12/-14</a>&nbsp;
</td>

</tr>
</table></td></tr><tr><td><strong>Configuration
changes</strong></td><td><table>
<tr>
  <td>
    <details>
<summary><strong>playwright.yml</strong><dd><code>Include new spec in CI
workflow</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></summary>
<hr>

.github/workflows/playwright.yml

- Included `scheduled-pipeline-query-builder.spec.js` in run_files


</details>


  </td>
<td><a
href="https://github.com/openobserve/openobserve/pull/10161/files#diff-7afcd2d8f7b49bda74843f209eefb7b2da45f7e7803bf2e4bd636699b76aa2d3">+1/-0</a>&nbsp;
&nbsp; &nbsp; </td>

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

</details>

___
2026-01-23 14:00:36 +05:30
..