diff options
author | 2018-09-04 12:25:14 +0300 | |
---|---|---|
committer | 2018-09-04 12:25:14 +0300 | |
commit | 5c491c20f8201b1a90335899aa0f2eb72ed0daff (patch) | |
tree | dd4f7857f0a3745030e08eea999676a8cbc462be /juick-server/src/test/java/com/juick/server | |
parent | b3d633cf0e8a6c35be9755702dedbea29ff3d897 (diff) |
ActivityStreams initial support
Diffstat (limited to 'juick-server/src/test/java/com/juick/server')
-rw-r--r-- | juick-server/src/test/java/com/juick/server/tests/ServerTests.java | 8 |
1 files changed, 8 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 9a4fb93a..63ba4b3e 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 @@ -23,6 +23,7 @@ import com.fasterxml.jackson.databind.ObjectMapper; import com.jayway.jsonpath.JsonPath; import com.juick.*; import com.juick.server.*; +import com.juick.server.api.activity.model.ActivityObject; import com.juick.server.component.MessageEvent; import com.juick.server.helpers.AnonymousUser; import com.juick.server.helpers.CommandResult; @@ -1332,4 +1333,11 @@ public class ServerTests { mockMvc.perform(get("/.well-known/webfinger?resource=acct:durov@localhost")) .andExpect(status().isNotFound()); } + @Test + public void userProfilesShouldBeExposedAsActivityStream() throws Exception { + mockMvc.perform(get("/u/ugnich").accept(ActivityObject.CONTENT_TYPE)) + .andExpect(status().isOk()) + .andExpect(jsonPath("$.@context", is(ActivityObject.CONTEXT_URI))) + .andExpect(jsonPath("$.icon", is("http://localhost:8080/i/a/1.png"))); + } } |