-
-
Notifications
You must be signed in to change notification settings - Fork 49
Expand test coverage for renderer type validation to include non-object types #297
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
base: 289-double-extensions
Are you sure you want to change the base?
Conversation
Co-authored-by: samdark <47294+samdark@users.noreply.github.com>
|
Just as a heads up, I was blocked by some firewall rules while working on your feedback. Expand below for details. Warning Firewall rules blocked me from connecting to one or more addresses (expand for details)I tried to connect to the following addresses, but was blocked by firewall rules:
If you need me to access, download, or install something from one of these locations, you can either:
|
Codecov Report✅ All modified and coverable lines are covered by tests. Additional details and impacted files@@ Coverage Diff @@
## 289-double-extensions #297 +/- ##
========================================================
Coverage 99.51% 99.51%
Complexity 310 310
========================================================
Files 19 19
Lines 822 822
========================================================
Hits 818 818
Misses 4 4 ☔ View full report in Codecov by Sentry. 🚀 New features to boost your workflow:
|
The existing test coverage for
ViewTrait::withRenderers()validation only tested rejection of objects not implementingTemplateRendererInterface(viastdClass). The validation logic also handles non-object types like null, strings, arrays, and scalars, but these cases were untested.Changes
Added four test cases to verify validation behavior for non-object renderer values:
testWithRenderersNullRendererThrowsException- null valuestestWithRenderersStringRendererThrowsException- string valuestestWithRenderersArrayRendererThrowsException- array valuestestWithRenderersIntegerRendererThrowsException- scalar valuesEach test verifies the error message includes the correct type (via
get_debug_type()) in the format:✨ Let Copilot coding agent set things up for you — coding agent works faster and does higher quality work when set up for your repo.