Skip to content

Commit b30cedf

Browse files
tomphpGianluca Arbezzano
authored andcommitted
Remove trait tests for PHP 5.3
1 parent 8523367 commit b30cedf

File tree

2 files changed

+9
-1
lines changed

2 files changed

+9
-1
lines changed

PHPCtags.class.php

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -421,7 +421,7 @@ private function process($file)
421421
$this->struct($this->mParser->parse(file_get_contents($this->mFile)), TRUE)
422422
);
423423
} catch(Exception $e) {
424-
echo "PHPParser: {$e->getMessage()} - {$filename}".PHP_EOL;
424+
echo "PHPParser: {$e->getMessage()} - {$file}".PHP_EOL;
425425
}
426426
}
427427
}

tests/Acceptance/TraitsTest.php

Lines changed: 8 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -9,6 +9,10 @@ final class TraitsTest extends AcceptanceTestCase
99
*/
1010
public function itCreatesTagForTopLevelTrait()
1111
{
12+
if (version_compare('5.4.0', PHP_VERSION, 'gte')) {
13+
$this->markTestSkipped('Traits were not introduced until 5.4');
14+
}
15+
1216
$this->givenSourceFile('TopLevelTraitExample.php', <<<'EOS'
1317
<?php
1418
@@ -98,6 +102,10 @@ private function privateMethod()
98102
*/
99103
public function itAddsNamespacesToTraitTags()
100104
{
105+
if (version_compare('5.4.0', PHP_VERSION, 'gte')) {
106+
$this->markTestSkipped('Traits were not introduced until 5.4');
107+
}
108+
101109
$this->givenSourceFile('MultiLevelNamespace.php', <<<'EOS'
102110
<?php
103111

0 commit comments

Comments
 (0)