~ballot/wordpress/openstack-objectstorage-bis

« back to all changes in this revision

Viewing changes to vendor/phpunit/php-code-coverage/tests/_files/NamespaceCoveredClass.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
namespace Foo;
 
3
 
 
4
class CoveredParentClass
 
5
{
 
6
    private function privateMethod()
 
7
    {
 
8
    }
 
9
 
 
10
    protected function protectedMethod()
 
11
    {
 
12
        $this->privateMethod();
 
13
    }
 
14
 
 
15
    public function publicMethod()
 
16
    {
 
17
        $this->protectedMethod();
 
18
    }
 
19
}
 
20
 
 
21
class CoveredClass extends CoveredParentClass
 
22
{
 
23
    private function privateMethod()
 
24
    {
 
25
    }
 
26
 
 
27
    protected function protectedMethod()
 
28
    {
 
29
        parent::protectedMethod();
 
30
        $this->privateMethod();
 
31
    }
 
32
 
 
33
    public function publicMethod()
 
34
    {
 
35
        parent::publicMethod();
 
36
        $this->protectedMethod();
 
37
    }
 
38
}