Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Add support for Python 3.12 #46

Merged
merged 3 commits into from
May 8, 2024
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 2 additions & 0 deletions CHANGES.rst
Original file line number Diff line number Diff line change
Expand Up @@ -10,6 +10,8 @@ Change log for zope.pytestlayer

- Add support for Python 3.11.

- Add support for Python 3.12.

- Rename from ``gocept.pytestlayer`` to ``zope.pytestlayer``.


Expand Down
4 changes: 2 additions & 2 deletions src/zope/pytestlayer/fixture.py
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
import contextlib
import imp
import re
import time
import types

import pytest
import zope.dottedname.resolve
Expand Down Expand Up @@ -205,7 +205,7 @@ def parsefactories(collector, layer):
ns = create(layer)
if ns:
name = get_fixture_name(layer, scope='function')
module = imp.new_module(name)
module = types.ModuleType(name)
module.__dict__.update(ns)
collector.session._fixturemanager.parsefactories(module, '')

Expand Down