#2829295: Improve test coverage and function docs: context introduced a regression. The class ctools_context_optional is missing the required property override to FALSE from the parent ctools_context_required class.
This caused page elements on context admin pages to completely disappear.
Solution: define class property default values on the property itself where possible. That way subclasses can easily override them and don't need to copy the constructor.
| Comment | File | Size | Author |
|---|---|---|---|
| #3 | ctools-2905885-3.patch | 2.72 KB | klausi |
Comments
Comment #2
klausiPatch. Still needs tests to make sure that this doesn't happen again.
Comment #3
klausiNow with a unit test.
Comment #5
klausiPerfect, test only patch failing as expected.
Comment #6
rivimeyAs author of earlier patch, apologies for the regression.
Checked this by eye and it all looks good - thanks for a new test and for demoing the test-only fail.
Comment #7
joelpittetThanks @klausi
Comment #8
japerryLooks good to me too.
Comment #10
joelpittetThank you @klausi, I've committed and pushed this to -dev