1
0
Fork 0
mirror of https://we.phorge.it/source/arcanist.git synced 2024-10-24 17:48:50 +02:00
phorge-arcanist/src/lint/linter/__tests__/ArcanistApacheLicenseLinterTestCase.php
vrana ac92f9bdfc Remove getLink() from ArcanistLinterTestCase
Summary:
Installations extend this.

Another solution would be to extend `ArcanistLinterTestCase` from `ArcanistArcanistLinterTestCase` and return null in `getLink()` to avoid code duplication but I prefer clean class hierarchy.

Test Plan:
  $ arc unit

Reviewers: epriestley

Reviewed By: epriestley

CC: aran, Korvin

Differential Revision: https://secure.phabricator.com/D3878
2012-11-07 10:12:24 -08:00

25 lines
661 B
PHP

<?php
/**
* Test cases for @{class:ArcanistApacheLicenseLinter}.
*
* @group testcase
*/
final class ArcanistApacheLicenseLinterTestCase
extends ArcanistArcanistLinterTestCase {
public function testApacheLicenseLint() {
$linter = new ArcanistApacheLicenseLinter();
$working_copy = ArcanistWorkingCopyIdentity::newFromPath(__FILE__);
return $this->executeTestsInDirectory(
dirname(__FILE__).'/apachelicense/',
$linter,
$working_copy);
}
protected function compareTransform($expected, $actual) {
$expected = str_replace('YYYY', date('Y'), $expected);
return parent::compareTransform($expected, $actual);
}
}