Page MenuHomePhabricator

Merge PhutilGitURI into PhutilURI
ClosedPublic

Authored by epriestley on Jun 13 2016, 12:41 PM.
Tags
None
Referenced Files
F14006469: D16099.id38739.diff
Mon, Oct 28, 10:33 AM
F13997764: D16099.diff
Thu, Oct 24, 6:05 AM
F13996941: D16099.id38737.diff
Thu, Oct 24, 1:13 AM
F13983380: D16099.id38735.diff
Sun, Oct 20, 6:08 AM
F13976549: D16099.diff
Fri, Oct 18, 2:45 PM
F13974498: D16099.id38733.diff
Fri, Oct 18, 5:52 AM
Unknown Object (File)
Sun, Oct 13, 6:45 AM
Unknown Object (File)
Sun, Oct 13, 6:44 AM
Subscribers
None

Details

Summary

Ref T11137. This addresses three general issues:

  • From T11137, I recently added a bad typehint.
  • From T11004, we currently have buggy behavior with Git URIs that have relative paths: we convert them into "ssh://" URIs but change the meaning of their paths.
  • Generally, Phabricator has a lot of instanceof-flavored code around URI handling, and this has been a frequent source of errors. See some discussion in T11137. See next revision for changes to Phabricator.
Test Plan

Unit tests; see next revision for field testing.

Diff Detail

Repository
rPHU libphutil
Branch
gituri1
Lint
Lint Passed
Unit
Tests Passed
Build Status
Buildable 12610
Build 16009: Run Core Tests
Build 16008: arc lint + arc unit

Unit TestsFailed

TimeTest
0 msPhutilMarkupTestCase::Unknown Unit Message ("")
Assertion failed, expected values to be equal (at PhutilMarkupTestCase.php:179): Rejected href: Expected: true Actual: false
25 msPhutilRemarkupEngineTestCase::Unknown Unit Message ("")
Assertion failed, expected values to be equal (at PhutilRemarkupEngineTestCase.php:63): Failed to markup HTML in file 'link-mailto.txt'. Expected vs Actual Output Diff --- Old Value
1 msAbstractDirectedGraphTestCase::Unknown Unit Message ("")
2 assertions passed.
0 msAbstractDirectedGraphTestCase::Unknown Unit Message ("")
1 assertion passed.
0 msAbstractDirectedGraphTestCase::Unknown Unit Message ("")
1 assertion passed.
View Full Test Results (2 Failed · 341 Passed · 2 Skipped)

Event Timeline

epriestley retitled this revision from to Merge PhutilGitURI into PhutilURI.
epriestley updated this object.
epriestley edited the test plan for this revision. (Show Details)
epriestley added a reviewer: chad.
  • Test behavior for URIs with no protocol.
  • Test behavior for creating new Git URIs from other Git URIs.
  • Test behavior for implicit SSH protocol on Git URIs.
  • Remove "INVALID_PATH" faux-error.

Fixing those other test issues.

  • Fix ambiguous cases of "javascript:evil" and "mailto:user@domain".
  • Improve ease of debugging markup test case.
chad edited edge metadata.
This revision is now accepted and ready to land.Jun 13 2016, 2:18 PM
This revision was automatically updated to reflect the committed changes.