~ballot/wordpress/openstack-objectstorage-breaking-insight

« back to all changes in this revision

Viewing changes to vendor/phpunit/phpunit/src/Framework/IncompleteTestCase.php

  • Committer: Jacek Nykis
  • Date: 2015-02-11 15:35:31 UTC
  • Revision ID: jacek.nykis@canonical.com-20150211153531-hmy6zi0ov2qfkl0b
Initial commit

Show diffs side-by-side

added added

removed removed

Lines of Context:
 
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
 * An incomplete test case
 
13
 *
 
14
 * @package    PHPUnit
 
15
 * @subpackage Framework
 
16
 * @author     Davey Shafik <me@daveyshafik.com>
 
17
 * @copyright  Sebastian Bergmann <sebastian@phpunit.de>
 
18
 * @license    http://www.opensource.org/licenses/BSD-3-Clause  The BSD 3-Clause License
 
19
 * @link       http://www.phpunit.de/
 
20
 * @since      Class available since Release 4.3.0
 
21
 */
 
22
class PHPUnit_Framework_IncompleteTestCase extends PHPUnit_Framework_TestCase
 
23
{
 
24
    /**
 
25
     * @var string
 
26
     */
 
27
    protected $message = '';
 
28
 
 
29
    /**
 
30
     * @var boolean
 
31
     */
 
32
    protected $backupGlobals = false;
 
33
 
 
34
    /**
 
35
     * @var boolean
 
36
     */
 
37
    protected $backupStaticAttributes = false;
 
38
 
 
39
    /**
 
40
     * @var boolean
 
41
     */
 
42
    protected $runTestInSeparateProcess = false;
 
43
 
 
44
    /**
 
45
     * @var boolean
 
46
     */
 
47
    protected $useErrorHandler = false;
 
48
 
 
49
    /**
 
50
     * @var boolean
 
51
     */
 
52
    protected $useOutputBuffering = false;
 
53
 
 
54
    /**
 
55
     * @param string $message
 
56
     */
 
57
    public function __construct($className, $methodName, $message = '')
 
58
    {
 
59
        $this->message = $message;
 
60
        parent::__construct($className . '::' . $methodName);
 
61
    }
 
62
 
 
63
    /**
 
64
     * @throws PHPUnit_Framework_Exception
 
65
     */
 
66
    protected function runTest()
 
67
    {
 
68
        $this->markTestIncomplete($this->message);
 
69
    }
 
70
 
 
71
    /**
 
72
     * @return string
 
73
     */
 
74
    public function getMessage()
 
75
    {
 
76
        return $this->message;
 
77
    }
 
78
 
 
79
    /**
 
80
     * Returns a string representation of the test case.
 
81
     *
 
82
     * @return string
 
83
     */
 
84
    public function toString()
 
85
    {
 
86
        return $this->getName();
 
87
    }
 
88
}