@@ -55,8 +55,10 @@ class _FakePostgresSettings(BaseCustomSettings):
5555 POSTGRES_PASSWORD : str
5656
5757 POSTGRES_DB : str
58- POSTGRES_MINSIZE : Annotated [int , Field (ge = 2 )] = 2
59- POSTGRES_MAXSIZE : Annotated [int , Field (ge = 2 )] = 50
58+ POSTGRES_MINSIZE : Annotated [int , Field (ge = 1 )] = 1
59+ POSTGRES_MAXSIZE : Annotated [int , Field (ge = 1 )] = 50
60+ POSTGRES_MAX_POOLSIZE : int = 10
61+ POSTGRES_MAX_OVERFLOW : Annotated [int , Field (ge = 0 )] = 20
6062
6163 POSTGRES_CLIENT_NAME : Annotated [
6264 str | None ,
@@ -126,7 +128,6 @@ class S5(BaseCustomSettings):
126128def test_parse_from_empty_envs (
127129 postgres_envvars_unset : None , model_classes_factory : Callable
128130):
129-
130131 S1 , S2 , S3 , S4 , S5 = model_classes_factory ()
131132
132133 with pytest .raises (ValidationError , match = "WEBSERVER_POSTGRES" ) as exc_info :
@@ -160,7 +161,6 @@ def test_parse_from_individual_envs(
160161 monkeypatch : pytest .MonkeyPatch ,
161162 model_classes_factory : Callable ,
162163):
163-
164164 S1 , S2 , S3 , S4 , S5 = model_classes_factory ()
165165
166166 # environment
@@ -232,7 +232,6 @@ def test_parse_from_individual_envs(
232232def test_parse_compact_env (
233233 postgres_envvars_unset : None , monkeypatch , model_classes_factory
234234):
235-
236235 S1 , S2 , S3 , S4 , S5 = model_classes_factory ()
237236
238237 # environment
@@ -348,7 +347,6 @@ def test_parse_compact_env(
348347def test_parse_from_mixed_envs (
349348 postgres_envvars_unset : None , monkeypatch , model_classes_factory
350349):
351-
352350 S1 , S2 , S3 , S4 , S5 = model_classes_factory ()
353351
354352 # environment
@@ -480,7 +478,6 @@ def test_parse_from_mixed_envs(
480478def test_toggle_plugin_1 (
481479 postgres_envvars_unset : None , monkeypatch , model_classes_factory
482480):
483-
484481 * _ , S4 , S5 = model_classes_factory ()
485482
486483 # empty environ
@@ -543,7 +540,6 @@ def test_toggle_plugin_3(
543540def test_toggle_plugin_4 (
544541 postgres_envvars_unset : None , monkeypatch , model_classes_factory
545542):
546-
547543 * _ , S4 , S5 = model_classes_factory ()
548544 JSON_VALUE = '{"POSTGRES_HOST":"pg2", "POSTGRES_USER":"test2", "POSTGRES_PASSWORD":"shh2", "POSTGRES_DB":"db2"}'
549545
@@ -573,7 +569,6 @@ def test_toggle_plugin_4(
573569 )
574570
575571 with monkeypatch .context () as patch :
576-
577572 # Enables both but remove individuals
578573 setenvs_from_envfile (
579574 patch ,
0 commit comments