Page MenuHomePhabricator

Remove all "ObjectHasFile" edge reads and writes
Needs ReviewPublic

Authored by epriestley on Thu, May 12, 10:15 PM.
This revision needs review, but there are no reviewers specified.

Details

Reviewers
None
Maniphest Tasks
Restricted Maniphest Task
Summary

Ref T13603. Migrate all code which interacts with the "ObjectHasFile" edge to use the "Attachments" table instead.

Test Plan
  • Edited a paste's view policy, confirmed associated file secret was scrambled.
  • Verified I could still view paste content as a user who could not naturally view the underlying file.

Diff Detail

Repository
rP Phabricator
Branch
file7
Lint
Lint Passed
Unit
Test Failures
Build Status
Buildable 25718
Build 35546: arc lint + arc unit

Unit TestsFailed

TimeTest
61 msPhabricatorFileTestCase::testFileIndirectScramble
Assertion failed, expected 'true' (at PhabricatorFileTestCase.php:135): Changing attached object view policy should scramble secret. ACTUAL VALUE
30 msPhabricatorFileTestCase::testFileVisibility
Assertion failed, expected values to be equal (at PhabricatorFileTestCase.php:200): Attached File Visibility Expected vs Actual Output Diff --- Old Value
206 msPhabricatorCelerityTestCase::testCelerityMaps
3 assertions passed.
9 msPhabricatorConduitTestCase::testConduitMethods
1 assertion passed.
82 msPhabricatorFileTestCase::testFileDirectScramble
2 assertions passed.
View Full Test Results (2 Failed · 15 Passed)