]> CyberLeo.Net >> Repos - Github/sugarcrm.git/blob - tests/PHPUnit/Tests/TextUI/dataset-log-xml.phpt
Added unit tests.
[Github/sugarcrm.git] / tests / PHPUnit / Tests / TextUI / dataset-log-xml.phpt
1 --TEST--
2 phpunit --log-xml php://stdout DataSetTest ../_files/DataSetTest.php
3 --FILE--
4 <?php
5 $_SERVER['argv'][1] = '--log-xml';
6 $_SERVER['argv'][2] = 'php://stdout';
7 $_SERVER['argv'][3] = 'DataSetTest';
8 $_SERVER['argv'][4] = dirname(dirname(__FILE__)) . '/_files/DataSetTest.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 ..F.<?xml version="1.0" encoding="UTF-8"?>
17 <testsuites>
18   <testsuite name="DataSetTest" file="%s/DataSetTest.php" tests="4" assertions="4" failures="1" errors="0" time="%f">
19     <testsuite name="DataSetTest::testAdd" tests="4" assertions="4" failures="1" errors="0" time="%f">
20       <testcase name="testAdd with data set #0" assertions="1" time="%f"/>
21       <testcase name="testAdd with data set #1" assertions="1" time="%f"/>
22       <testcase name="testAdd with data set #2" assertions="1" time="%f">
23         <failure type="PHPUnit_Framework_ExpectationFailedException">testAdd(DataSetTest) with data set #2 (1, 1, 3)
24 Failed asserting that &lt;integer:2&gt; matches expected value &lt;integer:3&gt;.
25
26 %s:%i
27 %s:%i
28 </failure>
29       </testcase>
30       <testcase name="testAdd with data set #3" assertions="1" time="%f"/>
31     </testsuite>
32   </testsuite>
33 </testsuites>
34
35
36 Time: %i seconds
37
38 There was 1 failure:
39
40 1) testAdd(DataSetTest) with data set #2 (1, 1, 3)
41 Failed asserting that <integer:2> matches expected value <integer:3>.
42 %s:%i
43 %s:%i
44
45 FAILURES!
46 Tests: 4, Assertions: 4, Failures: 1.
47