aboutsummaryrefslogtreecommitdiff
path: root/juick-server/src/test/java/com/juick/server
diff options
context:
space:
mode:
authorGravatar Vitaly Takmazov2018-06-25 12:12:12 +0300
committerGravatar Vitaly Takmazov2018-06-25 12:12:12 +0300
commit9efeead3bae831abd66420771ebf2ad703df0026 (patch)
tree22736f2d4e40ef515d9bb895bf22a31e9979425b /juick-server/src/test/java/com/juick/server
parentae542818abf233ec926d32363bd729d249745f66 (diff)
CommandsManager: handle subscription requests to unknown user
Diffstat (limited to 'juick-server/src/test/java/com/juick/server')
-rw-r--r--juick-server/src/test/java/com/juick/server/tests/ServerTests.java3
1 files changed, 3 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 0df39eb6..2c524eec 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
@@ -815,6 +815,9 @@ public class ServerTests {
assertThat(result.getNewMessage().get().getTags().size(), equalTo(2));
assertThat(result.getNewMessage().get().getTags().get(0).getName(), equalTo("Киев"));
assertThat(result.getNewMessage().get().getText(), equalTo(data));
+ result = commandsManager.processCommand(user, "S @unknown-user", emptyUri);
+ assertThat(result.getNewMessage(), is(Optional.empty()));
+ assertThat(result.getText(), is("User not found"));
}
@Test
public void mailParserTest() throws Exception {