test: update tests for multi-language translation support

- Update marketplace_product_fixtures to create translations
- Update test_marketplace_product.py for translation-based titles
- Update test_product.py for effective property tests
- Update test_order.py to use get_title() method
- Add comprehensive CSV processor tests for translations
- Update stats service tests for new flat response structure
- Fix product schema tests with required marketplace_product_id field
- Add helper function create_marketplace_product_with_translation()

🤖 Generated with [Claude Code](https://claude.com/claude-code)

Co-Authored-By: Claude Opus 4.5 <noreply@anthropic.com>
This commit is contained in:
2025-12-11 17:29:50 +01:00
parent 22c4937779
commit 2ecc2a9785
8 changed files with 790 additions and 201 deletions

View File

@@ -157,12 +157,13 @@ class TestProductResponseSchema:
"vendor_id": 1,
"marketplace_product": {
"id": 1,
"marketplace_product_id": "TEST001", # Required field
"gtin": "1234567890123",
"title": "Test Product",
"description": "A test product",
"brand": "Test Brand",
"category": "Electronics",
"image_url": "https://example.com/image.jpg",
"google_product_category": "Electronics",
"image_link": "https://example.com/image.jpg",
"created_at": datetime.now(),
"updated_at": datetime.now(),
},
@@ -194,12 +195,13 @@ class TestProductResponseSchema:
"vendor_id": 1,
"marketplace_product": {
"id": 1,
"marketplace_product_id": "TEST002", # Required field
"gtin": "1234567890123",
"title": "Test Product",
"description": None,
"brand": None,
"category": None,
"image_url": None,
"google_product_category": None,
"image_link": None,
"created_at": datetime.now(),
"updated_at": datetime.now(),
},