Failed to open stream: No such file or directory, yes there is!
Change
set_include_path(dirname(__FILE__));
require '../test2.php';
to
set_include_path(dirname(__FILE__)."/../");
require 'test2.php';
It could be a symlinks issue? Try:
set_include_path(realpath(dirname(__FILE__))); // added realpath here
Also try:
require(dirname(__FILE__) . '/../test2.php');