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 back support for Python 3.7 #882

Merged
merged 1 commit into from
Sep 7, 2023
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: 1 addition & 1 deletion .github/workflows/testsuite.yml
Original file line number Diff line number Diff line change
Expand Up @@ -25,7 +25,7 @@ jobs:
fail-fast: false
matrix:
os: [ubuntu-latest, macOS-latest, windows-latest]
python-version: ["3.8", "3.9", "3.10", "3.11", "3.12-dev"]
python-version: [3.7, 3.8, 3.9, "3.10", "3.11", "3.12-dev"]
include:
- python-version: "pypy-3.7"
os: ubuntu-latest
Expand Down
3 changes: 0 additions & 3 deletions CHANGES.md
Original file line number Diff line number Diff line change
Expand Up @@ -3,9 +3,6 @@ The released versions correspond to PyPI releases.

## Unreleased

### Changes
* removed support for Python 3.7 (end of life)

### Fixes
* removed a leftover debug print statement (see [#869](../../issues/869))
* make sure tests work without HOME environment set (see [#870](../../issues/870))
Expand Down
4 changes: 2 additions & 2 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -55,7 +55,7 @@ provides some additional features:
under root

## Compatibility
pyfakefs works with CPython 3.8 and above, on Linux, Windows and macOS, and
pyfakefs works with CPython 3.7 and above, on Linux, Windows and macOS, and
with PyPy3.

pyfakefs works with [pytest](http://doc.pytest.org) version 3.0.0 or above,
Expand All @@ -73,7 +73,7 @@ for more information about the limitations of pyfakefs.
### Continuous integration

pyfakefs is currently automatically tested on Linux, macOS and Windows, with
Python 3.8 to 3.12, and with PyPy3 on Linux, using
Python 3.7 to 3.11, and with PyPy3 on Linux, using
[GitHub Actions](https://github.com/pytest-dev/pyfakefs/actions).

### Running pyfakefs unit tests
Expand Down
2 changes: 1 addition & 1 deletion docs/intro.rst
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,7 @@ system that mocks the Python file system modules.
Using pyfakefs, your tests operate on a fake file system in memory without touching the real disk.
The software under test requires no modification to work with pyfakefs.

pyfakefs works with CPython 3.8 and above, on Linux, Windows and macOS,
pyfakefs works with CPython 3.7 and above, on Linux, Windows and macOS,
and with PyPy3.

pyfakefs works with `pytest <doc.pytest.org>`__ version 3.0.0 or above by
Expand Down
4 changes: 3 additions & 1 deletion pyfakefs/tests/fake_filesystem_test.py
Original file line number Diff line number Diff line change
Expand Up @@ -1062,7 +1062,9 @@ def test_join_bytes(self):
components = [b"foo", b"bar", b"baz"]
self.assertEqual(b"foo!bar!baz", self.path.join(*components))

@unittest.skipIf(sys.platform != "win32", "Windows specific test")
@unittest.skipIf(
sys.platform != "win32" or sys.version_info < (3, 8), "Windows specific test"
)
@patch.dict(os.environ, {"USERPROFILE": r"C:\Users\John"})
def test_expand_user_windows(self):
self.assertEqual(self.path.expanduser("~"), "C:!Users!John")
Expand Down
8 changes: 6 additions & 2 deletions pyfakefs/tests/fake_pathlib_test.py
Original file line number Diff line number Diff line change
Expand Up @@ -462,7 +462,9 @@ def test_cwd(self):
self.path.cwd(), self.path(self.os.path.realpath(dir_path))
)

@unittest.skipIf(sys.platform != "win32", "Windows specific test")
@unittest.skipIf(
sys.platform != "win32" or sys.version_info < (3, 8), "Windows specific test"
)
@patch.dict(os.environ, {"USERPROFILE": r"C:\Users\John"})
def test_expanduser_windows(self):
self.assertEqual(
Expand All @@ -475,7 +477,9 @@ def test_expanduser_windows(self):
def test_expanduser_posix(self):
self.assertEqual(self.path("~").expanduser(), self.path("/home/john"))

@unittest.skipIf(sys.platform != "win32", "Windows specific test")
@unittest.skipIf(
sys.platform != "win32" or sys.version_info < (3, 8), "Windows specific test"
)
@patch.dict(os.environ, {"USERPROFILE": r"C:\Users\John"})
def test_home_windows(self):
self.assertEqual(
Expand Down
3 changes: 2 additions & 1 deletion setup.cfg
Original file line number Diff line number Diff line change
Expand Up @@ -28,6 +28,7 @@ classifiers =
Intended Audience :: Developers
License :: OSI Approved :: Apache Software License
Programming Language :: Python :: 3
Programming Language :: Python :: 3.7
Programming Language :: Python :: 3.8
Programming Language :: Python :: 3.9
Programming Language :: Python :: 3.10
Expand All @@ -49,7 +50,7 @@ universal = 0
[options]
packages = find:
install_requires =
python_requires = >=3.8
python_requires = >=3.7
test_suite = pyfakefs.tests
include_package_data = True

Expand Down
Loading