HosipLan

Untitled

Jun 23rd, 2011
273
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
PHP 3.74 KB | None | 0 0
  1. $ cat /usr/bin/phpunit
  2. #!/usr/bin/php
  3. <?php
  4. /* PHPUnit
  5.  *
  6.  * Copyright (c) 2002-2011, Sebastian Bergmann <[email protected]>.
  7.  * All rights reserved.
  8.  *
  9.  * Redistribution and use in source and binary forms, with or without
  10.  * modification, are permitted provided that the following conditions
  11.  * are met:
  12.  *
  13.  *   * Redistributions of source code must retain the above copyright
  14.  *     notice, this list of conditions and the following disclaimer.
  15.  *                                                                                                                                                                                      
  16.  *   * Redistributions in binary form must reproduce the above copyright                                                                                                                
  17.  *     notice, this list of conditions and the following disclaimer in                                                                                                                  
  18.  *     the documentation and/or other materials provided with the                                                                                                                      
  19.  *     distribution.                                                                                                                                                                    
  20.  *                                                                                                                                                                                      
  21.  *   * Neither the name of Sebastian Bergmann nor the names of his                                                                                                                      
  22.  *     contributors may be used to endorse or promote products derived                                                                                                                  
  23.  *     from this software without specific prior written permission.                                                                                                                    
  24.  *                                                                                                                                                                                      
  25.  * THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS                                                                                                                  
  26.  * "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT                                                                                                                    
  27.  * LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS
  28.  * FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE
  29.  * COPYRIGHT OWNER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT,
  30.  * INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING,
  31.  * BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES;
  32.  * LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER
  33.  * CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT
  34.  * LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN
  35.  * ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE
  36.  * POSSIBILITY OF SUCH DAMAGE.
  37.  */
  38.  
  39. require_once 'PHP/CodeCoverage/Filter.php';
  40. PHP_CodeCoverage_Filter::getInstance()->addFileToBlacklist(__FILE__, 'PHPUNIT');
  41.  
  42. if (extension_loaded('xdebug')) {
  43.     xdebug_disable();
  44. }
  45.  
  46. if (strpos('/usr/bin/php', '@php_bin') === 0) {
  47.     set_include_path(dirname(__FILE__) . PATH_SEPARATOR . get_include_path());
  48. }
  49.  
  50. require_once 'PHPUnit/Autoload.php';
  51.  
  52. define('PHPUnit_MAIN_METHOD', 'PHPUnit_TextUI_Command::main');
  53.  
  54. PHPUnit_TextUI_Command::main();
Advertisement
Add Comment
Please, Sign In to add comment