WordPress.org

Make WordPress Core

Changeset 504 in tests


Ignore:
Timestamp:
02/01/12 16:07:55 (2 years ago)
Author:
convissor
Message:

Turn PHPUnit --verbose into an option (-p), false by default.

Files:
2 edited

Legend:

Unmodified
Added
Removed
  • wp-test.php

    r502 r504  
    1818 *   - -m  Test multisite 
    1919 *   - -n  Do not clean up the database at the end of the run 
     20 *   - -p  PHPUnit --verbose 
    2021 *   - -q  Save queries 
    2122 *   - -r  Uses the given path as the WP_DIR to be tested.  Overrides -v. 
     
    2627 
    2728// parse options 
    28 $options = 'v:t:r:msflndqh'; 
     29$options = 'r:t:v:dfhlmnpqs'; 
    2930if (is_callable('getopt')) { 
    3031    $opts = getopt($options); 
     
    5253  -m  Test multisite 
    5354  -n  Do not clean up the database at the end of the run 
     55  -p  PHPUnit --verbose 
    5456  -q  Save queries 
    5557  -r  Uses the given path as the WP_DIR to be tested.  Overrides -v. 
     
    7476define('WP_DEBUG', array_key_exists('d', $opts) ); 
    7577define('SAVEQUERIES', array_key_exists('q', $opts) ); 
     78define('WP_PHPUNIT_VERBOSE', array_key_exists('p', $opts)); 
    7679 
    7780if (!empty($opts['r'])) 
  • wp-testlib/base.php

    r498 r504  
    559559    $result = new PHPUnit_Framework_TestResult; 
    560560    require_once('PHPUnit/TextUI/ResultPrinter.php'); 
    561     $printer = new PHPUnit_TextUI_ResultPrinter(NULL, true, !stristr(PHP_OS, 'WIN') ); 
     561    $printer = new PHPUnit_TextUI_ResultPrinter(NULL, WP_PHPUNIT_VERBOSE, !stristr(PHP_OS, 'WIN') ); 
    562562    $result->addListener($printer); 
    563563    return array($suite->run($result), $printer); 
Note: See TracChangeset for help on using the changeset viewer.