forked from jmrozanec/cron-utils
-
Notifications
You must be signed in to change notification settings - Fork 1
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
1 parent
d31697e
commit e38d2e2
Showing
1 changed file
with
29 additions
and
0 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,29 @@ | ||
package com.cronutils; | ||
|
||
import com.cronutils.mapper.CronMapper; | ||
import com.cronutils.model.Cron; | ||
import com.cronutils.model.CronType; | ||
import com.cronutils.model.definition.CronDefinitionBuilder; | ||
import com.cronutils.parser.CronParser; | ||
import org.junit.jupiter.api.BeforeEach; | ||
import org.junit.jupiter.api.Test; | ||
|
||
import static org.junit.jupiter.api.Assertions.assertDoesNotThrow; | ||
|
||
public class Issue605Test { | ||
|
||
private CronParser cronParser; | ||
|
||
@BeforeEach | ||
public void setUp() { | ||
this.cronParser = new CronParser(CronDefinitionBuilder.instanceDefinitionFor(CronType.SPRING)); | ||
} | ||
|
||
@Test | ||
public void testDayOfWeekMapping() { | ||
Cron cron = this.cronParser.parse("0 0 0 ? * 5#1"); | ||
CronMapper mapper = CronMapper.fromSpringToQuartz(); | ||
assertDoesNotThrow(() -> mapper.map(cron)); | ||
} | ||
|
||
} |