PEAR
[ class tree: PEAR ] [ index: PEAR ] [ all elements ]

Class: PEAR_RunTest

Source Location: /PEAR-1.9.4/PEAR/RunTest.php

Class Overview


Simplified version of PHP's test suite


Author(s):

Version:

  • Release: 1.9.4

Copyright:

  • 1997-2009 The Authors

Variables

Methods


Inherited Variables

Inherited Methods


Class Details

[line 45]
Simplified version of PHP's test suite

Try it with:

$ php -r 'include "../PEAR/RunTest.php"; $t=new PEAR_RunTest; $o=$t->run("./pear_system.phpt");print_r($o);'



[ Top ]


Class Variables

$ini_overwrites = array(
        'output_handler=',
        'open_basedir=',
        'safe_mode=0',
        'disable_functions=',
        'output_buffering=Off',
        'display_errors=1',
        'log_errors=0',
        'html_errors=0',
        'track_errors=1',
        'report_memleaks=0',
        'report_zend_debug=0',
        'docref_root=',
        'docref_ext=.html',
        'error_prepend_string=',
        'error_append_string=',
        'auto_prepend_file=',
        'auto_append_file=',
        'magic_quotes_runtime=0',
        'xdebug.default_enable=0',
        'allow_url_fopen=1',
    )

[line 60]


Type:   mixed


[ Top ]

$tests_count =

[line 51]


Type:   mixed


[ Top ]

$xdebug_loaded =

[line 52]


Type:   mixed


[ Top ]



Method Detail

PEAR_RunTest (Constructor)   [line 87]

PEAR_RunTest PEAR_RunTest( [PEAR_Common|null $logger = null], [ $options = array()])

An object that supports the PEAR_Common->log() signature, or null

Parameters:

PEAR_Common|null   $logger     
   $options     

[ Top ]

generate_diff   [line 679]

void generate_diff( $wanted, $output, $rvalue, $wanted_re)


Parameters:

   $wanted     
   $output     
   $rvalue     
   $wanted_re     

[ Top ]

iniString2array   [line 189]

array iniString2array( string $ini_string)

Turns a PHP INI string into an array

Turns -d "include_path=/foo/bar" into this: array( 'include_path' => array( 'operator' => '-d', 'value' => '/foo/bar', ) ) Works both with quotes and without


Parameters:

string   $ini_string     an PHP INI string, -d "include_path=/foo/bar"

[ Top ]

run   [line 276]

string|object Returns run( string $file, [array|string $ini_settings = array()], [integer $test_number = 1])

Runs an individual test case.
  • Return: PASSED, WARNED, FAILED depending on how the test came out. PEAR Error when the tester it self fails

Parameters:

string   $file     The filename of the test
array|string   $ini_settings     INI settings to be applied to the test run
integer   $test_number     Number what the current running test is of the whole test suite being runned.

[ Top ]

runPHPUnit   [line 244]

void runPHPUnit( $file, [ $ini_settings = ''])


Parameters:

   $file     
   $ini_settings     

[ Top ]

save_text   [line 706]

void save_text( $filename, $text)


Parameters:

   $filename     
   $text     

[ Top ]

settings2array   [line 202]

void settings2array( $settings, $ini_settings)


Parameters:

   $settings     
   $ini_settings     

[ Top ]

settings2params   [line 215]

void settings2params( $ini_settings)


Parameters:

   $ini_settings     

[ Top ]

system_with_timeout   [line 115]

unknown system_with_timeout( string $commandline, [array $env = null], [string $stdin = null])

Taken from php-src/run-tests.php

Parameters:

string   $commandline     command name
array   $env     
string   $stdin     standard input to pass to the command

[ Top ]


Documentation generated on Wed, 06 Jul 2011 23:31:19 +0000 by phpDocumentor 1.4.3. PEAR Logo Copyright © PHP Group 2004.