php-tools/tests/ActionDateCTest.php

15 lines
446 B
PHP
Raw Normal View History

2013-07-25 17:25:26 +00:00
<?php
class ActionDateCTest extends PHPUnit_Framework_TestCase {
function testDecode() {
$action = new ActionDateC("1374772515");
$expected = [1374772515 => '2013-07-25T17:15:15+00:00'];
$this->assertEquals($expected, $action->decode());
}
function testDecodeHasCorrectNumberOfResults() {
$action = new ActionDateC("1374772515\n1374772516");
$this->assertCount(2, $action->decode());
}
}