title: How to use PHPUnit on remote server with PhpStorm 8
body: <p>I've got a php-fpm 5.3.10 installation running on Ubuntu 12.04 on a remote server, and I'm trying to use PHPUnit from within PhpStorm 8 (as of yesterday). I don't have a local php installation.</p>
  
  <p>I have installed PHPUnit on my server and can use it via the commandline.</p>
  
  <p>I have (seemingly) successfully linked my PhpStorm to my remote server and remote interpreter, and configured the right deployment settings.</p>
  
  <p>At first I had an issue where it would try to run my local paths remotely, but that issue has been sorted. However, I keep getting the error <code>Cannot find PHPUnit in include path (.:/usr/share/php:/usr/local/bin)</code>. This is almost certainly a serverside error (PhpStorm also knows these include paths, it could be confusing them for local paths) as the paths change when I change my include path in my php.ini.</p>
  
  <p>This is the same error it gives back if I don't install PHPUnit at all, so again it would seem this is a serverside issue.</p>
  
  <p>I have tried installing PHPUnit through PEAR (which is deprecated and soon unsupported by PHPUnit but still mentioned in a lot of PhpStorm tutorials), through Composer (on the remote server, not in PhpStorm) and even just manually.</p>
  
  <p>The server accepted these installation methods just fine (the PEAR method seems to install an older version of PHPUnit, 1.0.x instead of the apparently available 4.0.x) but they all give the same issue.</p>
  
  <p>If I manually place PHPUnit in my include path (I'm unsure what kind of files it wants there, though. a .phar? Source files?) it does seem to pick up something, but I get an XDebug error instead and it tells me it can't find the necessary PHPUnit files so I assume it is not the way to go (it shouldn't have to be).</p>
  
  <p>At this point I'm starting to run out of ideas and none of the Stackoverflow responses to similar issues or PhpStorm/PHPUnit documentations seem to be able to help me.</p>
  
  <p>Edit 1: Included picture of settings, as requested.</p>
  
  <p>(can't post images yet, not enough rep)
  <a href="http://i.imgur.com/wRNqh7l.png" rel="nofollow">settings</a></p>
  
  <p>Other than that it's probably worth noting I'm using a mounted folder for my deployment, which just refers to the filesystem of my server (it's in my local network)</p>
  
  <p>Edit 2: Changed deployment to SFTP as suggested and updated my mappings, as PhpStorm is able to successfully validate my remote environment everything seems to be in order there.</p>
  
  <p>After reinstalling PHPUnit via Composer and selecting the autoloader in my PHPUnit settings it was still  giving the error about the include path (it shouldn't do when the autoloader is used, should it?) so I changed the include path to point to <code>/usr/share/php/Composer/vendor/phpunit</code> (and the two directories above it, for good measure).</p>
  
  <p>It was still giving the error, however in the error it says it cannot find PHPUnit in the include path, while the installation is in a directory called phpunit (all lowercase). After changing the directory name to PHPUnit, it is no longer giving the include path error, but en XDebug error instead : <code>Warning: include(/usr/share/php/Composer/vendor/phpunit/phpunit/PHPUnit/TextUI/ResultPrinter.php) [&lt;a href='function.include'&gt;function.include&lt;/a&gt;]: failed to open stream: No such file or directory in /usr/share/php/Composer/vendor/composer/ClassLoader.php on line &lt;i&gt;382&lt;/i&gt;</code></p>
  
  <p>I'm unsure what this implies exactly, and I don't know whether the error is because I should not be changing the directory names (it seems as if that should not be necessary), because I haven't changed enough of them (other directories are likely still lowercase) or because these files should simply not be in the include path (composer should be managing my dependencies, shouldn't it?).</p>