[web-app] Unify steps for cookie management#5637
Conversation
17019ba to
dacd0c2
Compare
Qodana for JVM5 new problems were found
💡 Qodana analysis was run in the pull request mode: only the changed files were checked Contact Qodana teamContact us at qodana-support@jetbrains.com
|
| <property name="uriToIgnoreRegex" value="${resource-checker.uri-to-ignore-regex}" /> | ||
| </bean> | ||
|
|
||
| <bean id="browserAndHttpContextIntegrationSteps" class="org.vividus.integration.steps.BrowserAndHttpContextIntegrationSteps" /> |
Check failure
Code scanning / QDJVM
Incorrect constructor injection in XML Spring bean Error
| </bean> | ||
| <bean id="mouseActions" class="org.vividus.ui.web.action.MouseActions" /> | ||
| <bean id="navigateActions" class="org.vividus.ui.web.action.NavigateActions" /> | ||
| <bean id="navigateActions" class="org.vividus.ui.web.action.SeleniumNavigateActions" /> |
Check failure
Code scanning / QDJVM
Incorrect constructor injection in XML Spring bean Error
|
Codecov Report✅ All modified and coverable lines are covered by tests. Additional details and impacted files@@ Coverage Diff @@
## master #5637 +/- ##
=========================================
Coverage 97.77% 97.77%
+ Complexity 7400 7399 -1
=========================================
Files 1014 1013 -1
Lines 21420 21421 +1
Branches 1405 1406 +1
=========================================
+ Hits 20943 20944 +1
Misses 361 361
Partials 116 116 ☔ View full report in Codecov by Sentry. 🚀 New features to boost your workflow:
|
dacd0c2 to
fa11433
Compare
|
Important Review skippedDraft detected. Please check the settings in the CodeRabbit UI or the ⚙️ Run configurationConfiguration used: Organization UI Review profile: ASSERTIVE Plan: Pro Run ID: You can disable this status message by setting the Use the checkbox below for a quick retry:
✨ Finishing Touches🧪 Generate unit tests (beta)
📝 Coding Plan
Thanks for using CodeRabbit! It's free for OSS, and your support helps us grow. If you like it, consider giving us a shout-out. Comment Tip You can disable sequence diagrams in the walkthrough.Disable the |
There was a problem hiding this comment.
Pull request overview
This PR unifies cookie-management steps across Selenium and Playwright by introducing a shared navigation abstraction and moving cookie operations into the common CookieSteps implementation.
Changes:
- Introduced
NavigateActionsabstraction (getCurrentUrl,refresh) and added Selenium/Playwright implementations. - Migrated “set/remove cookies (with/without applying changes)” steps into
vividus-extension-web-appsharedCookieSteps. - Simplified/centralized browser↔HTTP cookie integration steps and updated docs + integration stories accordingly.
Reviewed changes
Copilot reviewed 26 out of 26 changed files in this pull request and generated 5 comments.
Show a summary per file
| File | Description |
|---|---|
| vividus-tests/src/main/resources/story/integration/WebCookieSteps.story | Updates integration story to validate new unified cookie steps behavior (apply vs no-apply). |
| vividus-plugin-web-app/src/test/java/org/vividus/ui/web/action/NavigateActionsTests.java | Updates Selenium navigation tests for renamed implementation and adds getCurrentUrl coverage. |
| vividus-plugin-web-app/src/test/java/org/vividus/steps/ui/web/SeleniumCookieStepsTests.java | Removes cookie-step tests now covered by shared CookieStepsTests. |
| vividus-plugin-web-app/src/main/resources/vividus-plugin/spring.xml | Switches navigateActions bean to Selenium-specific implementation. |
| vividus-plugin-web-app/src/main/java/org/vividus/ui/web/action/NavigateActions.java | Renames/refactors Selenium navigate actions and adds getCurrentUrl. |
| vividus-plugin-web-app/src/main/java/org/vividus/ui/web/action/INavigateActions.java | Makes Selenium-specific navigation extend shared NavigateActions. |
| vividus-plugin-web-app/src/main/java/org/vividus/steps/ui/web/SeleniumCookieSteps.java | Delegates cookie operations to shared CookieSteps via NavigateActions. |
| vividus-plugin-web-app-to-rest-api/src/test/java/org/vividus/integration/steps/SeleniumBrowserAndHttpContextIntegrationStepsTests.java | Removes Selenium-specific tests in favor of unified base steps tests. |
| vividus-plugin-web-app-to-rest-api/src/test/java/org/vividus/integration/steps/PlaywrightBrowserAndHttpContextIntegrationStepsTests.java | Removes Playwright-specific tests in favor of unified base steps tests. |
| vividus-plugin-web-app-to-rest-api/src/test/java/org/vividus/integration/steps/BrowserAndHttpContextIntegrationStepsTests.java | Adds unified tests using NavigateActions.refresh() contract. |
| vividus-plugin-web-app-to-rest-api/src/main/resources/vividus-plugin/spring.xml | Registers unified steps bean and removes engine-specific профiled beans. |
| vividus-plugin-web-app-to-rest-api/src/main/java/org/vividus/integration/steps/SeleniumBrowserAndHttpContextIntegrationSteps.java | Removes Selenium-specific subclass in favor of unified steps. |
| vividus-plugin-web-app-to-rest-api/src/main/java/org/vividus/integration/steps/PlaywrightBrowserAndHttpContextIntegrationSteps.java | Removes Playwright-specific subclass in favor of unified steps. |
| vividus-plugin-web-app-to-rest-api/src/main/java/org/vividus/integration/steps/BrowserAndHttpContextIntegrationSteps.java | Uses NavigateActions directly instead of passing a refresh runnable. |
| vividus-plugin-web-app-playwright/src/test/java/org/vividus/ui/web/playwright/steps/PlaywrightCookieStepsTests.java | Removes tests for cookie operations now covered by shared CookieStepsTests. |
| vividus-plugin-web-app-playwright/src/test/java/org/vividus/ui/web/playwright/steps/PageStepsTests.java | Updates refresh-page test to rely on NavigateActions.refresh(). |
| vividus-plugin-web-app-playwright/src/test/java/org/vividus/ui/web/playwright/action/PlaywrightNavigateActionsTests.java | Adds unit tests for Playwright navigation abstraction. |
| vividus-plugin-web-app-playwright/src/main/resources/vividus-plugin/spring.xml | Registers Playwright NavigateActions implementation bean. |
| vividus-plugin-web-app-playwright/src/main/java/org/vividus/ui/web/playwright/steps/PlaywrightCookieSteps.java | Delegates cookie ops to shared CookieSteps using NavigateActions. |
| vividus-plugin-web-app-playwright/src/main/java/org/vividus/ui/web/playwright/steps/PageSteps.java | Uses NavigateActions.refresh() instead of Page.reload(). |
| vividus-plugin-web-app-playwright/src/main/java/org/vividus/ui/web/playwright/action/PlaywrightNavigateActions.java | Introduces Playwright implementation of shared NavigateActions. |
| vividus-extension-web-app/src/test/java/org/vividus/ui/web/CookieStepsTests.java | Adds/updates tests to cover unified cookie operations via NavigateActions. |
| vividus-extension-web-app/src/main/java/org/vividus/ui/web/action/NavigateActions.java | Introduces shared navigation contract used by cookie steps and integrations. |
| vividus-extension-web-app/src/main/java/org/vividus/ui/web/CookieSteps.java | Moves cookie set/remove (+ no-apply variants) into shared implementation. |
| docs/modules/plugins/partials/web-cookie-steps.adoc | Documents new “without applying changes” steps and refresh semantics. |
| docs/modules/plugins/pages/plugin-web-app.adoc | Replaces inlined cookie steps docs with shared partial include. |
💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.
| <property name="uriToIgnoreRegex" value="${resource-checker.uri-to-ignore-regex}" /> | ||
| </bean> | ||
|
|
||
| <bean id="browserAndHttpContextIntegrationSteps" class="org.vividus.integration.steps.BrowserAndHttpContextIntegrationSteps" /> |
| @Test | ||
| void shoutSetAllCookiesWithoutApplyingChanges() | ||
| { | ||
| testSetAllCookies(cookieSteps::setAllCookiesWithoutApply); |
| } | ||
|
|
||
| @Test | ||
| void shoutSetAllCookiesWithoutApplyingChanges() |
| * Adds the cookies provided in the input ExamplesTable with domain of the opened currently page. After adding | ||
| * the cookies the opened page is refreshed (this is required to apply the new cookies). |
| Removes the certain cookie from the current domain. | ||
| Removes the certain cookie from the current domain. The actions performed by the step: | ||
|
|
||
| * remove the certain cookie the from current domain; |
Qodana for JVM5 new problems were found
💡 Qodana analysis was run in the pull request mode: only the changed files were checked Contact Qodana teamContact us at qodana-support@jetbrains.com
|
|



No description provided.