qa:runtests:howtorun

Differences

This shows you the differences between two versions of the page.

Link to this comparison view

Both sides previous revisionPrevious revision
Next revision
Previous revision
qa:runtests:howtorun [2012/05/22 07:55] – [Configure options] zoeqa:runtests:howtorun [2017/09/22 13:28] (current) – external edit 127.0.0.1
Line 26: Line 26:
  
 ===== Run the code ===== ===== Run the code =====
-At the moment the code will run a single test, eg:+Run a single test, eg:
 <code> <code>
  runtests my_test.phpt  runtests my_test.phpt
 </code> </code>
  
-All the tests under a given directory, eg:+Run all the tests under a given directory, eg:
 <code> <code>
   runtests ext/standard/tests/   runtests ext/standard/tests/
Line 37: Line 37:
  
 The output format is different to run-tests.php. If a single test is run a short summary is printed to stdout. If one or more directories of tests are run the output is printed after each group (directory) of tests has been run. Again, a summary is printed to stdout but details are written to a file. The output format is different to run-tests.php. If a single test is run a short summary is printed to stdout. If one or more directories of tests are run the output is printed after each group (directory) of tests has been run. Again, a summary is printed to stdout but details are written to a file.
 +
 +Run all the tests under path_to_php/ext in parallel on 4 processors
  
 <code> <code>
-runtests --help+  runtests path_to_php/ext -z 4
 </code> </code>
  
-will give you all of the possible command line options.+Generate XML formatted output to a file:
  
 +<code>
 +  runtests -o xml -s /tmp/somefile path_to_php/tests
 +</code>
  
 +Get more verbose results to the screen: 
 +<code>
 +  runtests -vvv path_to_php/tests
 +</code>
  
 +Note: there are three levels of verbosity, -v, -vv and -vvv. But default all you will see is a '.' for each test.
  
  
 +<code>
 +runtests --help
 +</code>
 +
 +will give you all of the possible command line options.
  
-======phpruntests on Windows====== 
-At frist, make sure to use the correct php-version as described here: [[http://windows.php.net/download/]] 
  
-A important difference to unix is that you have to execute the script from the directory were your test-cases are stored. 
  
-We've created a short bat-file which you can use: 
  
-<code> 
-cd c:\QA 
-set TEST_PHP_CGI_EXECUTABLE=c:\PHP\php-5.3.0-nts-Win32-VC6-x86\php-cgi.exe 
-c:\PHP\php-5.3.0-nts-Win32-VC6-x86\php.exe 
-c:\workspace\phpruntests\src\run-tests.php -p 
-c:\PHP\php-5.3.0-nts-Win32-VC6-x86\php.exe %* 
-</code> 
  
 +======run-tests.php on Windows======
  
 +Running the code should be the same, you will need a runtests.bat file rather than a shell script.
  
qa/runtests/howtorun.1337673340.txt.gz · Last modified: 2017/09/22 13:28 (external edit)