Skip to content

Commit

Permalink
fix tests
Browse files Browse the repository at this point in the history
  • Loading branch information
Piotr Adamczyk committed Jan 1, 2021
1 parent a7b33d1 commit c36bf4a
Showing 1 changed file with 1 addition and 2 deletions.
Original file line number Diff line number Diff line change
@@ -1,7 +1,6 @@
package flank.scripts.ci.nexttag

import java.time.LocalDate
import java.time.Year
import java.time.format.DateTimeFormatter

fun generateNextReleaseTag(previousReleaseTag: String): String {
Expand All @@ -14,7 +13,7 @@ fun generateNextReleaseTag(previousReleaseTag: String): String {
}

private fun isNextReleaseInCurrentMonth(year: String, month: String) =
DateTimeFormatter.ofPattern("yy").format(Year.now()) == year &&
DateTimeFormatter.ofPattern("yy").format(LocalDate.now()) == year &&
DateTimeFormatter.ofPattern("MM").format(LocalDate.now()) == month

private fun currentMonthFirstTag() = "v${DateTimeFormatter.ofPattern("yy.MM").format(LocalDate.now())}.0"

0 comments on commit c36bf4a

Please sign in to comment.