]> khamidou — GitHub mirrors - arcanist.git/commit
Improve getLink method for unit tests
authorJoshua Spence <josh@joshuaspence.com>
Tue, 19 May 2015 23:36:22 +0000 (09:36 +1000)
committerJoshua Spence <josh@joshuaspence.com>
Tue, 19 May 2015 23:36:22 +0000 (09:36 +1000)
commit399f0400185fccc34c347a376694d58ccb05f084
treef071d0697d10d6465efe6b6ab699c40b6ba6e342
parent1d72cfc94421fa1cc1bf88ba124bb55beb6ba6c3
Improve getLink method for unit tests

Summary:
Ref T7977. The `PhutilTestCase::getLink` method currently relies on arcanist projects instead of repositories. Instead, make this logic a bit smarter by looking up the base URI from `phabricator.uri` (currently it is hardcoded to `https://secure.phabricator.com`).

Ideally, we would pass `?repositories=$REPOSITORY_PHID` to `DiffusionSymbolController` as well, but I don't know if this is worth pursuing.

Test Plan: This diff.

Reviewers: avivey, #blessed_reviewers, epriestley

Reviewed By: avivey, #blessed_reviewers, epriestley

Subscribers: aurelijus, Korvin, epriestley

Maniphest Tasks: T7977

Differential Revision: https://secure.phabricator.com/D12664
src/infrastructure/testing/ArcanistTestCase.php
src/unit/engine/PhutilUnitTestEngine.php
src/unit/engine/XUnitTestEngine.php
src/unit/engine/__tests__/PhutilUnitTestEngineTestCase.php
src/unit/engine/phutil/ArcanistPhutilTestCase.php