aboutsummaryrefslogtreecommitdiff
path: root/juick-server/src/test/java/com/juick/server
diff options
context:
space:
mode:
Diffstat (limited to 'juick-server/src/test/java/com/juick/server')
-rw-r--r--juick-server/src/test/java/com/juick/server/tests/ServerTests.java7
1 files changed, 7 insertions, 0 deletions
diff --git a/juick-server/src/test/java/com/juick/server/tests/ServerTests.java b/juick-server/src/test/java/com/juick/server/tests/ServerTests.java
index 41f2b68c..8e3e5dfd 100644
--- a/juick-server/src/test/java/com/juick/server/tests/ServerTests.java
+++ b/juick-server/src/test/java/com/juick/server/tests/ServerTests.java
@@ -584,6 +584,13 @@ public class ServerTests {
assertThat(juickTag.TID, is(2));
tagService.updateTags(topmid, Collections.singletonList(juickTag));
assertThat(messagesService.getPopularCandidates().isEmpty(), is(true));
+ tagService.updateTags(topmid, Collections.singletonList(juickTag));
+ assertThat(messagesService.getPopularCandidates().isEmpty(), is(false));
+ jdbcTemplate.update("INSERT INTO tags(tag_id, name) VALUES(805, 'NSFW')");
+ Tag nsfw = tagService.getTag("NSFW", false);
+ assertThat(nsfw.TID, equalTo(805));
+ tagService.updateTags(topmid, Collections.singletonList(nsfw));
+ assertThat(messagesService.getPopularCandidates().isEmpty(), is(true));
}
@Test
public void inReplyToScannerTest() {