From e30087dacaf59f2328e74f1a88a2be3e60a93e80 Mon Sep 17 00:00:00 2001 From: =?utf8?q?David=20=E2=80=98Bombe=E2=80=99=20Roden?= Date: Tue, 11 Oct 2016 21:38:59 +0200 Subject: [PATCH] Setup core and web interface separately --- src/test/java/net/pterodactylus/sone/web/WebPageTest.java | 6 +++++- 1 file changed, 5 insertions(+), 1 deletion(-) diff --git a/src/test/java/net/pterodactylus/sone/web/WebPageTest.java b/src/test/java/net/pterodactylus/sone/web/WebPageTest.java index 3cbc75e..c135d07 100644 --- a/src/test/java/net/pterodactylus/sone/web/WebPageTest.java +++ b/src/test/java/net/pterodactylus/sone/web/WebPageTest.java @@ -55,9 +55,13 @@ public abstract class WebPageTest { } @Before - public final void setupWebInterface() { + public final void setupCore() { UpdateChecker updateChecker = mock(UpdateChecker.class); when(webInterface.getCore().getUpdateChecker()).thenReturn(updateChecker); + } + + @Before + public final void setupWebInterface() { when(webInterface.getCurrentSone(toadletContext)).thenReturn(currentSone); when(webInterface.getCurrentSone(eq(toadletContext), anyBoolean())).thenReturn(currentSone); when(webInterface.getNotifications(currentSone)).thenReturn(new ArrayList()); -- 2.7.4