@@ -1228,7 +1228,7 @@ class MockConfig:
1228
1228
# Patch is_pydantic_model to return 2 (v2) for our mock
1229
1229
monkeypatch .setattr (
1230
1230
"jsonargparse._optionals.is_pydantic_model" ,
1231
- lambda cls : 2 if cls is mock_model_v2 else is_pydantic_model (cls )
1231
+ lambda cls : 2 if cls is mock_model_v2 else is_pydantic_model (cls ),
1232
1232
)
1233
1233
1234
1234
# This should hit the direct attribute access branch
@@ -1252,7 +1252,7 @@ class MockConfig:
1252
1252
# Patch is_pydantic_model to return 2 (v2) for our mock
1253
1253
monkeypatch .setattr (
1254
1254
"jsonargparse._optionals.is_pydantic_model" ,
1255
- lambda cls : 2 if cls is mock_model_v2_legacy else is_pydantic_model (cls )
1255
+ lambda cls : 2 if cls is mock_model_v2_legacy else is_pydantic_model (cls ),
1256
1256
)
1257
1257
1258
1258
# This should hit the legacy __config__ branch for v2
@@ -1274,7 +1274,7 @@ class MockPydanticModel:
1274
1274
# Patch is_pydantic_model to return 1 (v1) for our mock
1275
1275
monkeypatch .setattr (
1276
1276
"jsonargparse._optionals.is_pydantic_model" ,
1277
- lambda cls : 1 if cls is mock_model_v1 else is_pydantic_model (cls )
1277
+ lambda cls : 1 if cls is mock_model_v1 else is_pydantic_model (cls ),
1278
1278
)
1279
1279
1280
1280
# This should hit the string extra_value branch
@@ -1300,7 +1300,7 @@ def __str__(self):
1300
1300
# Patch is_pydantic_model to return 1 (v1) for our mock
1301
1301
monkeypatch .setattr (
1302
1302
"jsonargparse._optionals.is_pydantic_model" ,
1303
- lambda cls : 1 if cls is mock_model_v1_enum else is_pydantic_model (cls )
1303
+ lambda cls : 1 if cls is mock_model_v1_enum else is_pydantic_model (cls ),
1304
1304
)
1305
1305
1306
1306
# This should hit the string conversion branch
@@ -1325,7 +1325,7 @@ def __config__(self):
1325
1325
# Patch is_pydantic_model to return 2 (v2) for our mock
1326
1326
monkeypatch .setattr (
1327
1327
"jsonargparse._optionals.is_pydantic_model" ,
1328
- lambda cls : 2 if cls is exception_model else is_pydantic_model (cls )
1328
+ lambda cls : 2 if cls is exception_model else is_pydantic_model (cls ),
1329
1329
)
1330
1330
1331
1331
# This should hit the exception handling branch
0 commit comments