Passed
Push — master ( 67a964...2aff1a )
by Konrad
04:08
created

getNormalizedValueTest   A

Complexity

Total Complexity 1

Size/Duplication

Total Lines 14
Duplicated Lines 0 %

Importance

Changes 1
Bugs 0 Features 0
Metric Value
eloc 4
dl 0
loc 14
rs 10
c 1
b 0
f 0
wmc 1

1 Method

Rating   Name   Duplication   Size   Complexity  
A test() 0 9 1
1
<?php
2
3
namespace Tests\Unit\functions;
4
5
use function sweetrdf\InMemoryStoreSqlite\getNormalizedValue;
6
use Tests\TestCase;
7
8
class getNormalizedValueTest extends TestCase
9
{
10
    /**
11
     * Tests to behavior, if a datetime string was given.
12
     */
13
    public function test()
14
    {
15
        // case with +hourse
16
        $string = '2009-05-28T18:03:38+09:00';
17
        $this->assertEquals('2009-05-28T09:03:38Z', getNormalizedValue($string));
18
19
        // GMT case
20
        $string = '2009-05-28T18:03:38GMT';
21
        $this->assertEquals('2009-05-28T18:03:38Z', getNormalizedValue($string));
22
    }
23
}
24