Skip to content

Define the base_url fallback fixture as a class method - #342

Closed
Aditya Nikam (adityaanikam) wants to merge 1 commit into
microsoft:mainfrom
adityaanikam:fix-341-base-url-fallback
Closed

Aditya Nikam (adityaanikam) wants to merge 1 commit into
microsoft:mainfrom
adityaanikam:fix-341-base-url-fallback

Conversation

@adityaanikam

Copy link
Copy Markdown

Fixes #341

With pytest 9.2 and no pytest-base-url, the base_url fallback fixture raised PytestRemovedIn10Warning, because it was a session-scoped fixture defined as an instance method. It is now a class method, as the warning recommends, in both pytest-playwright and pytest-playwright-asyncio.

Added a test for each package that runs with -W error::pytest.PytestDeprecationWarning and fails without the change. I checked the fix on pytest 7.0.0, 7.4.4, 8.4.2, 9.1.1 and 9.2.0.

Copilot AI balanced review requested due to automatic review settings October 31, 2026 18:59

Copilot AI left a comment

Copy link
Copy Markdown

Choose a reason for hiding this comment

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

Copilot was unable to review this pull request because the user who requested the review has insufficient remaining quota. Try requesting a review at a lower effort level.

@pavelfeldman

Copy link
Copy Markdown
Member

Oh, i did not the the bots - looks flawed

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

PytestRemovedIn10Warning for base_url with pytest 9.2.0 and pytest-playwright 0.10.0 without pytest-base-url

3 participants