Project

General

Profile

Bug #22232 ยป 13737.diff

Administrator Admin, 2010-03-26 19:36

View differences:

tests/typo3/sysext/scheduler/tx_scheduler_croncmd_testcase.php (working copy)
* @test
*/
public function isDayListCorrectForOneDayOfMonth() {
if (!t3lib_extMgm::isLoaded('scheduler')) {
$this->markTestSkipped(
'This test only is applicable if the scheduler is installed.'
);
}
$cronCmdInstance = t3lib_div::makeInstance('tx_scheduler_cronCmd', '* * 2 * *');
$expectedResult = array(
'0' => 2,
......
* @test
*/
public function isDayListCorrectForListOfDayOfMonth() {
if (!t3lib_extMgm::isLoaded('scheduler')) {
$this->markTestSkipped(
'This test only is applicable if the scheduler is installed.'
);
}
$cronCmdInstance = t3lib_div::makeInstance('tx_scheduler_cronCmd', '* * 2,7 * *');
$expectedResult = array(
'0' => 2,
......
* @test
*/
public function isDayListCorrectForRangeOfDayOfMonth() {
if (!t3lib_extMgm::isLoaded('scheduler')) {
$this->markTestSkipped(
'This test only is applicable if the scheduler is installed.'
);
}
$cronCmdInstance = t3lib_div::makeInstance('tx_scheduler_cronCmd', '* * 2-4,10 * *');
$expectedResult = array(
'0' => 2,
......
* @test
*/
public function isDayListCorrectForOneDayOfWeek() {
if (!t3lib_extMgm::isLoaded('scheduler')) {
$this->markTestSkipped(
'This test only is applicable if the scheduler is installed.'
);
}
$cronCmdInstance = t3lib_div::makeInstance('tx_scheduler_cronCmd', '* * * * 1', self::TIMESTAMP);
$expectedResult = array(
'0' => 4,
......
* @test
*/
public function isDayListCorrectForCombinationOfDayOfMonthAndDayOfWeek() {
if (!t3lib_extMgm::isLoaded('scheduler')) {
$this->markTestSkipped(
'This test only is applicable if the scheduler is installed.'
);
}
$cronCmdInstance = t3lib_div::makeInstance('tx_scheduler_cronCmd', '* * 1,2 * 1', self::TIMESTAMP);
$expectedResult = array(
'0' => 1,
......
$this->assertEquals($expectedResult, $actualResult[2]);
}
}
?>
?>
    (1-1/1)