diff options
author | Patrick Webster <noxwizard@phpbb.com> | 2012-04-12 20:10:20 -0500 |
---|---|---|
committer | Patrick Webster <noxwizard@phpbb.com> | 2012-05-08 04:31:32 -0500 |
commit | ceacb63abfdc8144ce88c0d9ce763ccc74836be5 (patch) | |
tree | 18d42b42c3d4487eae310c24c8893b30c518888f /tests | |
parent | 9bb2785da0c84bcc4a95f737b7da14c58c5d4380 (diff) | |
download | forums-ceacb63abfdc8144ce88c0d9ce763ccc74836be5.tar forums-ceacb63abfdc8144ce88c0d9ce763ccc74836be5.tar.gz forums-ceacb63abfdc8144ce88c0d9ce763ccc74836be5.tar.bz2 forums-ceacb63abfdc8144ce88c0d9ce763ccc74836be5.tar.xz forums-ceacb63abfdc8144ce88c0d9ce763ccc74836be5.zip |
[ticket/10678] Lowercase class name, adjust comment width
PHPBB3-10678
Diffstat (limited to 'tests')
-rw-r--r-- | tests/RUNNING_TESTS.txt | 26 | ||||
-rw-r--r-- | tests/test_framework/phpbb_database_connection_helper.php | 2 | ||||
-rw-r--r-- | tests/test_framework/phpbb_database_test_connection_manager.php | 4 |
3 files changed, 18 insertions, 14 deletions
diff --git a/tests/RUNNING_TESTS.txt b/tests/RUNNING_TESTS.txt index 705fb28d07..487320f736 100644 --- a/tests/RUNNING_TESTS.txt +++ b/tests/RUNNING_TESTS.txt @@ -36,8 +36,9 @@ found on the wiki (see below). $dbuser = 'user'; $dbpasswd = 'password'; -Alternatively you can specify parameters in the environment, so e.g. the following -will run phpunit with the same parameters as in the shown test_config.php file: +Alternatively you can specify parameters in the environment, so e.g. the +following will run phpunit with the same parameters as in the shown +test_config.php file: $ PHPBB_TEST_DBMS='mysqli' PHPBB_TEST_DBHOST='localhost' \ PHPBB_TEST_DBNAME='database' PHPBB_TEST_DBUSER='user' \ @@ -46,9 +47,10 @@ will run phpunit with the same parameters as in the shown test_config.php file: Special Database Cases ---------------------- In order to run tests on some of the databases that we support, it will be -necessary to provide a custom DSN string in test_config.php. This is only needed for -MSSQL 2000+ (PHP module), MSSQL via ODBC, and Firebird when PDO_Firebird does not work -on your system (https://bugs.php.net/bug.php?id=61183). The variable must be named $custom_dsn. +necessary to provide a custom DSN string in test_config.php. This is only +needed for MSSQL 2000+ (PHP module), MSSQL via ODBC, and Firebird when +PDO_Firebird does not work on your system +(https://bugs.php.net/bug.php?id=61183). The variable must be named $custom_dsn. Examples: Firebird using http://www.firebirdsql.org/en/odbc-driver/ @@ -57,15 +59,17 @@ $custom_dsn = "Driver={Firebird/InterBase(r) driver};dbname=$dbhost:$dbname"; MSSQL $custom_dsn = "Driver={SQL Server Native Client 10.0};Server=$dbhost;Database=$dbname"; -The other fields in test_config.php should be filled out as you would normally to connect -to that database in phpBB. +The other fields in test_config.php should be filled out as you would normally +to connect to that database in phpBB. -Additionally, you will need to be running the DbUnit fork from https://github.com/phpbb/dbunit/tree/phpbb. +Additionally, you will need to be running the DbUnit fork from +https://github.com/phpbb/dbunit/tree/phpbb. Running ======= -Once the prerequisites are installed, run the tests from the project root directory (above phpBB): +Once the prerequisites are installed, run the tests from the project root +directory (above phpBB): $ phpunit @@ -73,8 +77,8 @@ Slow tests -------------- Certain tests, such as the UTF-8 normalizer or the DNS tests tend to be slow. Thus these tests are in the `slow` group, which is excluded by default. You can -enable slow tests by copying the phpunit.xml.all file to phpunit.xml. If you only -want the slow tests, run: +enable slow tests by copying the phpunit.xml.all file to phpunit.xml. If you +only want the slow tests, run: $ phpunit --group slow diff --git a/tests/test_framework/phpbb_database_connection_helper.php b/tests/test_framework/phpbb_database_connection_helper.php index fbb85784f8..5eba2e7a2e 100644 --- a/tests/test_framework/phpbb_database_connection_helper.php +++ b/tests/test_framework/phpbb_database_connection_helper.php @@ -14,7 +14,7 @@ * * This is used in the custom PHPUnit ODBC driver */ -class phpbb_database_connection_ODBC_PDO_wrapper extends PDO +class phpbb_database_connection_odbc_pdo_wrapper extends PDO { // Name of the driver being used (i.e. mssql, firebird) public $driver = ''; diff --git a/tests/test_framework/phpbb_database_test_connection_manager.php b/tests/test_framework/phpbb_database_test_connection_manager.php index 3c4a112d0d..8e214121f3 100644 --- a/tests/test_framework/phpbb_database_test_connection_manager.php +++ b/tests/test_framework/phpbb_database_test_connection_manager.php @@ -97,13 +97,13 @@ class phpbb_database_test_connection_manager { case 'mssql': case 'mssql_odbc': - $this->pdo = new phpbb_database_connection_ODBC_PDO_wrapper('mssql', 0, $dsn, $this->config['dbuser'], $this->config['dbpasswd']); + $this->pdo = new phpbb_database_connection_odbc_pdo_wrapper('mssql', 0, $dsn, $this->config['dbuser'], $this->config['dbpasswd']); break; case 'firebird': if (!empty($this->config['custom_dsn'])) { - $this->pdo = new phpbb_database_connection_ODBC_PDO_wrapper('firebird', 0, $dsn, $this->config['dbuser'], $this->config['dbpasswd']); + $this->pdo = new phpbb_database_connection_odbc_pdo_wrapper('firebird', 0, $dsn, $this->config['dbuser'], $this->config['dbpasswd']); break; } // Fall through if they're using the firebird PDO driver and not the generic ODBC driver |