fix includes
authorMichael Wallner <mike@php.net>
Tue, 22 Sep 2015 08:54:01 +0000 (10:54 +0200)
committerMichael Wallner <mike@php.net>
Tue, 22 Sep 2015 08:54:01 +0000 (10:54 +0200)
lib/autoload.php
tests/lib/pq/Gateway/CellTest.php
tests/lib/pq/Gateway/RowTest.php
tests/lib/pq/Gateway/RowsetTest.php
tests/lib/pq/Gateway/TableTest.php
tests/lib/pq/Query/AsyncExecutorTest.php

index cc5e906a728feaf3fa3e9fa836d2e375af63c2c2..e45fd2c81c3f3b711ca69c7cf8630be7a3cef99f 100644 (file)
@@ -1,7 +1,7 @@
 <?php
 
 spl_autoload_register(function($c) {
-       if (substr($c, 0, 10) === "pq\\Gateway" || substr($c, 0, 8) === "pq\\Query") {
+       if (substr($c, 0, 11) === "pq\\Gateway\\" || substr($c, 0, 9) === "pq\\Query\\" || substr($c, 0, 10) === "pq\\Mapper\\") {
                return include __DIR__ . "/" . strtr($c, "\\", "/") . ".php";
        }
 });
index 35ee6a072504e03d2d5a22b3dd6ffbd9345aac7c..f18163ad004d6c0c390646b871abd08420d9f150 100644 (file)
@@ -2,7 +2,7 @@
 
 namespace pq\Gateway;
 
-include __DIR__."/../../../setup.inc";
+require_once __DIR__."/../../../setup.inc";
 
 class CellTest extends \PHPUnit_Framework_TestCase {
 
index bee2dbe9bf36262ae055353a0fa2096f4890d8e2..4d539a054d9ba5ae116080134a1e867e042758c0 100644 (file)
@@ -2,7 +2,7 @@
 
 namespace pq\Gateway;
 
-include_once __DIR__."/../../../setup.inc";
+require_once __DIR__."/../../../setup.inc";
 
 class RowTest extends \PHPUnit_Framework_TestCase {
 
index 61f6b11af4668fa1b30c8e8566b47eba8de6cfa9..84981a61dc591047dac7010c144dbbacaf49f93b 100644 (file)
@@ -2,7 +2,7 @@
 
 namespace pq\Gateway;
 
-include_once __DIR__."/../../../setup.inc";
+require_once __DIR__."/../../../setup.inc";
 
 class RowsetTest extends \PHPUnit_Framework_TestCase {
 
index 03f71f783e36c000c767beffe484804c639b6ff1..c9bf19f5977f2ef5adb5488010a08e8e1db8c7e7 100644 (file)
@@ -2,7 +2,7 @@
 
 namespace pq\Gateway;
 
-include_once __DIR__."/../../../setup.inc";
+require_once __DIR__."/../../../setup.inc";
 
 class TableTest extends \PHPUnit_Framework_TestCase {
 
index ad68a914ce89d2b762e69759ba5c0d3a11fbe325..9a913e5771c388c58c48af04ad59f5c6e7024d7e 100644 (file)
@@ -2,7 +2,7 @@
 
 namespace pq\Query;
 
-include_once __DIR__."/../../../setup.inc";
+require_once __DIR__."/../../../setup.inc";
 
 use pq\Connection;
 use React\Promise\Deferred as Reacted;