-
epriestley authored
Test for "CAN_INTERACT" on comment edits in a way that survives objects which only implement "CAN_VIEW" Summary: Ref T13289. See D20551. In D20551, I implemented some "CAN_INTERACT" checks against certain edits, but these checks end up testing "CAN_INTERACT" against objects like Conpherence threads which do not support a distinct "CAN_INTERACT" permission. I misrembered how the "CAN_INTERACT" fallback to "CAN_VIEW" actually works: it's not fully automatic, and needs some explicit "interact, or view if interact is not available" checks. Use the "interact" wrappers to test these policies so they fall back to "CAN_VIEW" if an object does not support "CAN_INTERACT". Generally, objects which have a "locked" state have a separate "CAN_INTERACT" permission; objects which don't have a "locked" state do not. Test Plan: Created and edited comments in Conpherence (or most applications other than Maniphest). Reviewers: amckinley Maniphest Tasks: T13289 Differential Revision: https://secure.phabricator.com/D20558
53b9acfb