1
0
Fork 0
mirror of https://we.phorge.it/source/phorge.git synced 2024-11-11 01:12:41 +01:00
phorge-phorge/src/applications/policy/__tests__
epriestley d6247ffca5 Add support for "Extended Policies"
Summary:
Ref T7703. See that task and inline for a bunch of discussion.

Briefly, when we run implicit policy rules ("to see a revision, you must also be able to see its repository") at query time, they don't apply to other viewers we might check later.

We do this very rarely, but when we do we're often doing it for a bunch of different viewers (for example, in Herald) so I don't want to just reload the object a million times.

Test Plan:
  - Added and executed unit tests.
  - Wrote a "flag everything" Herald rule, as in the original report in T7703, and no longer got "Unknown Object" flags on revisions.
  - Rigged up a lot of cases in the web UI and couldn't find any inconsistencies, although this case is normally very hard to hit.

Reviewers: btrahan

Reviewed By: btrahan

Subscribers: epriestley

Maniphest Tasks: T7703

Differential Revision: https://secure.phabricator.com/D13104
2015-06-03 18:59:27 -07:00
..
PhabricatorPolicyAwareTestQuery.php Fix method visibility for PhabricatorPolicyAwareQuery subclasses 2015-01-14 07:01:16 +11:00
PhabricatorPolicyDataTestCase.php Rename PhabricatorPolicyRule subclasses for consistency 2015-01-03 23:48:55 +11:00
PhabricatorPolicyTestCase.php Add support for "Extended Policies" 2015-06-03 18:59:27 -07:00
PhabricatorPolicyTestObject.php Add support for "Extended Policies" 2015-06-03 18:59:27 -07:00