From 6b9817f179540aa151e6adf7cbe04402f2f2397f Mon Sep 17 00:00:00 2001 From: Samir Boulahtit Date: Sat, 27 Sep 2025 13:47:36 +0200 Subject: [PATCH] test updates to take into account exception management --- .idea/.gitignore | 4 - .idea/Letzshop-Import-v2.iml | 14 - .idea/inspectionProfiles/Project_Default.xml | 6 +- .idea/misc.xml | 4 +- .idea/modules.xml | 2 +- Makefile | 2 +- README-NEXTGEN.md | 400 +++++++++++++++ app/api/v1/product.py | 55 +- app/exceptions/handler.py | 25 +- app/services/admin_service.py | 21 - app/services/auth_service.py | 10 - app/services/product_service.py | 110 ++-- app/services/shop_service.py | 40 -- app/services/stats_service.py | 42 -- app/services/stock_service.py | 18 +- app/utils/data_processing.py | 8 +- docs/api/index.md | 6 +- middleware/auth.py | 2 +- models/schemas/auth.py | 23 +- models/schemas/marketplace.py | 44 +- models/schemas/product.py | 27 +- models/schemas/shop.py | 73 +-- models/schemas/stock.py | 27 +- tests/.coverage | Bin 53248 -> 53248 bytes tests/fixtures/product_fixtures.py | 15 + .../integration/api/v1/test_auth_endpoints.py | 15 - tests/integration/api/v1/test_filtering.py | 146 ++++-- tests/integration/api/v1/test_pagination.py | 268 +++++++++- .../api/v1/test_product_endpoints.py | 244 +++++++-- .../integration/api/v1/test_product_export.py | 287 ++++++++++- .../integration/api/v1/test_shop_endpoints.py | 366 ++++++++++++- .../api/v1/test_stock_endpoints.py | 343 ++++++++++++- tests/system/test_error_handling.py | 479 ++++++++++++++---- tests/unit/services/test_auth_service.py | 8 +- tests/unit/services/test_product_service.py | 7 +- tests/unit/services/test_shop_service.py | 276 +++++++--- tests/unit/services/test_stats_service.py | 18 +- tests/unit/services/test_stock_service.py | 387 +++++++++----- 38 files changed, 2951 insertions(+), 871 deletions(-) delete mode 100644 .idea/.gitignore delete mode 100644 .idea/Letzshop-Import-v2.iml create mode 100644 README-NEXTGEN.md diff --git a/.idea/.gitignore b/.idea/.gitignore deleted file mode 100644 index 351c96db..00000000 --- a/.idea/.gitignore +++ /dev/null @@ -1,4 +0,0 @@ -# Default ignored files -/shelf/ -/workspace.xml - diff --git a/.idea/Letzshop-Import-v2.iml b/.idea/Letzshop-Import-v2.iml deleted file mode 100644 index fc0b0f27..00000000 --- a/.idea/Letzshop-Import-v2.iml +++ /dev/null @@ -1,14 +0,0 @@ - - - - - - - - - - - - \ No newline at end of file diff --git a/.idea/inspectionProfiles/Project_Default.xml b/.idea/inspectionProfiles/Project_Default.xml index 930c0173..ace3249f 100644 --- a/.idea/inspectionProfiles/Project_Default.xml +++ b/.idea/inspectionProfiles/Project_Default.xml @@ -3,11 +3,7 @@