MPT-22199 use camelCase documentType key in product document fixtures#346
Conversation
…s (MPT-22199) The sync and async product-document e2e fixtures set the dictionary key "documenttype" (all lowercase) instead of the camelCase "documentType" expected by the MPT API. With the wrong-cased key the document type was never sent, so the created_document_from_file(_async) fixtures created documents without a type and the product document e2e tests failed. Align both fixtures with the API field name and the rest of the suite, which already uses "documentType". Co-Authored-By: Claude Opus 4.8 <noreply@anthropic.com>
|
No actionable comments were generated in the recent review. 🎉 ℹ️ Recent review info⚙️ Run configurationConfiguration used: Repository YAML (base), Organization UI (inherited) Review profile: CHILL Plan: Pro Run ID: 📒 Files selected for processing (2)
🔗 Linked repositories identifiedCodeRabbit considers these linked repositories for cross-repo context during reviews:
📜 Recent review details🧰 Additional context used📓 Path-based instructions (2)**/*⚙️ CodeRabbit configuration file
Files:
**⚙️ CodeRabbit configuration file
Files:
🧠 Learnings (7)📚 Learning: 2025-12-12T15:02:20.732ZApplied to files:
📚 Learning: 2026-04-02T09:35:03.825ZApplied to files:
📚 Learning: 2026-01-08T08:34:05.465ZApplied to files:
📚 Learning: 2026-01-08T08:34:19.306ZApplied to files:
📚 Learning: 2026-01-08T23:38:19.565ZApplied to files:
📚 Learning: 2026-02-02T13:05:41.144ZApplied to files:
📚 Learning: 2026-04-16T13:00:41.320ZApplied to files:
🔇 Additional comments (2)
📝 WalkthroughWalkthroughTwo e2e test fixtures for document creation are corrected to use the proper camelCase field name ChangesDocument type field name casing fixes
🎯 1 (Trivial) | ⏱️ ~3 minutes Important Pre-merge checks failedPlease resolve all errors before merging. Addressing warnings is optional. ❌ Failed checks (1 inconclusive)
✅ Passed checks (3 passed)
Comment |
|



🤖 AI-generated PR — Please review carefully.
What
Fix a wrong-cased dictionary key in the product-document e2e fixtures.
The sync and async product-document fixtures set
document_data["documenttype"] = "File"using an all-lowercase key. The MPT API expects the camelCase fielddocumentType, which the rest of the suite already uses (e.g.tests/e2e/integration/extension_documents/conftest.py,tests/e2e/program/program/document/conftest.py). With the wrong-cased key thedocumentTypevalue was never sent, so thecreated_document_from_file/created_document_from_file_asyncfixtures created documents without a type and the product-document e2e tests failed.Changed files
tests/e2e/catalog/product/documents/test_sync_document.pytests/e2e/catalog/product/documents/test_async_document.pyTesting
make check(Docker):ruff format --check,ruff check,flake8,mypy,uv lock --check— all pass on the project tree.make test(Docker): 2285 unit tests passed.Closes MPT-22199
Closes MPT-22199
documentTypekey in product-document e2e fixtures (test_sync_document.pyandtest_async_document.py)documenttypeto camelCasedocumentTypeto match the MPT API's expected field name