class CodeExtensionTest extends TestCase
{ public function testFormatFile() { $expected =
sprintf('<a href="proto://foobar%s#&line=25" title="Click to open this file" class="file_link">%s at line 25</a>',
substr(__FILE__, 5
), __FILE__
);
$this->
assertEquals($expected,
$this->
getExtension()->
formatFile(__FILE__, 25
));
} public function testFileRelative() { $this->
assertEquals('file.txt',
$this->
getExtension()->
getFileRelative(\DIRECTORY_SEPARATOR.'project'.\DIRECTORY_SEPARATOR.'file.txt'
));
} /**
* @dataProvider getClassNameProvider
*/
public function testGettingClassAbbreviation($class,
$abbr) { $this->
assertEquals($this->
getExtension()->
abbrClass($class),
$abbr);
} /**
* @dataProvider getMethodNameProvider
*/