filesystems/py-pyfakefs 5.7.1_1 MidnightBSD
Implement a fake file system that mocks the Python file system modules
- System
- MidnightBSD
- Repository
- mports
- Maintainer
- [email protected]
- License
- Apache-2.0
- Categories
- filesystems, devel, python
Description
pyfakefs implements a fake file 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 creates a new empty in-memory file system at each test start, which replaces the real filesystem during the test. Think of pyfakefs as making a per-test temporary directory, except for an entire file system.
There are several means to achieve this: by using the fs fixture if running pytest, by using fake_filesystem_unittest.TestCase as a base class if using unittest, by using a fake_filesystem_unittest.Patcher instance as a context manager, or by using the patchfs decorator.
In the other systems
The newest version among them is 6.2.0, as upstream numbers it.
| System | Port | Version | Vulnerabilities | Status | Maintainer | Last update |
|---|---|---|---|---|---|---|
| MidnightBSD | filesystems/py-pyfakefs | 5.7.1_1 behind since 2026-09-30 | no data | - | [email protected] | - |
| FreeBSD | filesystems/py-pyfakefs | 6.2.0 newest | none known | - | [email protected] | 2026-09-30 |
| DragonFly | filesystems/py-pyfakefs | 5.8.0 behind since 2026-09-30 | none known | - | [email protected] | - |
| HardenedBSD | filesystems/py-pyfakefs | 6.2.0 newest | no data | - | [email protected] | - |
| GhostBSD | filesystems/py-pyfakefs | 5.10.2 behind since 2026-09-30 | no data | - | [email protected] | - |
Install
Binary package:
mport install ${PYTHON_PKGNAMEPREFIX}pyfakefs
From mports:
cd /usr/mports/filesystems/py-pyfakefs && make install clean
To depend on this port in another port's Makefile:
RUN_DEPENDS= ${PYTHON_PKGNAMEPREFIX}pyfakefs>0:filesystems/py-pyfakefs
Dependency graph
Ports that need it on the left, what it needs to run on the right (to build, as it needs nothing to run); at most 8 of each. "Dependencies" below lists them all.
Dependencies
As this port's Makefile names them.
Build 2
${PYTHON_PKGNAMEPREFIX}setuptools>=0: devel/py-setuptools${PYTHON_PKGNAMEPREFIX}wheel>=0: devel/py-wheel
Test 1
${PYTHON_PKGNAMEPREFIX}undefined>=0: devel/py-undefined
Build dependencies 2
No port depends on this one.
Configuration
No options to configure.
- USES
- python
- Service scripts
- none
Files
distinfo 1
| File | Size | SHA256 |
|---|---|---|
| pyfakefs-5.7.1.tar.gz | 211163 | 24774c632f3b67ea26fd56b08115ba7c339d5cd65655410bca8572d73a1ae9a4 |
Master sites 1
- PYPI