Skip to content

test: make class-scoped fixtures classmethods - #1580

Open
ChenfromChina123 wants to merge 1 commit into
python-openxml:masterfrom
ChenfromChina123:fix/class-scoped-fixtures
Open

test: make class-scoped fixtures classmethods#1580
ChenfromChina123 wants to merge 1 commit into
python-openxml:masterfrom
ChenfromChina123:fix/class-scoped-fixtures

Conversation

@ChenfromChina123

Copy link
Copy Markdown

What does this PR do?

Fixes pytest 9.1 deprecation of class-scoped fixtures defined as instance methods (taking self); they must now be classmethods taking cls.

Closes #1564 (see #1563)

Changes

  • tests/opc/test_phys_pkg.py: convert dir_reader and phys_reader class-scoped fixtures to classmethods.

Verification

  • python -m py_compile tests/opc/test_phys_pkg.py passes.

@ChenfromChina123
ChenfromChina123 force-pushed the fix/class-scoped-fixtures branch from db98cdb to 5af41d4 Compare August 11, 2026 13:38
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.

Don't define class-scoped fixtures as instance methods

1 participant