Skip to content

Conversation

@tonyghiani
Copy link
Contributor

@tonyghiani tonyghiani commented Jul 29, 2025

📓 Summary

Part of #245

This PR introduces a comprehensive Scout test suite for the Stream Routing UI.
The tests cover key workflow areas, including creating, editing, reordering routing rules, error handling and recovery scenarios, and preview panel behavior with generated synthetic data.

🧪 Test Suite

Stream data routing
├─ Creating New routing rules
│  ├─ should create a new routing rule successfully
│  ├─ should cancel creating new routing rule
│  ├─ should not let creating new routing rule while one is in progress
│  ├─ should show validation errors for invalid stream names
│  └─ should handle insufficient privileges gracefully
│
├─ Editing existing routing rules
│  ├─ should edit an existing routing rule
│  ├─ should cancel editing routing rule
│  ├─ should switch between editing different rules
│  ├─ should remove routing rule with confirmation
│  └─ should cancel rule removal
│
├─ Reordering routing rules
│  ├─ should reorder routing rules via drag and drop
│  ├─ should cancel reordering
│  └─ should handle multiple reorder operations
│
├─ Error handling and recovery
│  ├─ should handle network failures during rule creation
│  └─ should recover from API errors during rule updates
│
└─ Preview panel
   ├─ should show the preview data during rule creation
   ├─ should update the preview data when the condition changes
   └─ should show no matches when the condition matches nothing

Stream data retention
└─ Updating data retention
   ├─ should update a stream data retention policy successfully
   └─ should reset a stream data retention policy successfully

@tonyghiani tonyghiani changed the title 282 improve routing testing [Streams] Implement Routing UI e2e tests Jul 29, 2025
@tonyghiani tonyghiani changed the title [Streams] Implement Routing UI e2e tests [Streams] Implement Routing UI + Data retention e2e tests Jul 29, 2025
@tonyghiani
Copy link
Contributor Author

/ci

@tonyghiani tonyghiani marked this pull request as ready for review July 30, 2025 08:21
@tonyghiani tonyghiani requested review from a team as code owners July 30, 2025 08:21
@dmlemeshko dmlemeshko self-requested a review July 30, 2025 08:22
@tonyghiani tonyghiani added release_note:skip Skip the PR/issue when compiling release notes backport:skip This PR does not require backporting Team:obs-onboarding Observability Onboarding Team Feature:Streams This is the label for the Streams Project labels Jul 30, 2025
@elasticmachine
Copy link
Contributor

Pinging @elastic/obs-ux-logs-team (Team:obs-ux-logs)

@tonyghiani tonyghiani requested a review from a team as a code owner July 30, 2025 09:50
@tonyghiani tonyghiani removed the request for review from a team July 30, 2025 11:09
Copy link
Contributor

@dmlemeshko dmlemeshko left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM, thanks a lot for update 🚀

@flash1293
Copy link
Contributor

Pretty neat, however I think it would be great to add a test for the syntax-based condition editor.

@tonyghiani
Copy link
Contributor Author

@flash1293 Added a test for the syntax editor to verify changes are reflected on the preview outcome, this should be ready for another look.

Copy link
Contributor

@flash1293 flash1293 left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM, thanks for adding that. Just one last request :)

@tonyghiani tonyghiani enabled auto-merge (squash) August 4, 2025 09:37
@tonyghiani tonyghiani merged commit b0b021c into elastic:main Aug 4, 2025
12 checks passed
@elasticmachine
Copy link
Contributor

💛 Build succeeded, but was flaky

Failed CI Steps

Test Failures

  • [job] [logs] FTR Configs #125 / Fleet Endpoints fleet policy secrets fleet server version requirements "after each" hook for "should convert plain text values to secrets once fleet server requirements are met"

Metrics [docs]

Async chunks

Total size of all lazy-loaded chunks that will be downloaded as the user navigates the app

id before after diff
streamsApp 615.9KB 616.3KB +321.0B
Unknown metric groups

ESLint disabled in files

id before after diff
streamsApp 4 7 +3

Total ESLint disabled count

id before after diff
streamsApp 12 15 +3

History

szaffarano pushed a commit to szaffarano/kibana that referenced this pull request Aug 5, 2025
…9791)

## 📓 Summary

Part of [elastic#245](elastic/logs-dev#245)

This PR introduces a comprehensive Scout test suite for the **Stream
Routing UI**.
The tests cover key workflow areas, including creating, editing,
reordering routing rules, error handling and recovery scenarios, and
preview panel behavior with generated synthetic data.

## 🧪 Test Suite

```
Stream data routing
├─ Creating New routing rules
│  ├─ should create a new routing rule successfully
│  ├─ should cancel creating new routing rule
│  ├─ should not let creating new routing rule while one is in progress
│  ├─ should show validation errors for invalid stream names
│  └─ should handle insufficient privileges gracefully
│
├─ Editing existing routing rules
│  ├─ should edit an existing routing rule
│  ├─ should cancel editing routing rule
│  ├─ should switch between editing different rules
│  ├─ should remove routing rule with confirmation
│  └─ should cancel rule removal
│
├─ Reordering routing rules
│  ├─ should reorder routing rules via drag and drop
│  ├─ should cancel reordering
│  └─ should handle multiple reorder operations
│
├─ Error handling and recovery
│  ├─ should handle network failures during rule creation
│  └─ should recover from API errors during rule updates
│
└─ Preview panel
   ├─ should show the preview data during rule creation
   ├─ should update the preview data when the condition changes
   └─ should show no matches when the condition matches nothing

Stream data retention
└─ Updating data retention
   ├─ should update a stream data retention policy successfully
   └─ should reset a stream data retention policy successfully
```

---------

Co-authored-by: kibanamachine <42973632+kibanamachine@users.noreply.github.com>
delanni pushed a commit to delanni/kibana that referenced this pull request Aug 5, 2025
…9791)

## 📓 Summary

Part of [elastic#245](elastic/logs-dev#245)

This PR introduces a comprehensive Scout test suite for the **Stream
Routing UI**.
The tests cover key workflow areas, including creating, editing,
reordering routing rules, error handling and recovery scenarios, and
preview panel behavior with generated synthetic data.

## 🧪 Test Suite

```
Stream data routing
├─ Creating New routing rules
│  ├─ should create a new routing rule successfully
│  ├─ should cancel creating new routing rule
│  ├─ should not let creating new routing rule while one is in progress
│  ├─ should show validation errors for invalid stream names
│  └─ should handle insufficient privileges gracefully
│
├─ Editing existing routing rules
│  ├─ should edit an existing routing rule
│  ├─ should cancel editing routing rule
│  ├─ should switch between editing different rules
│  ├─ should remove routing rule with confirmation
│  └─ should cancel rule removal
│
├─ Reordering routing rules
│  ├─ should reorder routing rules via drag and drop
│  ├─ should cancel reordering
│  └─ should handle multiple reorder operations
│
├─ Error handling and recovery
│  ├─ should handle network failures during rule creation
│  └─ should recover from API errors during rule updates
│
└─ Preview panel
   ├─ should show the preview data during rule creation
   ├─ should update the preview data when the condition changes
   └─ should show no matches when the condition matches nothing

Stream data retention
└─ Updating data retention
   ├─ should update a stream data retention policy successfully
   └─ should reset a stream data retention policy successfully
```

---------

Co-authored-by: kibanamachine <42973632+kibanamachine@users.noreply.github.com>
@tonyghiani tonyghiani deleted the 282-improve-routing-testing branch August 7, 2025 06:55
@wildemat wildemat mentioned this pull request Aug 7, 2025
10 tasks
NicholasPeretti pushed a commit to NicholasPeretti/kibana that referenced this pull request Aug 18, 2025
…9791)

## 📓 Summary

Part of [elastic#245](elastic/logs-dev#245)

This PR introduces a comprehensive Scout test suite for the **Stream
Routing UI**.
The tests cover key workflow areas, including creating, editing,
reordering routing rules, error handling and recovery scenarios, and
preview panel behavior with generated synthetic data.

## 🧪 Test Suite

```
Stream data routing
├─ Creating New routing rules
│  ├─ should create a new routing rule successfully
│  ├─ should cancel creating new routing rule
│  ├─ should not let creating new routing rule while one is in progress
│  ├─ should show validation errors for invalid stream names
│  └─ should handle insufficient privileges gracefully
│
├─ Editing existing routing rules
│  ├─ should edit an existing routing rule
│  ├─ should cancel editing routing rule
│  ├─ should switch between editing different rules
│  ├─ should remove routing rule with confirmation
│  └─ should cancel rule removal
│
├─ Reordering routing rules
│  ├─ should reorder routing rules via drag and drop
│  ├─ should cancel reordering
│  └─ should handle multiple reorder operations
│
├─ Error handling and recovery
│  ├─ should handle network failures during rule creation
│  └─ should recover from API errors during rule updates
│
└─ Preview panel
   ├─ should show the preview data during rule creation
   ├─ should update the preview data when the condition changes
   └─ should show no matches when the condition matches nothing

Stream data retention
└─ Updating data retention
   ├─ should update a stream data retention policy successfully
   └─ should reset a stream data retention policy successfully
```

---------

Co-authored-by: kibanamachine <42973632+kibanamachine@users.noreply.github.com>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

backport:skip This PR does not require backporting Feature:Streams This is the label for the Streams Project release_note:skip Skip the PR/issue when compiling release notes Team:obs-onboarding Observability Onboarding Team v9.2.0

Projects

None yet

Development

Successfully merging this pull request may close these issues.

5 participants