Skip to content

Commit 6b70cbe

Browse files
committed
Update README.md
1 parent 89b2b2c commit 6b70cbe

3 files changed

Lines changed: 5 additions & 8 deletions

File tree

README.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -20,7 +20,7 @@ cron-utils is available on [Maven central](http://search.maven.org/#search%7Cga%
2020
<dependency>
2121
<groupId>com.cronutils</groupId>
2222
<artifactId>cron-utils</artifactId>
23-
<version>9.1.0</version>
23+
<version>9.1.1</version>
2424
</dependency>
2525

2626
For Android developers, cron-utils 7.0.0 assumes Android 26+. For earlier Android versions consider using cron-utils 6.0.6.

src/main/java/com/cronutils/model/time/SingleExecutionTime.java

Lines changed: 1 addition & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -324,10 +324,7 @@ private ExecutionTimeResult potentialPreviousClosestMatch(final ZonedDateTime da
324324

325325
if (year.isEmpty()) {
326326
return getPreviousPotentialYear(date, days, highestMonth, highestDay, highestHour, highestMinute, highestSecond);
327-
}
328-
//TODO Issue 305
329-
330-
else{
327+
} else {
331328
if(!year.contains(date.getYear())){
332329
Optional<Integer> validprevyear = year.stream().filter(y->y<date.getYear()).max(Integer::compareTo);
333330
if(validprevyear.isPresent()){

src/test/java/com/cronutils/Issue404Test.java

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -34,7 +34,7 @@
3434
*/
3535
public class Issue404Test {
3636

37-
@Ignore
37+
3838
@Test
3939
public void testNovember3Midnight() {
4040
final CronDefinition cronDefinition = CronDefinitionBuilder.defineCron().withMinutes().and().withHours().and()
@@ -44,7 +44,7 @@ public void testNovember3Midnight() {
4444

4545
final ExecutionTime executionTime = ExecutionTime.forCron(cron);
4646

47-
final ZonedDateTime time = LocalDateTime.of(2019, 11, 3, 0, 0, 1).atZone(ZoneId.of("America/Sao_Paulo"));
47+
final ZonedDateTime time = ZonedDateTime.of(2019, 11, 3, 0, 0, 1, 0, ZoneId.of("America/Sao_Paulo"));
4848

4949
final Duration timeFromLastExecution = executionTime.timeFromLastExecution(time).get();
5050

@@ -61,7 +61,7 @@ public void testNovember3Noon() {
6161

6262
final ExecutionTime executionTime = ExecutionTime.forCron(cron);
6363

64-
final ZonedDateTime time = LocalDateTime.of(2019, 11, 3, 12, 0, 0).atZone(ZoneId.of("America/Sao_Paulo"));
64+
final ZonedDateTime time = ZonedDateTime.of(2019, 11, 3, 12, 0, 1, 0, ZoneId.of("America/Sao_Paulo"));
6565

6666
final Duration timeFromLastExecution = executionTime.timeFromLastExecution(time).get();
6767

0 commit comments

Comments
 (0)