From a98689880e3568eb745fd76b054e9e33fca0857c Mon Sep 17 00:00:00 2001 From: Florian Zschocke Date: Mon, 10 Jun 2019 22:11:35 +0200 Subject: [PATCH] Fix revLog test that broke due to changes in the hello-world repository. --- src/test/data/hello-world.properties | 1 + src/test/java/com/gitblit/tests/JGitUtilsTest.java | 7 ++++--- 2 files changed, 5 insertions(+), 3 deletions(-) diff --git a/src/test/data/hello-world.properties b/src/test/data/hello-world.properties index 7828a8ce..7482c863 100644 --- a/src/test/data/hello-world.properties +++ b/src/test/data/hello-world.properties @@ -5,6 +5,7 @@ commit.fifteen=5ebfaca commit.added=192cded commit.changed=b2c50ce commit.deleted=8613bee10bde27a0fbaca66447cdc3f0f9483365 +commits.since_20190605=10 users.byEmail=11 users.byName=10 files.top=14 diff --git a/src/test/java/com/gitblit/tests/JGitUtilsTest.java b/src/test/java/com/gitblit/tests/JGitUtilsTest.java index a493884a..1d9150a1 100644 --- a/src/test/java/com/gitblit/tests/JGitUtilsTest.java +++ b/src/test/java/com/gitblit/tests/JGitUtilsTest.java @@ -656,10 +656,11 @@ public class JGitUtilsTest extends GitblitUnitTest { commits = JGitUtils.getRevLog(repository, null, "java.java", 0, 2); assertEquals(2, commits.size()); - // grab the commits since 2008-07-15 + // grab the commits since 2019-06-05 commits = JGitUtils.getRevLog(repository, null, - new SimpleDateFormat("yyyy-MM-dd").parse("2008-07-15")); - assertEquals(12, commits.size()); + new SimpleDateFormat("yyyy-MM-dd").parse("2019-06-05")); + assertEquals("Wrong number of commits since 2019-06-05.", + GitBlitSuite.helloworldSettings.getInteger(HelloworldKeys.commits.since_20190605, -1), commits.size()); repository.close(); } -- 2.39.5