本文整理匯總了PHP中TYPO3\CMS\Core\Tests\AccessibleObjectInterface::checkValue_input_Eval方法的典型用法代碼示例。如果您正苦於以下問題:PHP AccessibleObjectInterface::checkValue_input_Eval方法的具體用法?PHP AccessibleObjectInterface::checkValue_input_Eval怎麽用?PHP AccessibleObjectInterface::checkValue_input_Eval使用的例子?那麽, 這裏精選的方法代碼示例或許可以為您提供幫助。您也可以進一步了解該方法所在類TYPO3\CMS\Core\Tests\AccessibleObjectInterface
的用法示例。
在下文中一共展示了AccessibleObjectInterface::checkValue_input_Eval方法的2個代碼示例,這些例子默認根據受歡迎程度排序。您可以為喜歡或者感覺有用的代碼點讚,您的評價將有助於係統推薦出更棒的PHP代碼示例。
示例1: evalCheckValueDouble2
/**
* @test
*/
public function evalCheckValueDouble2()
{
$testData = array('-0,5' => '-0.50', '1000' => '1000.00', '1000,10' => '1000.10', '1000,0' => '1000.00', '600.000.000,00' => '600000000.00', '60aaa00' => '6000.00');
foreach ($testData as $value => $expectedReturnValue) {
$returnValue = $this->subject->checkValue_input_Eval($value, array('double2'), '');
$this->assertSame($returnValue['value'], $expectedReturnValue);
}
}
示例2: evalCheckValueDatetime
/**
* @test
* @dataProvider dataProviderDatetime
*/
public function evalCheckValueDatetime($input, $serverTimezone, $expectedOutput)
{
$oldTimezone = date_default_timezone_get();
date_default_timezone_set($serverTimezone);
$output = $this->subject->checkValue_input_Eval($input, ['datetime'], '');
// set before the assertion is performed, so it is restored even for failing tests
date_default_timezone_set($oldTimezone);
$this->assertEquals($expectedOutput, $output['value']);
}