simple-module-test 0.0.39__tar.gz → 0.0.40__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.
- {simple_module_test-0.0.39 → simple_module_test-0.0.40}/PKG-INFO +5 -5
- {simple_module_test-0.0.39 → simple_module_test-0.0.40}/pyproject.toml +5 -5
- {simple_module_test-0.0.39 → simple_module_test-0.0.40}/simple_module_test/_schema.py +17 -3
- {simple_module_test-0.0.39 → simple_module_test-0.0.40}/.gitignore +0 -0
- {simple_module_test-0.0.39 → simple_module_test-0.0.40}/LICENSE +0 -0
- {simple_module_test-0.0.39 → simple_module_test-0.0.40}/README.md +0 -0
- {simple_module_test-0.0.39 → simple_module_test-0.0.40}/simple_module_test/__init__.py +0 -0
- {simple_module_test-0.0.39 → simple_module_test-0.0.40}/simple_module_test/app_factory.py +0 -0
- {simple_module_test-0.0.39 → simple_module_test-0.0.40}/simple_module_test/database.py +0 -0
- {simple_module_test-0.0.39 → simple_module_test-0.0.40}/simple_module_test/fake_events.py +0 -0
- {simple_module_test-0.0.39 → simple_module_test-0.0.40}/simple_module_test/fixtures.py +0 -0
- {simple_module_test-0.0.39 → simple_module_test-0.0.40}/simple_module_test/mail.py +0 -0
- {simple_module_test-0.0.39 → simple_module_test-0.0.40}/simple_module_test/plugin.py +0 -0
- {simple_module_test-0.0.39 → simple_module_test-0.0.40}/simple_module_test/process_state.py +0 -0
- {simple_module_test-0.0.39 → simple_module_test-0.0.40}/simple_module_test/redis_server.py +0 -0
- {simple_module_test-0.0.39 → simple_module_test-0.0.40}/simple_module_test/routes.py +0 -0
- {simple_module_test-0.0.39 → simple_module_test-0.0.40}/simple_module_test/session_cookie.py +0 -0
- {simple_module_test-0.0.39 → simple_module_test-0.0.40}/simple_module_test/setup_wizard.py +0 -0
- {simple_module_test-0.0.39 → simple_module_test-0.0.40}/simple_module_test/tenant_client.py +0 -0
- {simple_module_test-0.0.39 → simple_module_test-0.0.40}/simple_module_test/waiting.py +0 -0
- {simple_module_test-0.0.39 → simple_module_test-0.0.40}/tests/test_app_factory.py +0 -0
- {simple_module_test-0.0.39 → simple_module_test-0.0.40}/tests/test_fake_events.py +0 -0
- {simple_module_test-0.0.39 → simple_module_test-0.0.40}/tests/test_plugin_fixtures.py +0 -0
- {simple_module_test-0.0.39 → simple_module_test-0.0.40}/tests/test_schema_reuse_pg.py +0 -0
- {simple_module_test-0.0.39 → simple_module_test-0.0.40}/tests/test_testing_process_state.py +0 -0
- {simple_module_test-0.0.39 → simple_module_test-0.0.40}/tests/test_waiting_helpers.py +0 -0
- {simple_module_test-0.0.39 → simple_module_test-0.0.40}/tests/test_worker_database.py +0 -0
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
Metadata-Version: 2.5
|
|
2
2
|
Name: simple_module_test
|
|
3
|
-
Version: 0.0.
|
|
3
|
+
Version: 0.0.40
|
|
4
4
|
Summary: Shared pytest fixtures (app, client, db_session, authenticated_client) for writing simple_module module tests
|
|
5
5
|
Project-URL: Homepage, https://github.com/antosubash/simple_module_python
|
|
6
6
|
Project-URL: Repository, https://github.com/antosubash/simple_module_python
|
|
@@ -21,13 +21,13 @@ Classifier: Programming Language :: Python :: 3.12
|
|
|
21
21
|
Classifier: Topic :: Software Development :: Testing
|
|
22
22
|
Classifier: Typing :: Typed
|
|
23
23
|
Requires-Python: >=3.12
|
|
24
|
-
Requires-Dist: fastapi<0.
|
|
24
|
+
Requires-Dist: fastapi<0.159,>=0.140
|
|
25
25
|
Requires-Dist: httpx<0.29,>=0.27
|
|
26
26
|
Requires-Dist: pytest-asyncio<2,>=0.24
|
|
27
27
|
Requires-Dist: pytest<10,>=8.0
|
|
28
|
-
Requires-Dist: simple-module-core==0.0.
|
|
29
|
-
Requires-Dist: simple-module-db==0.0.
|
|
30
|
-
Requires-Dist: simple-module-hosting==0.0.
|
|
28
|
+
Requires-Dist: simple-module-core==0.0.40
|
|
29
|
+
Requires-Dist: simple-module-db==0.0.40
|
|
30
|
+
Requires-Dist: simple-module-hosting==0.0.40
|
|
31
31
|
Requires-Dist: sqlalchemy<3,>=2.0
|
|
32
32
|
Description-Content-Type: text/markdown
|
|
33
33
|
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
[project]
|
|
2
2
|
name = "simple_module_test"
|
|
3
|
-
version = "0.0.
|
|
3
|
+
version = "0.0.40"
|
|
4
4
|
description = "Shared pytest fixtures (app, client, db_session, authenticated_client) for writing simple_module module tests"
|
|
5
5
|
readme = "README.md"
|
|
6
6
|
license = "MIT"
|
|
@@ -21,13 +21,13 @@ classifiers = [
|
|
|
21
21
|
"Typing :: Typed",
|
|
22
22
|
]
|
|
23
23
|
dependencies = [
|
|
24
|
-
"fastapi>=0.140,<0.
|
|
24
|
+
"fastapi>=0.140,<0.159",
|
|
25
25
|
"httpx>=0.27,<0.29",
|
|
26
26
|
"pytest>=8.0,<10",
|
|
27
27
|
"pytest-asyncio>=0.24,<2",
|
|
28
|
-
"simple_module_core==0.0.
|
|
29
|
-
"simple_module_db==0.0.
|
|
30
|
-
"simple_module_hosting==0.0.
|
|
28
|
+
"simple_module_core==0.0.40",
|
|
29
|
+
"simple_module_db==0.0.40",
|
|
30
|
+
"simple_module_hosting==0.0.40",
|
|
31
31
|
"sqlalchemy>=2.0,<3",
|
|
32
32
|
]
|
|
33
33
|
|
|
@@ -29,9 +29,17 @@ def _ensure_models_imported() -> list:
|
|
|
29
29
|
return list(all_module_bases)
|
|
30
30
|
|
|
31
31
|
|
|
32
|
-
|
|
32
|
+
_heads_cache: tuple[str, ...] | None = None
|
|
33
|
+
|
|
34
|
+
|
|
33
35
|
def _alembic_heads() -> tuple[str, ...]:
|
|
34
|
-
"""
|
|
36
|
+
"""Head revisions — cannot change within a pytest run, once found.
|
|
37
|
+
|
|
38
|
+
Only a non-empty result is cached. ``resolve_head_revisions`` returns ``()``
|
|
39
|
+
when ``alembic.ini`` is not found, which is what happens under a test that
|
|
40
|
+
points ``SM_PROJECT_ROOT`` at a tmp dir; caching that would leave every
|
|
41
|
+
later test in the worker unstamped while its app, resolving the real ini,
|
|
42
|
+
demands the heads ("Database is N revision(s) behind").
|
|
35
43
|
|
|
36
44
|
Plural: each module's first migration sets its own ``branch_labels``, so
|
|
37
45
|
the history has one head per module and a real upgraded database carries
|
|
@@ -39,9 +47,15 @@ def _alembic_heads() -> tuple[str, ...]:
|
|
|
39
47
|
looking un-applied, which now reads as a behind-head schema and puts every
|
|
40
48
|
test app behind the setup gate.
|
|
41
49
|
"""
|
|
50
|
+
global _heads_cache
|
|
42
51
|
from simple_module_hosting.migrations import resolve_head_revisions
|
|
43
52
|
|
|
44
|
-
|
|
53
|
+
if _heads_cache is None:
|
|
54
|
+
heads = resolve_head_revisions()
|
|
55
|
+
if not heads:
|
|
56
|
+
return heads
|
|
57
|
+
_heads_cache = heads
|
|
58
|
+
return _heads_cache
|
|
45
59
|
|
|
46
60
|
|
|
47
61
|
async def _create_all_tables(engine) -> None:
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
{simple_module_test-0.0.39 → simple_module_test-0.0.40}/simple_module_test/session_cookie.py
RENAMED
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|