Repository navigation
Feature/pickleib improvements - #192
Merged
Merged
Conversation
Documents the plan for RetryPolicy extraction, thread-safe singletons, god class decomposition, unit tests, dependency updates, and cleanup — all while preserving the public API.
12 tasks covering RetryPolicy extraction, thread-safe singletons, helper class decomposition (TDD), dependency updates, and cleanup.
Fixes: StaleElementReferenceException early-exit in elementIs() was silently broken (FQCN vs simple name comparison). Now uses instanceof check.
…mentAcquisition with RetryPolicy Fixes: hoverOver() only retried once due to inverted timeout check
- PickleibWebDriver, PickleibAppiumDriver, ServiceFactory now use ThreadLocal - Remove deprecated BasicAuth initialize method and BouncyCastle import - Fixes stale driver reference after terminate() - Fix AppiumDriverFactory.service.get() call for ThreadLocal usage
Narrows clickButtonIfPresent catch to NoSuchElement/StaleElementRef only. Handles PickleibException wrapping from RetryPolicy for both direct and wrapped exceptions.
Replaces assert with PickleibException for input verification.
…nings, document setter thread-safety
Add implementation plan and design spec for Pickleib improvements (docs/superpowers/plans/2026-03-26-pickleib-improvements.md and docs/superpowers/specs/2026-03-26-pickleib-improvements-design.md). Also update .gitignore to exclude .worktrees and keep existing entries.
Replaces the need for a manual CommonSteps class. Steps are auto-available when 'pickleib.steps' is included in Cucumber's glue path.
- Update page-repository.json for new UI Components Test Suite - Rewrite page object classes to match new app structure - Rewrite AppTest with comprehensive API coverage (45 tests) - Update test URL from 8080 to 7457 - Remove obsolete page objects (ElementsPage, InteractionsPage, AlertAndWindowsPage, DropDownPage) - Add new page objects (AlertsPage, ButtonsPage, DropdownPage)
Platform.MAC was not handled, causing EnumConstantNotPresent on macOS Chrome. Default case now returns text() for all non-Android/iOS platforms.
…ttern - Add static setElementRepository() method - Falls back to PickleibRunner registry if not set - Rename 'Navigate to the test page' to 'Navigate to test url' to avoid collision with environment-specific step patterns
Remove uppercase BACKWARDS/FORWARDS and Mobile/Web from step regex patterns. All enum-based step parameters now use lowercase consistently.
…nd parallel execution
…oll step DriverType params
…ass hierarchy in ContextValueInjector
Umutayb
commented
Apr 2, 2026
…tep, logging improvements - Add Platform enum (web, android, ios, macos, windows) and use in @PageObject/@ScreenObject - Add FormInput record replacing DataTable Map for form fill steps - Add "Select option X from Y on Z" built-in step for dropdown elements - Use contextCheck() in ContextValueInjector for key-value replacement - Use ObjectMapper.convertValue() for generic type conversion - Add warning log in ClasspathScanner for unloadable classes - Suppress Selenium CDP version mismatch warnings - Clean up RetryPolicy logging: first warning + final status only - Update README with @Pickleib, @ScreenObject, Platform enum, PickleibRunner docs
… approaches - Lead with two clear quick-start paths: JSON Repository (low-code) and Page Objects (classic) - Add complete built-in step library reference table - Consolidate configuration docs - Update architecture diagram and step count
…add agent skill - Add pageRepository attribute to @Pickleib annotation for auto-wiring JSON element repos - PickleibRunner loads page-repository.json and sets it on BuiltInSteps automatically - Eliminates need for CommonSteps.java in JSON-based projects - Add Pickleib agent skill with staged workflow for Cucumber test generation - Update README to reflect annotation-driven JSON setup
- Bundle SKILL.md in JAR at META-INF/claude/skills/pickleib/ - Consumers extract it via maven-antrun-plugin during initialize phase - Document plugin config in README - Remove CommonSteps requirement from skill Stage 3
…XT-key docs - Move skill extraction from PickleibRunner to BuiltInSteps static init - Skill auto-extracts to skills/pickleib/SKILL.md when pickleib.steps is in glue path - No consumer POM config needed — just add Pickleib dependency - Add comprehensive CONTEXT-key substitution documentation to skill
…to scan - @Pickleib without params auto-detects: JSON repo at default path, then pages package - Logs warning with setup instructions if neither is found - Rename scanPackages to scan for brevity - Update README and skill docs to reflect zero-config usage
…plicit wiring - Scan 'pages' package for @PageObject/@ScreenObject on first element access - Fall back to page-repository.json if no annotated classes found - Works with JUnit 4 (@RunWith Cucumber) — no @ExtendWith needed - Update skill and README docs for auto-detection order
…stale driver proxies - Add PageObjectRegistry.clearInstances() to flush ThreadLocal cache - Call clearInstances() in BuiltInSteps constructor (runs per scenario) - Fixes NoSuchSessionException when running multiple scenarios sequentially
…ad code Critical: - C1: Use ConcurrentHashMap for PageObjectRegistry metadata (thread-safe parallel execution) - C2: Make elementRepository/autoDetected volatile, synchronize auto-detection in BuiltInSteps High: - H1: Fix resource leak in installSkill() with try-with-resources - H4: Use actual platform from registry instead of hard-coded "web" in ElementBundle - H5: Align auto-detection order (page objects first) in both PickleibRunner and BuiltInSteps Medium: - M4: Catch IllegalArgumentException in ContextValueInjector for type conversion failures Low: - L4: Update Guava from 31.0.1 to 33.2.1 (compatible with Selenium 4.19) - L5: Make junit-jupiter optional to avoid version conflicts in consumers - L6: Fix copy-paste comment on org.json dependency Cleanup: - Remove unused support package (ChatSupport, SupportGUI) - Add JaCoCo for code coverage reporting
…n, ContextValueInjector PageObjectRegistry (13 new): - clearInstances() safety and registry preservation - getPlatform() for all platform types + unknown pages - Concurrent register/lookup thread safety - Case-insensitive registration and lookup BuiltInSteps (15 new): - setElementRepository() priority over auto-detection - volatile/synchronized fields verified via reflection - Cross-thread visibility of static fields - DEFAULT constants match PickleibRunner - clearInstances() thread-local behavior ContextValueInjector (7 new): - Unsupported types handled without crash (IllegalArgumentException caught) - Private superclass fields injected across class hierarchy - Non-annotated fields left untouched - Null/empty context values handled gracefully - CONTEXT- prefix resolution in values and defaults Total: 135 tests (was 100), all passing.
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.
No description provided.