fix: update sdk beta test expectations - #503
Conversation
There was a problem hiding this comment.
Pull request overview
This PR updates unit test expectations to align with SDK beta.29 validation behavior, reducing brittleness around generated SDK exception messages while keeping unsupported-carrier handling covered via Carrier::isSupported().
Changes:
- Relax
CapabilitiesService::getContractDefinitions()invalid-carrier assertion to avoid matching the full generated SDK exception message. - Update
Carriermodel tests to treat unknown carrier names as “unsupported” rather than expecting a constructor exception.
Reviewed changes
Copilot reviewed 2 out of 2 changed files in this pull request and generated 1 comment.
| File | Description |
|---|---|
| tests/Unit/SdkApi/Service/CoreApi/Shipment/CapabilitiesServiceTest.php | Adjusts invalid-carrier assertion to avoid coupling tests to SDK-generated exception message details. |
| tests/Unit/Carrier/Model/CarrierTest.php | Updates behavior expectation for unknown carriers to be “unsupported” via Carrier::isSupported(). |
💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.
Codecov Report✅ All modified and coverable lines are covered by tests. Additional details and impacted files@@ Coverage Diff @@
## main #503 +/- ##
============================================
+ Coverage 94.21% 94.25% +0.03%
Complexity 2350 2350
============================================
Files 350 350
Lines 7538 7538
============================================
+ Hits 7102 7105 +3
+ Misses 436 433 -3 ☔ View full report in Codecov by Harness. 🚀 New features to boost your workflow:
|
|
🎉 This PR is included in version 4.2.1 🎉 The release is available on GitHub release Your semantic-release bot 📦🚀 |
Uh oh!
There was an error while loading. Please reload this page.