GitHub Access Token became invalid

It seems like the GitHub access token used for retrieving details about this repository from GitHub became invalid. This might prevent certain types of inspections from being run (in particular, everything related to pull requests).
Please ask an admin of your repository to re-new the access token on this website.
Completed
Push — dev ( 3d92be...f468a1 )
by w3l
02:00
created

Tests   A

Complexity

Total Complexity 6

Size/Duplication

Total Lines 80
Duplicated Lines 0 %

Coupling/Cohesion

Components 1
Dependencies 1

Importance

Changes 1
Bugs 0 Features 0
Metric Value
wmc 6
c 1
b 0
f 0
lcom 1
cbo 1
dl 0
loc 80
rs 10
1
<?php
2
/**
3
 * Tests.php 
4
 * @ignore
5
 */
6
namespace w3l\Holt45\Tests;
7
8
require_once dirname(__FILE__) . '/holt45.php';
9
10
class Tests extends \Holt45
11
{
12
    public function allTests()
13
    {
14
        /* $_GET */
15
        if (self::chkGet("q")) {
16
            echo '$_GET["q"] is set';
17
        }
18
19
        echo self::assignFromGet("q"); // "" or $_GET["q"]
20
21
        if (self::chkGetAll(array("q", "search"))) {
22
            echo '$_GET["q"] and $_GET["search"] is set';
23
        }
24
25
        /* $_POST */
26
        if (self::chkPost("q")) {
27
            echo '$_POST["q"] is set';
28
        }
29
30
        echo self::assignFromPost("q"); // "" or $_POST["q"]
31
32
        if (self::chkPostAll(array("q", "search"))) {
33
            echo '$_POST["q"] and $_POST["search"] is set';
34
        }
35
36
        /* Sessions */
37
        self::sessionSet("example_session_name", "content of session", 86400);
38
39
        if (self::sessionIsset("example_session_name")) {
40
            echo 'Session example_session_name is set and not expired';
41
        }
42
43
        echo self::sessionRead("example_session_name"); // content of session
44
45
        self::sessionDelete("example_session_name"); // Deletes session
46
47
        /* Time */
48
        echo self::timestampToHttpDate("1980-01-01 17:15:00"); // Tue, 01 Jan 1980 16:15:00 GMT
49
50
        echo self::timeElapsed("1980-01-01 17:15:00"); // 13173 days
51
52
        /* Browser */
53
        echo self::getClientIpAddress(); // 127.0.0.1
54
        
55
        echo self::getClientOperatingSystem(); // linux
56
        
57
        echo self::getClientBrowser(); // Firefox
58
        
59
        /* Convert */
60
        echo self::rgbhex(array(255, 0, 0)); // ff0000
61
62
        print_r(self::hexrgb("#FF0000")); // Array([0] => 255, [1] => 0, [2] => 0)
63
64
        /* Strings */
65
        echo self::textareaEncode('<textarea id="tex1"></textarea> <p> asdasd </p>'); // [textarea id="tex1"][/textarea] <p> asdasd </p>
66
67
        echo self::textareaDecode('[textarea id="tex1"][/textarea] <p> asdasd </p>'); // <textarea id="tex1"></textarea> <p> asdasd </p>
68
69
        echo self::obfuscateString("Hi, I'm a ninja!"); // 49574671626d6c75494745676253644a4943787053413d3d
70
71
        echo self::deobfuscateString("49574671626d6c75494745676253644a4943787053413d3d"); // Hi, I'm a ninja!
72
73
        echo self::replaceString("Hi my name is [@foo] and i like [@bar]", array("foo" => "sven", "bar" => "beer")); // Hi my name is sven and i like beer
74
75
        echo self::rainbowText("Hallo world"); // <span style="color: #ff0000;">H</span><span style="color: #ff3300;">a</span>...
76
        
77
        echo self::kbdSymbol("enter"); // &#9166;
78
79
        echo self::kbdShortcut(array("Ctrl", "Alt", "Delete"), "auto"); // <kbd class="holt45-kbd"><span class="holt45-kbd__symbol">&#10034;</span>Ctrl</kbd> + <kbd class="holt45-kbd"><span class="holt45-kbd__symbol">&#9095;</span>Alt</kbd> + <kbd class="holt45-kbd"><span class="holt45-kbd__symbol">&#9003;</span>Delete</kbd>
80
81
        /* Math */
82
        print_r(self::generatePaginationRange(106, 15, 7)); // Array([0] => 1, [1] => 13, [2] => 14, [3] => 15, [4] => 16, [5] => 17, [6] => 106)
83
84
        /* Misc */
85
        print_r(self::urlParser("htt://w.google..com/")); // Array([url] => http://www.google.com/, [url_display] => www.google.com)
86
87
        echo self::generatePassword(10); // 2k%=cbot:w
88
89
        echo self::generatePassword(10, "simple"); // m9b7gfkmhc
90
91
        echo self::iso3166ToName("SE"); // SWEDEN
92
93
        /* constants */
94
        echo self::DATA_URI_TRANSPARENT_GIF; // data:image/gif;base64,R0lGODlhAQABAIAAAAAAAP///yH5BAEAAAAALAAAAAABAAEAAAIBRAA7
95
96
        echo self::DATA_URI_TRANSPARENT_PNG; // data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAAAEAAAABCAQAAAC1HAwCAAAAC0lEQVQYV2NgYAAAAAMAAWgmWQ0AAAAASUVORK5CYII=
97
    }
98
}
99