nti.testing 4.5.0__tar.gz → 4.5.1__tar.gz
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- {nti_testing-4.5.0 → nti_testing-4.5.1}/CHANGES.rst +7 -1
- {nti_testing-4.5.0/src/nti.testing.egg-info → nti_testing-4.5.1}/PKG-INFO +8 -2
- {nti_testing-4.5.0 → nti_testing-4.5.1}/setup.py +1 -1
- {nti_testing-4.5.0 → nti_testing-4.5.1}/src/nti/testing/base.py +4 -2
- {nti_testing-4.5.0 → nti_testing-4.5.1}/src/nti/testing/tests/test_base.py +2 -1
- {nti_testing-4.5.0 → nti_testing-4.5.1/src/nti.testing.egg-info}/PKG-INFO +8 -2
- {nti_testing-4.5.0 → nti_testing-4.5.1}/src/nti.testing.egg-info/SOURCES.txt +0 -9
- nti_testing-4.5.0/.github/workflows/tests.yml +0 -68
- nti_testing-4.5.0/.gitignore +0 -8
- nti_testing-4.5.0/docs/_build/html/_static/basic.css +0 -906
- nti_testing-4.5.0/docs/_build/html/_static/debug.css +0 -69
- nti_testing-4.5.0/docs/_build/html/_static/pygments.css +0 -249
- nti_testing-4.5.0/docs/_build/html/_static/skeleton.css +0 -296
- nti_testing-4.5.0/docs/_build/html/_static/styles/furo-extensions.css +0 -2
- nti_testing-4.5.0/docs/_build/html/_static/styles/furo.css +0 -2
- nti_testing-4.5.0/docs/_static/custom.css +0 -95
- {nti_testing-4.5.0 → nti_testing-4.5.1}/.coveragerc +0 -0
- {nti_testing-4.5.0 → nti_testing-4.5.1}/.isort.cfg +0 -0
- {nti_testing-4.5.0 → nti_testing-4.5.1}/.nti_cover_package +0 -0
- {nti_testing-4.5.0 → nti_testing-4.5.1}/.pylintrc +0 -0
- {nti_testing-4.5.0 → nti_testing-4.5.1}/.readthedocs.yml +0 -0
- {nti_testing-4.5.0 → nti_testing-4.5.1}/.travis.yml +0 -0
- {nti_testing-4.5.0 → nti_testing-4.5.1}/COPYRIGHT.txt +0 -0
- {nti_testing-4.5.0 → nti_testing-4.5.1}/INSTALL +0 -0
- {nti_testing-4.5.0 → nti_testing-4.5.1}/LICENSE +0 -0
- {nti_testing-4.5.0 → nti_testing-4.5.1}/MANIFEST.in +0 -0
- {nti_testing-4.5.0 → nti_testing-4.5.1}/README.rst +0 -0
- {nti_testing-4.5.0 → nti_testing-4.5.1}/TODO +0 -0
- {nti_testing-4.5.0 → nti_testing-4.5.1}/doc-requirements.txt +0 -0
- {nti_testing-4.5.0/docs/_build/html → nti_testing-4.5.1/docs}/_static/custom.css +0 -0
- {nti_testing-4.5.0 → nti_testing-4.5.1}/docs/api.rst +0 -0
- {nti_testing-4.5.0 → nti_testing-4.5.1}/docs/base.rst +0 -0
- {nti_testing-4.5.0 → nti_testing-4.5.1}/docs/changelog.rst +0 -0
- {nti_testing-4.5.0 → nti_testing-4.5.1}/docs/conf.py +0 -0
- {nti_testing-4.5.0 → nti_testing-4.5.1}/docs/index.rst +0 -0
- {nti_testing-4.5.0 → nti_testing-4.5.1}/docs/layers.rst +0 -0
- {nti_testing-4.5.0 → nti_testing-4.5.1}/docs/matchers.rst +0 -0
- {nti_testing-4.5.0 → nti_testing-4.5.1}/docs/time.rst +0 -0
- {nti_testing-4.5.0 → nti_testing-4.5.1}/docs/zodb.rst +0 -0
- {nti_testing-4.5.0 → nti_testing-4.5.1}/pyproject.toml +0 -0
- {nti_testing-4.5.0 → nti_testing-4.5.1}/setup.cfg +0 -0
- {nti_testing-4.5.0 → nti_testing-4.5.1}/src/nti/__init__.py +0 -0
- {nti_testing-4.5.0 → nti_testing-4.5.1}/src/nti/testing/__init__.py +0 -0
- {nti_testing-4.5.0 → nti_testing-4.5.1}/src/nti/testing/layers/__init__.py +0 -0
- {nti_testing-4.5.0 → nti_testing-4.5.1}/src/nti/testing/layers/cleanup.py +0 -0
- {nti_testing-4.5.0 → nti_testing-4.5.1}/src/nti/testing/layers/postgres.py +0 -0
- {nti_testing-4.5.0 → nti_testing-4.5.1}/src/nti/testing/layers/tests/__init__.py +0 -0
- {nti_testing-4.5.0 → nti_testing-4.5.1}/src/nti/testing/layers/tests/test_postgres.py +0 -0
- {nti_testing-4.5.0 → nti_testing-4.5.1}/src/nti/testing/layers/zope.py +0 -0
- {nti_testing-4.5.0 → nti_testing-4.5.1}/src/nti/testing/matchers.py +0 -0
- {nti_testing-4.5.0 → nti_testing-4.5.1}/src/nti/testing/mock.py +0 -0
- {nti_testing-4.5.0 → nti_testing-4.5.1}/src/nti/testing/tests/__init__.py +0 -0
- {nti_testing-4.5.0 → nti_testing-4.5.1}/src/nti/testing/tests/test_component_cleanup_broken.txt +0 -0
- {nti_testing-4.5.0 → nti_testing-4.5.1}/src/nti/testing/tests/test_layers.py +0 -0
- {nti_testing-4.5.0 → nti_testing-4.5.1}/src/nti/testing/tests/test_main.py +0 -0
- {nti_testing-4.5.0 → nti_testing-4.5.1}/src/nti/testing/tests/test_matchers.py +0 -0
- {nti_testing-4.5.0 → nti_testing-4.5.1}/src/nti/testing/tests/test_time.py +0 -0
- {nti_testing-4.5.0 → nti_testing-4.5.1}/src/nti/testing/tests/test_zodb.py +0 -0
- {nti_testing-4.5.0 → nti_testing-4.5.1}/src/nti/testing/time.py +0 -0
- {nti_testing-4.5.0 → nti_testing-4.5.1}/src/nti/testing/zodb.py +0 -0
- {nti_testing-4.5.0 → nti_testing-4.5.1}/src/nti.testing.egg-info/dependency_links.txt +0 -0
- {nti_testing-4.5.0 → nti_testing-4.5.1}/src/nti.testing.egg-info/requires.txt +0 -0
- {nti_testing-4.5.0 → nti_testing-4.5.1}/src/nti.testing.egg-info/top_level.txt +0 -0
- {nti_testing-4.5.0 → nti_testing-4.5.1}/src/nti.testing.egg-info/zip-safe +0 -0
- {nti_testing-4.5.0 → nti_testing-4.5.1}/tox.ini +0 -0
|
@@ -2,7 +2,13 @@
|
|
|
2
2
|
Changes
|
|
3
3
|
=========
|
|
4
4
|
|
|
5
|
-
4.5.
|
|
5
|
+
4.5.1 (2026-07-15)
|
|
6
|
+
==================
|
|
7
|
+
|
|
8
|
+
- Make ``patch_object`` really return the mock object, as documented.
|
|
9
|
+
|
|
10
|
+
|
|
11
|
+
4.5.0 (2026-07-07)
|
|
6
12
|
==================
|
|
7
13
|
|
|
8
14
|
- Add ``patch_object`` to the test bases.
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
Metadata-Version: 2.4
|
|
2
2
|
Name: nti.testing
|
|
3
|
-
Version: 4.5.
|
|
3
|
+
Version: 4.5.1
|
|
4
4
|
Summary: Support for testing code
|
|
5
5
|
Home-page: https://github.com/OpenNTI/nti.testing
|
|
6
6
|
Author: Jason Madden
|
|
@@ -323,7 +323,13 @@ ZODB in `nti.testing.zodb`. See the API documentation for details.
|
|
|
323
323
|
Changes
|
|
324
324
|
=========
|
|
325
325
|
|
|
326
|
-
4.5.
|
|
326
|
+
4.5.1 (2026-07-15)
|
|
327
|
+
==================
|
|
328
|
+
|
|
329
|
+
- Make ``patch_object`` really return the mock object, as documented.
|
|
330
|
+
|
|
331
|
+
|
|
332
|
+
4.5.0 (2026-07-07)
|
|
327
333
|
==================
|
|
328
334
|
|
|
329
335
|
- Add ``patch_object`` to the test bases.
|
|
@@ -173,9 +173,11 @@ class PatchingMixin:
|
|
|
173
173
|
|
|
174
174
|
Returns the result of ``patch.start()``, i.e., a mock object.
|
|
175
175
|
|
|
176
|
-
.. versionadded::
|
|
176
|
+
.. versionadded:: 4.5.0
|
|
177
|
+
.. versionchanged:: 4.5.1
|
|
178
|
+
Actually return the mock object.
|
|
177
179
|
"""
|
|
178
|
-
self._install_patch(Patch.object(target, attribute, *args, **kwargs))
|
|
180
|
+
return self._install_patch(Patch.object(target, attribute, *args, **kwargs))
|
|
179
181
|
|
|
180
182
|
def _install_patch(self, patcher):
|
|
181
183
|
"""
|
|
@@ -167,6 +167,7 @@ class TestPatchingMixin(base.PatchingMixin, unittest.TestCase):
|
|
|
167
167
|
return -1
|
|
168
168
|
|
|
169
169
|
to_patch = ToPatch()
|
|
170
|
-
self.patch_object(to_patch, 'meth', return_value=42)
|
|
170
|
+
patch_result = self.patch_object(to_patch, 'meth', return_value=42)
|
|
171
171
|
|
|
172
172
|
self.assertEqual(to_patch.meth(), 42)
|
|
173
|
+
self.assertIsNotNone(patch_result)
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
Metadata-Version: 2.4
|
|
2
2
|
Name: nti.testing
|
|
3
|
-
Version: 4.5.
|
|
3
|
+
Version: 4.5.1
|
|
4
4
|
Summary: Support for testing code
|
|
5
5
|
Home-page: https://github.com/OpenNTI/nti.testing
|
|
6
6
|
Author: Jason Madden
|
|
@@ -323,7 +323,13 @@ ZODB in `nti.testing.zodb`. See the API documentation for details.
|
|
|
323
323
|
Changes
|
|
324
324
|
=========
|
|
325
325
|
|
|
326
|
-
4.5.
|
|
326
|
+
4.5.1 (2026-07-15)
|
|
327
|
+
==================
|
|
328
|
+
|
|
329
|
+
- Make ``patch_object`` really return the mock object, as documented.
|
|
330
|
+
|
|
331
|
+
|
|
332
|
+
4.5.0 (2026-07-07)
|
|
327
333
|
==================
|
|
328
334
|
|
|
329
335
|
- Add ``patch_object`` to the test bases.
|
|
@@ -1,5 +1,4 @@
|
|
|
1
1
|
.coveragerc
|
|
2
|
-
.gitignore
|
|
3
2
|
.isort.cfg
|
|
4
3
|
.nti_cover_package
|
|
5
4
|
.pylintrc
|
|
@@ -16,7 +15,6 @@ doc-requirements.txt
|
|
|
16
15
|
pyproject.toml
|
|
17
16
|
setup.py
|
|
18
17
|
tox.ini
|
|
19
|
-
.github/workflows/tests.yml
|
|
20
18
|
docs/api.rst
|
|
21
19
|
docs/base.rst
|
|
22
20
|
docs/changelog.rst
|
|
@@ -26,13 +24,6 @@ docs/layers.rst
|
|
|
26
24
|
docs/matchers.rst
|
|
27
25
|
docs/time.rst
|
|
28
26
|
docs/zodb.rst
|
|
29
|
-
docs/_build/html/_static/basic.css
|
|
30
|
-
docs/_build/html/_static/custom.css
|
|
31
|
-
docs/_build/html/_static/debug.css
|
|
32
|
-
docs/_build/html/_static/pygments.css
|
|
33
|
-
docs/_build/html/_static/skeleton.css
|
|
34
|
-
docs/_build/html/_static/styles/furo-extensions.css
|
|
35
|
-
docs/_build/html/_static/styles/furo.css
|
|
36
27
|
docs/_static/custom.css
|
|
37
28
|
src/nti/__init__.py
|
|
38
29
|
src/nti.testing.egg-info/PKG-INFO
|
|
@@ -1,68 +0,0 @@
|
|
|
1
|
-
name: tests
|
|
2
|
-
|
|
3
|
-
on: [push, pull_request]
|
|
4
|
-
|
|
5
|
-
env:
|
|
6
|
-
PYTHONHASHSEED: 1042466059
|
|
7
|
-
ZOPE_INTERFACE_STRICT_IRO: 1
|
|
8
|
-
|
|
9
|
-
|
|
10
|
-
|
|
11
|
-
jobs:
|
|
12
|
-
test:
|
|
13
|
-
strategy:
|
|
14
|
-
matrix:
|
|
15
|
-
python-version:
|
|
16
|
-
- "pypy-3.11"
|
|
17
|
-
- "3.10"
|
|
18
|
-
- "3.11"
|
|
19
|
-
- "3.12"
|
|
20
|
-
- "3.13"
|
|
21
|
-
- "3.14"
|
|
22
|
-
- "3.15-dev"
|
|
23
|
-
extras:
|
|
24
|
-
- "[test,docs,zodb,test-zodb]"
|
|
25
|
-
|
|
26
|
-
runs-on: ubuntu-latest
|
|
27
|
-
steps:
|
|
28
|
-
- uses: actions/checkout@v7
|
|
29
|
-
- name: Set up Python
|
|
30
|
-
uses: actions/setup-python@v6
|
|
31
|
-
with:
|
|
32
|
-
python-version: ${{ matrix.python-version }}
|
|
33
|
-
cache: 'pip'
|
|
34
|
-
cache-dependency-path: 'setup.py'
|
|
35
|
-
- name: Install dependencies
|
|
36
|
-
run: |
|
|
37
|
-
python -m pip install -U pip setuptools wheel
|
|
38
|
-
python -m pip install -U coverage
|
|
39
|
-
python -m pip install -U -e ".${{ matrix.extras }}"
|
|
40
|
-
- name: Test
|
|
41
|
-
run: |
|
|
42
|
-
coverage run -m zope.testrunner --test-path=src --auto-color --auto-progress
|
|
43
|
-
coverage run -a -m sphinx -b doctest -d docs/_build/doctrees docs docs/_build/doctests
|
|
44
|
-
coverage combine || true
|
|
45
|
-
coverage report -i || true
|
|
46
|
-
- name: Lint
|
|
47
|
-
if: matrix.python-version == '3.14'
|
|
48
|
-
run: |
|
|
49
|
-
python -m pip install -U pylint
|
|
50
|
-
pylint src
|
|
51
|
-
- name: Test No ZODB
|
|
52
|
-
run: |
|
|
53
|
-
python -m pip uninstall -y ZODB zope.site persistent
|
|
54
|
-
python -m zope.testrunner --test-path=src --auto-color --auto-progress
|
|
55
|
-
- name: Submit to Coveralls
|
|
56
|
-
# This is a container action, which only runs on Linux.
|
|
57
|
-
uses: AndreMiras/coveralls-python-action@develop
|
|
58
|
-
with:
|
|
59
|
-
parallel: true
|
|
60
|
-
|
|
61
|
-
coveralls_finish:
|
|
62
|
-
needs: test
|
|
63
|
-
runs-on: ubuntu-latest
|
|
64
|
-
steps:
|
|
65
|
-
- name: Coveralls Finished
|
|
66
|
-
uses: AndreMiras/coveralls-python-action@develop
|
|
67
|
-
with:
|
|
68
|
-
parallel-finished: true
|