]> CyberLeo.Net >> Repos - Github/sugarcrm.git/blob - tests/PHPUnit/Tests/TextUI/coverage-clover.phpt
Added unit tests.
[Github/sugarcrm.git] / tests / PHPUnit / Tests / TextUI / coverage-clover.phpt
1 --TEST--
2 phpunit --coverage-clover php://stdout BankAccountTest ../../Samples/BankAccount/BankAccountTest.php
3 --FILE--
4 <?php
5 $_SERVER['argv'][1] = '--coverage-clover';
6 $_SERVER['argv'][2] = 'php://stdout';
7 $_SERVER['argv'][3] = 'BankAccountTest';
8 $_SERVER['argv'][4] = '../Samples/BankAccount/BankAccountTest.php';
9
10 require_once dirname(dirname(dirname(__FILE__))) . '/TextUI/Command.php';
11 PHPUnit_TextUI_Command::main();
12 ?>
13 --EXPECTF--
14 PHPUnit %s by Sebastian Bergmann.
15
16 ...
17
18 Time: %i seconds
19
20 OK (3 tests, 3 assertions)
21
22 Writing code coverage data to XML file, this may take a moment.<?xml version="1.0" encoding="UTF-8"?>
23 <coverage generated="%d" phpunit="%s">
24   <project name="BankAccountTest" timestamp="%d">
25     <file name="%s/BankAccount.php">
26       <class name="BankAccountException" namespace="global" fullPackage="PHPUnit" category="Testing" package="PHPUnit">
27         <metrics methods="0" coveredmethods="0" statements="0" coveredstatements="0" elements="0" coveredelements="0"/>
28       </class>
29       <class name="BankAccount" namespace="global" fullPackage="PHPUnit" category="Testing" package="PHPUnit">
30         <metrics methods="4" coveredmethods="3" statements="9" coveredstatements="3" elements="13" coveredelements="6"/>
31       </class>
32       <line num="75" type="method" count="1"/>
33       <line num="77" type="stmt" count="1"/>
34       <line num="86" type="method" count="0"/>
35       <line num="88" type="stmt" count="0"/>
36       <line num="89" type="stmt" count="0"/>
37       <line num="90" type="stmt" count="0"/>
38       <line num="91" type="stmt" count="0"/>
39       <line num="93" type="stmt" count="0"/>
40       <line num="101" type="method" count="1"/>
41       <line num="103" type="stmt" count="1"/>
42       <line num="105" type="stmt" count="0"/>
43       <line num="114" type="method" count="1"/>
44       <line num="116" type="stmt" count="1"/>
45       <line num="118" type="stmt" count="0"/>
46       <metrics loc="121" ncloc="37" classes="2" methods="4" coveredmethods="3" statements="10" coveredstatements="3" elements="14" coveredelements="6"/>
47     </file>
48     <metrics files="1" loc="121" ncloc="37" classes="2" methods="4" coveredmethods="3" statements="10" coveredstatements="3" elements="14" coveredelements="6"/>
49   </project>
50 </coverage>