diff --git a/.travis.yml b/.travis.yml index a07c70e..c1f1c5a 100644 --- a/.travis.yml +++ b/.travis.yml @@ -13,7 +13,7 @@ before_script: - sh -c "psql -c 'create database test;' -U postgres" - sh -c "mysql -e 'create database IF NOT EXISTS test;'" -script: cd tests && phpunit +script: cd tests && phpunit --coverage-text matrix: allow_failures: diff --git a/classes/db_pdo.php b/classes/db_pdo.php index 652cbaa..167bd90 100644 --- a/classes/db_pdo.php +++ b/classes/db_pdo.php @@ -134,16 +134,10 @@ abstract class DB_PDO extends PDO { /** * Returns number of rows affected by an INSERT, UPDATE, DELETE type query * - * @param PDOStatement $statement * @return int */ - public function affected_rows($statement='') + public function affected_rows() { - if ( ! empty($statement)) - { - $this->statement = $statement; - } - // Return number of rows affected return $this->statement->rowCount(); } diff --git a/classes/idb_sql.php b/classes/idb_sql.php index 144ba11..31492dd 100644 --- a/classes/idb_sql.php +++ b/classes/idb_sql.php @@ -115,7 +115,7 @@ interface iDB_SQL { * Get information about the columns in the * specified table * - * @param string + * @param string $table * @return string */ public function column_list($table); diff --git a/classes/iquery_builder.php b/classes/iquery_builder.php index 22e9ded..22a1172 100644 --- a/classes/iquery_builder.php +++ b/classes/iquery_builder.php @@ -190,7 +190,7 @@ interface iQuery_Builder { * * @param mixed $key * @param mixed $val - @ @param bool $escape + * @param bool $escape * @return $this */ public function where($key, $val=array(), $escape = NULL); diff --git a/classes/query_parser.php b/classes/query_parser.php index 3666c5d..73ad4cb 100644 --- a/classes/query_parser.php +++ b/classes/query_parser.php @@ -47,7 +47,7 @@ class Query_Parser { /** * Constructor/entry point into parser * - * @param string + * @param string $sql */ public function __construct($sql = '') { @@ -69,7 +69,7 @@ class Query_Parser { /** * Public parser method for seting the parse string * - * @param string + * @param string $sql */ public function parse_join($sql) { @@ -82,7 +82,7 @@ class Query_Parser { /** * Returns a more useful match array * - * @param array + * @param array $array * @return array */ private function filter_array($array) diff --git a/drivers/firebird/firebird_result.php b/drivers/firebird/firebird_result.php index cc7861c..9909835 100644 --- a/drivers/firebird/firebird_result.php +++ b/drivers/firebird/firebird_result.php @@ -77,7 +77,7 @@ class Firebird_Result extends PDOStatement { * Invalidate method for data consistency * * @param mixed $column - * @param mixed &$param + * @param mixed $param * @param int $type * @param mixed $maxlen * @param array $driverdata @@ -94,7 +94,7 @@ class Firebird_Result extends PDOStatement { * Invalidate method for data consistency * * @param mixed $parameter - * @param mixed &$variable + * @param mixed $variable * @param int $data_type * @param mixed $maxlen * @param array $driverdata @@ -111,7 +111,7 @@ class Firebird_Result extends PDOStatement { * Invalidate method for data consistency * * @param mixed $parameter - * @param mixed &$variable + * @param mixed $variable * @param int $data_type * @return NULL */ @@ -147,8 +147,8 @@ class Firebird_Result extends PDOStatement { * Emulate PDO fetch public function * * @param int $fetch_style - * @param mixed $statement - * @param mixed $offset + * @param mixed $cursor_orientation + * @param mixed $cursor_offset * @return mixed */ public function fetch($fetch_style=PDO::FETCH_ASSOC, $cursor_orientation = PDO::FETCH_ORI_NEXT, $cursor_offset=NULL) diff --git a/drivers/firebird/firebird_util.php b/drivers/firebird/firebird_util.php index 1f30973..b27d57c 100644 --- a/drivers/firebird/firebird_util.php +++ b/drivers/firebird/firebird_util.php @@ -24,7 +24,7 @@ class Firebird_Util extends DB_Util { /** * Save a reference to the current connection object * - * @param object &$conn + * @param object $conn * @return void */ public function __construct(&$conn) diff --git a/drivers/mysql/mysql_util.php b/drivers/mysql/mysql_util.php index f19a06e..1f301dd 100644 --- a/drivers/mysql/mysql_util.php +++ b/drivers/mysql/mysql_util.php @@ -24,7 +24,7 @@ class MySQL_Util extends DB_Util { /** * Save a reference to the current connection object * - * @param object &$conn + * @param object $conn * @return void */ public function __construct(&$conn) diff --git a/drivers/odbc/odbc_util.php b/drivers/odbc/odbc_util.php index 0e4a029..9660a44 100644 --- a/drivers/odbc/odbc_util.php +++ b/drivers/odbc/odbc_util.php @@ -24,7 +24,7 @@ class ODBC_Util extends DB_Util { /** * Save a reference to the current connection object * - * @param object &$conn + * @param object $conn * @return void */ public function __construct(&$conn) diff --git a/drivers/pgsql/pgsql_util.php b/drivers/pgsql/pgsql_util.php index 4c28558..5d37c21 100644 --- a/drivers/pgsql/pgsql_util.php +++ b/drivers/pgsql/pgsql_util.php @@ -24,7 +24,7 @@ class PgSQL_Util extends DB_Util { /** * Save a reference to the current connection object * - * @param object &$conn + * @param object $conn * @return void */ public function __construct(&$conn) diff --git a/drivers/sqlite/sqlite_util.php b/drivers/sqlite/sqlite_util.php index f471cfe..869e828 100644 --- a/drivers/sqlite/sqlite_util.php +++ b/drivers/sqlite/sqlite_util.php @@ -24,7 +24,7 @@ class SQLite_Util extends DB_Util { /** * Save a reference to the current connection object * - * @param object &$conn + * @param object $conn * @return void */ public function __construct(&$conn) diff --git a/tests/bootstrap.php b/tests/bootstrap.php index 060f23c..32a766c 100644 --- a/tests/bootstrap.php +++ b/tests/bootstrap.php @@ -6,7 +6,7 @@ * * @package Query * @author Timothy J. Warren - * @copyright Copyright (c) 2012 - 2013 + * @copyright Copyright (c) 2012 - 2014 * @link https://github.com/aviat4ion/Query * @license http://philsturgeon.co.uk/code/dbad-license */ diff --git a/tests/core/core.php b/tests/core/core.php index 499e66f..1d201dd 100644 --- a/tests/core/core.php +++ b/tests/core/core.php @@ -5,7 +5,7 @@ * Free Database manager for Open Source Databases * * @author Timothy J. Warren - * @copyright Copyright (c) 2012 - 2013 + * @copyright Copyright (c) 2012 - 2014 * @link https://github.com/aviat4ion/OpenSQLManager * @license http://philsturgeon.co.uk/code/dbad-license */ diff --git a/tests/core/db_qb_test.php b/tests/core/db_qb_test.php index 8bda322..32a1f41 100644 --- a/tests/core/db_qb_test.php +++ b/tests/core/db_qb_test.php @@ -6,7 +6,7 @@ * * @package Query * @author Timothy J. Warren - * @copyright Copyright (c) 2012 - 2013 + * @copyright Copyright (c) 2012 - 2014 * @link https://github.com/aviat4ion/Query * @license http://philsturgeon.co.uk/code/dbad-license */ diff --git a/tests/core/db_qp_test.php b/tests/core/db_qp_test.php index aeaaafd..928f617 100644 --- a/tests/core/db_qp_test.php +++ b/tests/core/db_qp_test.php @@ -6,7 +6,7 @@ * * @package Query * @author Timothy J. Warren - * @copyright Copyright (c) 2012 - 2013 + * @copyright Copyright (c) 2012 - 2014 * @link https://github.com/aviat4ion/Query * @license http://philsturgeon.co.uk/code/dbad-license */ diff --git a/tests/core/db_test.php b/tests/core/db_test.php index 7752c84..455aba9 100644 --- a/tests/core/db_test.php +++ b/tests/core/db_test.php @@ -6,7 +6,7 @@ * * @package Query * @author Timothy J. Warren - * @copyright Copyright (c) 2012 - 2013 + * @copyright Copyright (c) 2012 - 2014 * @link https://github.com/aviat4ion/Query * @license http://philsturgeon.co.uk/code/dbad-license */ diff --git a/tests/databases/firebird/FirebirdQBTest.php b/tests/databases/firebird/FirebirdQBTest.php index 0ad8aa4..c7b79b0 100644 --- a/tests/databases/firebird/FirebirdQBTest.php +++ b/tests/databases/firebird/FirebirdQBTest.php @@ -6,7 +6,7 @@ * * @package Query * @author Timothy J. Warren - * @copyright Copyright (c) 2012 - 2013 + * @copyright Copyright (c) 2012 - 2014 * @link https://github.com/aviat4ion/Query * @license http://philsturgeon.co.uk/code/dbad-license */ diff --git a/tests/databases/firebird/FirebirdTest.php b/tests/databases/firebird/FirebirdTest.php index 2527069..b568c50 100644 --- a/tests/databases/firebird/FirebirdTest.php +++ b/tests/databases/firebird/FirebirdTest.php @@ -6,7 +6,7 @@ * * @package Query * @author Timothy J. Warren - * @copyright Copyright (c) 2012 - 2013 + * @copyright Copyright (c) 2012 - 2014 * @link https://github.com/aviat4ion/Query * @license http://philsturgeon.co.uk/code/dbad-license */ diff --git a/tests/databases/mysql/MySQLQBTest.php b/tests/databases/mysql/MySQLQBTest.php index 6bed5c7..9810cd3 100644 --- a/tests/databases/mysql/MySQLQBTest.php +++ b/tests/databases/mysql/MySQLQBTest.php @@ -6,7 +6,7 @@ * * @package Query * @author Timothy J. Warren - * @copyright Copyright (c) 2012 - 2013 + * @copyright Copyright (c) 2012 - 2014 * @link https://github.com/aviat4ion/Query * @license http://philsturgeon.co.uk/code/dbad-license */ diff --git a/tests/databases/mysql/MySQLTest.php b/tests/databases/mysql/MySQLTest.php index 002c61a..7c0b957 100644 --- a/tests/databases/mysql/MySQLTest.php +++ b/tests/databases/mysql/MySQLTest.php @@ -6,7 +6,7 @@ * * @package Query * @author Timothy J. Warren - * @copyright Copyright (c) 2012 - 2013 + * @copyright Copyright (c) 2012 - 2014 * @link https://github.com/aviat4ion/Query * @license http://philsturgeon.co.uk/code/dbad-license */ diff --git a/tests/databases/pgsql/PgSQLQBTest.php b/tests/databases/pgsql/PgSQLQBTest.php index f301b60..520b391 100644 --- a/tests/databases/pgsql/PgSQLQBTest.php +++ b/tests/databases/pgsql/PgSQLQBTest.php @@ -5,7 +5,7 @@ * Free Database manager for Open Source Databases * * @author Timothy J. Warren - * @copyright Copyright (c) 2012 - 2013 + * @copyright Copyright (c) 2012 - 2014 * @link https://github.com/aviat4ion/OpenSQLManager * @license http://philsturgeon.co.uk/code/dbad-license */ diff --git a/tests/databases/pgsql/PgSQLTest.php b/tests/databases/pgsql/PgSQLTest.php index 8be2ffe..f0bd58b 100644 --- a/tests/databases/pgsql/PgSQLTest.php +++ b/tests/databases/pgsql/PgSQLTest.php @@ -5,7 +5,7 @@ * Free Database manager for Open Source Databases * * @author Timothy J. Warren - * @copyright Copyright (c) 2012 - 2013 + * @copyright Copyright (c) 2012 - 2014 * @link https://github.com/aviat4ion/OpenSQLManager * @license http://philsturgeon.co.uk/code/dbad-license */ diff --git a/tests/databases/sqlite/SqliteQBTest.php b/tests/databases/sqlite/SqliteQBTest.php index 1a148cb..a82f232 100644 --- a/tests/databases/sqlite/SqliteQBTest.php +++ b/tests/databases/sqlite/SqliteQBTest.php @@ -5,7 +5,7 @@ * Free Database manager for Open Source Databases * * @author Timothy J. Warren - * @copyright Copyright (c) 2012 - 2013 + * @copyright Copyright (c) 2012 - 2014 * @link https://github.com/aviat4ion/OpenSQLManager * @license http://philsturgeon.co.uk/code/dbad-license */ diff --git a/tests/databases/sqlite/SqliteTest.php b/tests/databases/sqlite/SqliteTest.php index 1cd476b..63275e0 100644 --- a/tests/databases/sqlite/SqliteTest.php +++ b/tests/databases/sqlite/SqliteTest.php @@ -5,7 +5,7 @@ * Free Database manager for Open Source Databases * * @author Timothy J. Warren - * @copyright Copyright (c) 2012 - 2013 + * @copyright Copyright (c) 2012 - 2014 * @link https://github.com/aviat4ion/OpenSQLManager * @license http://philsturgeon.co.uk/code/dbad-license */ diff --git a/tests/index.php b/tests/index.php deleted file mode 100644 index 121da6c..0000000 --- a/tests/index.php +++ /dev/null @@ -1,28 +0,0 @@ -