Page slugs become WooCommerceWebDriver module config - #54
Merged
edpittol merged 7 commits intoJun 19, 2026
Conversation
Move cart, checkout, and my-account page-slug resolution out of the database and into module config. WooCommerceWebDriver now declares cartPageSlug (/cart), checkoutPageSlug (/checkout), and myAccountPageSlug (/my-account) with WooCommerce-convention defaults, each independently overridable in suite.yml. WooCommerceConfig holds the declared slugs instead of querying WPDb, so browser navigation to these pages never touches the system under test. Implements the page-slug half of the WebDriver store-shape-via-config decision (docs/adr/0008). Closes #48
edpittol
commented
Jun 19, 2026
- Drop overrideWooCommerceWebDriverConfig() and resetWooCommerceWebDriverConfig() from the Acceptance helper — the Codeception _reconfigure/_resetConfig API is not part of the public test interface we want to expose. - Remove testNavigatesToOverriddenCartSlug and the _after hook that depended on those helpers; the remaining default-slug tests need no teardown. - Delete the WooCommerceConfig class docblock — the class name and constructor signature are self-documenting.
…uantity The WooCommerce Cart Block renders quantity inputs via React hydration, which completes after DOM-ready. grabAttributeFrom does not wait, so the XPath lookup races the hydration step and fails intermittently. waitForElement makes the assertion block until the input is present, eliminating the flake.
…ceptance test - pageSlugConfig() now throws ModuleException when the configured value is not a string, instead of silently returning an empty slug - PageSlugCest covers all three default slugs (cart, checkout, my-account)
edpittol
deleted the
48-page-slugs-become-woocommercewebdriver-module-config
branch
June 19, 2026 02:28
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Summary
Moves cart, checkout, and my-account page-slug resolution out of the database and into `WooCommerceWebDriver` module config, so browser navigation to these pages never queries the system under test. Implements the page-slug half of ADR-0008.
Implementation
Fixes
Tests
Acceptance criteria
Closes #48