I'm just getting back into PHP and trying to do things the correct way from the beginning. So I've installed PHPLint 2.1_20151116 and I cannot seem to get it to work with composer's autoload. Is it possible?
For example I am trying to add a test case to Laravel/Envoy, but I cannot get past an error "undeclared parent class TestCase".
The folder structure is:
envoy
├── tests
│ ├── RemoteProcessorTest.php
│ ├── SSHConfigFileTest.php
│ └── TestCase.php
The contents of RemoteProcessorTest.php is:
<?php
namespace Laravel\Envoy;
class RemoteProcessTest extends TestCase
{
}
If I run ./vendor/bin/phpunit
then I get the error: No tests found in class "Laravel\Envoy\RemoteProcessTest".
. Which isn't a syntax error so it looks like everything is valid. But phplint still complains.
$ cd envoy
$ phpl --php-version 5 --print-path relative --print-column-number --tab-size 4 --no-overall tests/RemoteProcessorTest.php
BEGIN parsing of tests/RemoteProcessorTest.php
1: <?php
2: namespace Laravel\Envoy;
3:
4: class RemoteProcessTest extends TestCase
5: {
{
\_ HERE
==== 5:1: ERROR: undeclared parent class TestCase
6: }
END parsing of tests/RemoteProcessorTest.php
Is there a work around for this?