1
0
Fork 0
mirror of https://we.phorge.it/source/phorge.git synced 2024-12-19 03:50:54 +01:00

Replace ArcanistPhutilTestCase refs with PhutilTestCase

Summary: Ref T7977. Remove the `PhabricatorTestCase::getLink` method. Depends on D12665.

Test Plan: `arc unit`.

Reviewers: avivey, #blessed_reviewers, epriestley

Reviewed By: avivey, #blessed_reviewers, epriestley

Subscribers: Korvin, epriestley

Maniphest Tasks: T7977

Differential Revision: https://secure.phabricator.com/D12667
This commit is contained in:
Joshua Spence 2015-05-20 09:37:39 +10:00
parent 2154f17b3d
commit 69940f2b9e
8 changed files with 13 additions and 21 deletions

View file

@ -3532,7 +3532,7 @@ phutil_register_library_map(array(
'DifferentialActionEmailCommand' => 'MetaMTAEmailTransactionCommand',
'DifferentialActionMenuEventListener' => 'PhabricatorEventListener',
'DifferentialAddCommentView' => 'AphrontView',
'DifferentialAdjustmentMapTestCase' => 'ArcanistPhutilTestCase',
'DifferentialAdjustmentMapTestCase' => 'PhutilTestCase',
'DifferentialAffectedPath' => 'DifferentialDAO',
'DifferentialApplyPatchField' => 'DifferentialCustomField',
'DifferentialAsanaRepresentationField' => 'DifferentialCustomField',
@ -3597,7 +3597,7 @@ phutil_register_library_map(array(
'DifferentialDiffProperty' => 'DifferentialDAO',
'DifferentialDiffQuery' => 'PhabricatorCursorPagedPolicyAwareQuery',
'DifferentialDiffTableOfContentsView' => 'AphrontView',
'DifferentialDiffTestCase' => 'ArcanistPhutilTestCase',
'DifferentialDiffTestCase' => 'PhutilTestCase',
'DifferentialDiffTransaction' => 'PhabricatorApplicationTransaction',
'DifferentialDiffViewController' => 'DifferentialController',
'DifferentialDoorkeeperRevisionFeedStoryPublisher' => 'DoorkeeperFeedStoryPublisher',
@ -3626,7 +3626,7 @@ phutil_register_library_map(array(
),
'DifferentialHunkParserTestCase' => 'PhabricatorTestCase',
'DifferentialHunkQuery' => 'PhabricatorCursorPagedPolicyAwareQuery',
'DifferentialHunkTestCase' => 'ArcanistPhutilTestCase',
'DifferentialHunkTestCase' => 'PhutilTestCase',
'DifferentialInlineComment' => 'PhabricatorInlineCommentInterface',
'DifferentialInlineCommentEditController' => 'PhabricatorInlineCommentController',
'DifferentialInlineCommentPreviewController' => 'PhabricatorInlineCommentPreviewController',
@ -3861,7 +3861,7 @@ phutil_register_library_map(array(
'DiffusionTagListController' => 'DiffusionController',
'DiffusionTagListView' => 'DiffusionView',
'DiffusionTagsQueryConduitAPIMethod' => 'DiffusionQueryConduitAPIMethod',
'DiffusionURITestCase' => 'ArcanistPhutilTestCase',
'DiffusionURITestCase' => 'PhutilTestCase',
'DiffusionUpdateCoverageConduitAPIMethod' => 'DiffusionConduitAPIMethod',
'DiffusionView' => 'AphrontView',
'DivinerArticleAtomizer' => 'DivinerAtomizer',
@ -6083,7 +6083,7 @@ phutil_register_library_map(array(
'PhabricatorTOTPAuthFactorTestCase' => 'PhabricatorTestCase',
'PhabricatorTaskmasterDaemon' => 'PhabricatorDaemon',
'PhabricatorTestApplication' => 'PhabricatorApplication',
'PhabricatorTestCase' => 'ArcanistPhutilTestCase',
'PhabricatorTestCase' => 'PhutilTestCase',
'PhabricatorTestController' => 'PhabricatorController',
'PhabricatorTestNoCycleEdgeType' => 'PhabricatorEdgeType',
'PhabricatorTestStorageEngine' => 'PhabricatorFileStorageEngine',

View file

@ -1,6 +1,6 @@
<?php
final class DifferentialAdjustmentMapTestCase extends ArcanistPhutilTestCase {
final class DifferentialAdjustmentMapTestCase extends PhutilTestCase {
public function testBasicMaps() {
$change_map = array(

View file

@ -1,6 +1,6 @@
<?php
final class DifferentialDiffTestCase extends ArcanistPhutilTestCase {
final class DifferentialDiffTestCase extends PhutilTestCase {
public function testDetectCopiedCode() {
$copies = $this->detectCopiesIn('lint_engine.diff');

View file

@ -1,6 +1,6 @@
<?php
final class DifferentialHunkTestCase extends ArcanistPhutilTestCase {
final class DifferentialHunkTestCase extends PhutilTestCase {
public function testMakeChanges() {
$root = dirname(__FILE__).'/hunk/';

View file

@ -1,6 +1,6 @@
<?php
final class DiffusionURITestCase extends ArcanistPhutilTestCase {
final class DiffusionURITestCase extends PhutilTestCase {
public function testBlobDecode() {
$map = array(

View file

@ -21,7 +21,7 @@ To add new tests to a libphutil, Arcanist or Phabricator module:
- Create a ##__tests__/## directory in the module if it doesn't exist yet.
- Add classes to the ##__tests__/## directory which extend from
@{class:PhabricatorTestCase} (in Phabricator) or
@{class@arcanist:ArcanistPhutilTestCase} (elsewhere).
@{class@arcanist:PhutilTestCase} (elsewhere).
- Run ##arc liberate## on the library root so your classes are loadable.
= Running Tests =
@ -60,7 +60,7 @@ You can see this class at @{class:PhabricatorTrivialTestCase} and run it with:
PASS <1ms* testAllIsRightWithTheWorld
For more information on writing tests, see
@{class@arcanist:ArcanistPhutilTestCase} and @{class:PhabricatorTestCase}.
@{class@arcanist:PhutilTestCase} and @{class:PhabricatorTestCase}.
= Database Isolation =

View file

@ -64,6 +64,6 @@ might look like this:
);
You may also want to filter coverage information to the paths passed to the
unit test engine. See @{class@arcanist:ArcanistPhutilTestCase} and
unit test engine. See @{class@arcanist:PhutilTestCase} and
@{class@arcanist:PhutilUnitTestEngine} for an example of coverage integration
in PHP using Xdebug.

View file

@ -1,6 +1,6 @@
<?php
abstract class PhabricatorTestCase extends ArcanistPhutilTestCase {
abstract class PhabricatorTestCase extends PhutilTestCase {
const NAMESPACE_PREFIX = 'phabricator_unittest_';
@ -166,14 +166,6 @@ abstract class PhabricatorTestCase extends ArcanistPhutilTestCase {
return new PhabricatorStorageFixtureScopeGuard($name);
}
protected function getLink($method) {
$phabricator_project = 'PHID-APRJ-3f1fc779edeab89b2171';
return
'https://secure.phabricator.com/diffusion/symbol/'.$method.
'/?lang=php&projects='.$phabricator_project.
'&jump=true&context='.get_class($this);
}
/**
* Returns an integer seed to use when building unique identifiers (e.g.,
* non-colliding usernames). The seed is unstable and its value will change