Yaffs site version 1.1
[yaffs-website] / vendor / phpunit / phpunit / tests / Framework / Constraint / ExceptionMessageTest.php
1 <?php
2 /*
3  * This file is part of PHPUnit.
4  *
5  * (c) Sebastian Bergmann <sebastian@phpunit.de>
6  *
7  * For the full copyright and license information, please view the LICENSE
8  * file that was distributed with this source code.
9  */
10
11 /**
12  * @since      Class available since Release 4.0.20
13  * @covers     PHPUnit_Framework_Constraint_ExceptionMessage
14  */
15 class ExceptionMessageTest extends PHPUnit_Framework_TestCase
16 {
17     /**
18      * @expectedException \Exception
19      * @expectedExceptionMessage A literal exception message
20      */
21     public function testLiteralMessage()
22     {
23         throw new Exception('A literal exception message');
24     }
25
26     /**
27      * @expectedException \Exception
28      * @expectedExceptionMessage A partial
29      */
30     public function testPatialMessageBegin()
31     {
32         throw new Exception('A partial exception message');
33     }
34
35     /**
36      * @expectedException \Exception
37      * @expectedExceptionMessage partial exception
38      */
39     public function testPatialMessageMiddle()
40     {
41         throw new Exception('A partial exception message');
42     }
43
44     /**
45      * @expectedException \Exception
46      * @expectedExceptionMessage exception message
47      */
48     public function testPatialMessageEnd()
49     {
50         throw new Exception('A partial exception message');
51     }
52 }