Someone
public text v1 · immutableclass CC_DateTime {
protected $value;
public function __construct() {
$this->type = 'DateTime';
$this->value = new Date();
}
public function getValue() {
$this->value->getDate(DATE_FORMAT_ISO_EXTENDED);
}
}
class CC_DateTimeTest extends UnitTestCase {
public function testGettingDateReturnsISO8601Format() {
$mydate = new CC_DateTime();
$this->assertEqual('', $mydate->getValue());
}
}