mirror of
https://github.com/openobserve/openobserve.git
synced 2026-11-04 16:09:05 +00:00
### **User description** Add automated test to validate Share button behavior when ZO_WEB_URL is not configured. Uses Playwright route mocking to simulate backend configuration without requiring separate test environment. Changes: - Add Bug #9788 test in shareLink.spec.js with API route mocking - Mock /config endpoint to set web_url="" for testing disabled state - Validate Share button is disabled with informative tooltip - Add ZO_WEB_URL env variable to CI/CD playwright.yml Test validates: - Share button visibility - Disabled state when ZO_WEB_URL not configured - Tooltip: "Share URL is disabled until ZO_WEB_URL is configured" Fixes: https://github.com/openobserve/openobserve/issues/9788 🤖 Generated with [Claude Code](https://claude.com/claude-code) ___ ### **PR Type** Tests ___ ### **Description** - Add test for disabled share button without ZO_WEB_URL - Mock `/config` API endpoint and verify tooltip - Set `ZO_WEB_URL` env variable in CI workflow - Exclude `@bug-9788` tests in rerun commands ___ <details> <summary><h3> File Walkthrough</h3></summary> <table><thead><tr><th></th><th align="left">Relevant files</th></tr></thead><tbody><tr><td><strong>Tests</strong></td><td><table> <tr> <td> <details> <summary><strong>shareLink.spec.js</strong><dd><code>Add test for disabled share button</code> </dd></summary> <hr> tests/ui-testing/playwright-tests/Logs/shareLink.spec.js <ul><li>Added new functional test for Bug #9788 scenario<br> <li> Mocked <code>/config</code> endpoint to simulate missing <code>web_url</code><br> <li> Asserts share button visibility, disabled state, and tooltip</ul> </details> </td> <td><a href="https://github.com/openobserve/openobserve/pull/9858/files#diff-7ee6e1f00c7f0d5464334b39d3eefbe741cd4ee271ba7c5ca4b1e492be53a2d1">+79/-0</a> </td> </tr> </table></td></tr><tr><td><strong>Configuration changes</strong></td><td><table> <tr> <td> <details> <summary><strong>playwright.yml</strong><dd><code>CI workflow: set ZO_WEB_URL and exclude tests</code> </dd></summary> <hr> .github/workflows/playwright.yml <ul><li>Defined <code>ZO_WEB_URL</code> environment variable in CI<br> <li> Updated rerun commands to exclude <code>@bug-9788</code> tests</ul> </details> </td> <td><a href="https://github.com/openobserve/openobserve/pull/9858/files#diff-7afcd2d8f7b49bda74843f209eefb7b2da45f7e7803bf2e4bd636699b76aa2d3">+3/-2</a> </td> </tr> </table></td></tr></tr></tbody></table> </details> ___ --------- Co-authored-by: Claude <noreply@anthropic.com>