public function testHasHours()
{
$this->given($asserter = $this->newTestedInstance->setLocale($locale = new \mock\atoum\locale()))->then->exception(function () use($asserter) {
$asserter->hasHours(rand(0, PHP_INT_MAX));
})->isInstanceOf('mageekguy\\atoum\\exceptions\\logic')->hasMessage('Value is not an instance of \\dateTime or \\dateTimeInterface')->if($asserter->setWith($dateTime = new \DateTime('01:02:03')))->then->object($asserter->hasHours('01'))->isIdenticalTo($asserter)->object($asserter->hasHours('1'))->isIdenticalTo($asserter)->object($asserter->hasHours(1))->isIdenticalTo($asserter)->if($this->calling($locale)->_ = $badHours = uniqid())->then->exception(function () use($asserter) {
$asserter->hasHours(2);
})->isInstanceOf('mageekguy\\atoum\\asserter\\exception')->hasMessage($badHours)->mock($locale)->call('_')->withArguments('Hours are %s instead of %02d', 1, 2)->once->exception(function () use($asserter, &$failMessage) {
$asserter->hasHours(2, $failMessage = uniqid());
})->isInstanceOf('mageekguy\\atoum\\asserter\\exception')->hasMessage($failMessage);
}