Failed Conditions
Push — rbac ( be68b4...52c28b )
by Michael
03:11
created

FakeGlobalStateProvider::getServerSuperGlobal()   A

Complexity

Conditions 1
Paths 1

Size

Total Lines 3
Code Lines 2

Duplication

Lines 0
Ratio 0 %

Code Coverage

Tests 0
CRAP Score 2

Importance

Changes 0
Metric Value
eloc 2
c 0
b 0
f 0
dl 0
loc 3
ccs 0
cts 3
cp 0
rs 10
cc 1
nc 1
nop 0
crap 2
1
<?php
2
/******************************************************************************
3
 * Wikipedia Account Creation Assistance tool                                 *
4
 *                                                                            *
5
 * All code in this file is released into the public domain by the ACC        *
6
 * Development Team. Please see team.json for a list of contributors.         *
7
 ******************************************************************************/
8
9
namespace Waca\Providers\GlobalState;
10
11
/**
12
 * Class TestStateProvider
13
 *
14
 * This class is only to be used for testing sets of the global state variables. For everything else, please use PHPUnit
15
 * mocks as normal.
16
 *
17
 * @package Waca\Tests\Utility
18
 */
19
class FakeGlobalStateProvider extends GlobalStateProvider implements IGlobalStateProvider
20
{
21
    var $server = array();
0 ignored issues
show
Coding Style introduced by
The visibility should be declared for property $server.

The PSR-2 coding standard requires that all properties in a class have their visibility explicitly declared. If you declare a property using

class A {
    var $property;
}

the property is implicitly global.

To learn more about the PSR-2, please see the PHP-FIG site on the PSR-2.

Loading history...
22
    var $get = array();
0 ignored issues
show
Coding Style introduced by
The visibility should be declared for property $get.

The PSR-2 coding standard requires that all properties in a class have their visibility explicitly declared. If you declare a property using

class A {
    var $property;
}

the property is implicitly global.

To learn more about the PSR-2, please see the PHP-FIG site on the PSR-2.

Loading history...
23
    var $post = array();
0 ignored issues
show
Coding Style introduced by
The visibility should be declared for property $post.

The PSR-2 coding standard requires that all properties in a class have their visibility explicitly declared. If you declare a property using

class A {
    var $property;
}

the property is implicitly global.

To learn more about the PSR-2, please see the PHP-FIG site on the PSR-2.

Loading history...
24
    var $session = array();
0 ignored issues
show
Coding Style introduced by
The visibility should be declared for property $session.

The PSR-2 coding standard requires that all properties in a class have their visibility explicitly declared. If you declare a property using

class A {
    var $property;
}

the property is implicitly global.

To learn more about the PSR-2, please see the PHP-FIG site on the PSR-2.

Loading history...
25
26
    public function &getServerSuperGlobal()
27
    {
28
        return $this->server;
29
    }
0 ignored issues
show
Coding Style introduced by
Expected //end getServerSuperGlobal()
Loading history...
30
31
    public function &getGetSuperGlobal()
32
    {
33
        return $this->get;
34
    }
0 ignored issues
show
Coding Style introduced by
Expected //end getGetSuperGlobal()
Loading history...
35
36
    public function &getPostSuperGlobal()
37
    {
38
        return $this->post;
39
    }
0 ignored issues
show
Coding Style introduced by
Expected //end getPostSuperGlobal()
Loading history...
40
41
    public function &getSessionSuperGlobal()
42
    {
43
        return $this->session;
44
    }
0 ignored issues
show
Coding Style introduced by
Expected //end getSessionSuperGlobal()
Loading history...
45
}
0 ignored issues
show
Coding Style introduced by
Expected //end class
Loading history...