Completed
Branch 3.0.0 (d1c058)
by Serhii
02:32
created

OsTest::testLinux()   A

Complexity

Conditions 1
Paths 1

Size

Total Lines 8
Code Lines 4

Duplication

Lines 0
Ratio 0 %

Importance

Changes 1
Bugs 0 Features 0
Metric Value
cc 1
eloc 4
c 1
b 0
f 0
nc 1
nop 0
dl 0
loc 8
rs 9.4285
1
<?php
2
/**
3
 * @author Sergey Nehaenko <[email protected]>
4
 * @license GPL
5
 * @copyright Sergey Nehaenko &copy 2016
6
 * @version 1.0
7
 * @project browser-detector
8
 */
9
10
namespace EndorphinStudio\Tests;
11
12
13
class OsTest extends \PHPUnit_Framework_TestCase
14
{
15
    public function testLinux()
16
    {
17
        $ualist = array(
18
            'Mozilla/1.1I (X11; I; UNIX_SV 4.2MP R4000)',
19
        );
20
21
        testUaList($this,'OS','Name',$ualist,'Linux');
22
    }
23
24
    public function testAIX()
25
    {
26
        $ualist = array(
27
            'Mozilla/4.04j2 [en] (X11; I; AIX 4.2) ',
28
        );
29
30
        testUaList($this,'OS','Name',$ualist,'AIX');
31
    }
32
33
    public function testAliyunOS()
34
    {
35
        $ualist = array(
36
            'Mozilla/5.0 (Linux; U; AliyunOS 2.0; Android 4.0 Compatible; xx; R819T Build/AliyunOs-2012) AppleWebKit/534.30 (KHTML, like Gecko) Version/4.0 Mobile Safari/534.30',
37
        );
38
39
        testUaList($this,'OS','Name',$ualist,'Aliyun OS');
40
    }
41
}