-
Notifications
You must be signed in to change notification settings - Fork 1
/
Copy pathtrinary_test.php
59 lines (49 loc) · 1.28 KB
/
trinary_test.php
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
<?php
require "trinary.php";
class TrinaryTest extends \PHPUnit_Framework_TestCase
{
public function test1IsDecimal1()
{
$this->assertEquals(1, toDecimal('1'));
}
public function test2IsDecimal2()
{
$this->markTestSkipped();
$this->assertEquals(2, toDecimal('2'));
}
public function test10IsDecimal3()
{
$this->markTestSkipped();
$this->assertEquals(3, toDecimal('10'));
}
public function test11IsDecimal4()
{
$this->markTestSkipped();
$this->assertEquals(4, toDecimal('11'));
}
public function test100IsDecimal9()
{
$this->markTestSkipped();
$this->assertEquals(9, toDecimal('100'));
}
public function test112IsDecimal14()
{
$this->markTestSkipped();
$this->assertEquals(14, toDecimal('112'));
}
public function test222IsDecimal26()
{
$this->markTestSkipped();
$this->assertEquals(26, toDecimal('222'));
}
public function test1122000120IsDecimal32091()
{
$this->markTestSkipped();
$this->assertEquals(32091, toDecimal('1122000120'));
}
public function testInvalidTrinaryIsDecimal0()
{
$this->markTestSkipped();
$this->assertSame(0, toDecimal('13201'));
}
}