From 3d08e91faa3faaf496fdec77b9a11a03b8be1041 Mon Sep 17 00:00:00 2001 From: =?utf8?q?David=20=E2=80=98Bombe=E2=80=99=20Roden?= Date: Mon, 28 Oct 2013 21:50:24 +0100 Subject: [PATCH] Return an empty profile from a mocked Sone. --- src/test/java/net/pterodactylus/sone/data/Mocks.java | 1 + 1 file changed, 1 insertion(+) diff --git a/src/test/java/net/pterodactylus/sone/data/Mocks.java b/src/test/java/net/pterodactylus/sone/data/Mocks.java index 5715084..e1b9102 100644 --- a/src/test/java/net/pterodactylus/sone/data/Mocks.java +++ b/src/test/java/net/pterodactylus/sone/data/Mocks.java @@ -77,6 +77,7 @@ public class Mocks { Sone sone = mock(Sone.class); when(sone.getId()).thenReturn(id); when(sone.isLocal()).thenReturn(false); + when(sone.getProfile()).thenReturn(new Profile(sone)); final Database database = core.getDatabase(); when(sone.newPostBuilder()).thenThrow(IllegalStateException.class); when(sone.newPostReplyBuilder(Matchers.anyObject())).thenThrow(IllegalStateException.class); -- 2.7.4