PHP Class Mongolid\Serializer\Type\UTCDatetimeTest

Inheritance: extends TestCas\TestCase
Datei anzeigen Open project: leroy-merlin-br/mongolid

Protected Properties

Property Type Description
$dateTime UTCDateTime
$mongoDate MongoDB\BSON\UTCDateTime
$timestamp integer

Public Methods

Method Description
setUp ( )
tearDown ( )
testCallUndefinedMethodOfUtcDateTimeShouldCallMongoUtcDateTime ( )
testConstrucorWithInvalidParameterShouldThrowException ( )
testConstructorUsingMongoDateShouldSetMongoDateAndTimestamp ( )
testConstructorUsingNullShouldSetMongoDateAndTimestamp ( )
testConstructorUsingTimestampShouldSetMongoDateAndTimestamp ( )
testConvertShouldRetrieveMongodbUtcDateTime ( )
testShouldGetDateTimeWithProperTimezoneSet ( )
testShouldProperlyEncodeToJson ( )
testUnserializeShouldKeepFormattedDate ( )
testUtcDateTimeShouldBeSerializable ( )

Method Details

setUp() public method

public setUp ( )

tearDown() public method

public tearDown ( )

testCallUndefinedMethodOfUtcDateTimeShouldCallMongoUtcDateTime() public method

testConstrucorWithInvalidParameterShouldThrowException() public method

testConstructorUsingMongoDateShouldSetMongoDateAndTimestamp() public method

testConstructorUsingNullShouldSetMongoDateAndTimestamp() public method

testConstructorUsingTimestampShouldSetMongoDateAndTimestamp() public method

testConvertShouldRetrieveMongodbUtcDateTime() public method

testShouldGetDateTimeWithProperTimezoneSet() public method

testShouldProperlyEncodeToJson() public method

testUnserializeShouldKeepFormattedDate() public method

testUtcDateTimeShouldBeSerializable() public method

Property Details

$dateTime protected_oe property

protected UTCDateTime,Mongolid\Serializer\Type $dateTime
return UTCDateTime

$mongoDate protected_oe property

protected UTCDateTime,MongoDB\BSON $mongoDate
return MongoDB\BSON\UTCDateTime

$timestamp protected_oe property

protected int $timestamp
return integer