From 58b1fbbdd610de31a5883813206f9086e241207e Mon Sep 17 00:00:00 2001 From: Vitaly Takmazov Date: Sun, 22 Aug 2021 07:30:20 +0300 Subject: ActivityPub: Mention includes domain in the name property --- src/test/java/com/juick/UserTest.java | 7 +++++++ 1 file changed, 7 insertions(+) (limited to 'src/test/java/com') diff --git a/src/test/java/com/juick/UserTest.java b/src/test/java/com/juick/UserTest.java index 9af67467..6c0cdb88 100644 --- a/src/test/java/com/juick/UserTest.java +++ b/src/test/java/com/juick/UserTest.java @@ -20,6 +20,8 @@ package com.juick; import com.fasterxml.jackson.databind.ObjectMapper; import com.juick.model.User; import com.juick.test.util.MockUtils; +import com.juick.www.api.activity.model.objects.Mention; + import org.junit.jupiter.api.Test; import java.io.IOException; @@ -36,4 +38,9 @@ public class UserTest { assertEquals(ugnich, jsonUgnich); } + @Test + public void mentionFormat() { + Mention mention = new Mention("https://example.com/users/test", "testuser"); + assertEquals("@testuser@example.com", mention.getName()); + } } -- cgit v1.2.3