From 15b44bf5b02a4ba059cfc659e2812700bf690bde Mon Sep 17 00:00:00 2001 From: Pekka Helenius Date: Wed, 14 Oct 2020 13:15:26 +0300 Subject: [PATCH] Add BookDevController end point tests Signed-off-by: Pekka Helenius --- .../web/dev/endpoint/StatsrefTest.java | 39 +++++++++++++++++++ 1 file changed, 39 insertions(+) create mode 100644 bookstore/src/test/java/com/fjordtek/bookstore/web/dev/endpoint/StatsrefTest.java diff --git a/bookstore/src/test/java/com/fjordtek/bookstore/web/dev/endpoint/StatsrefTest.java b/bookstore/src/test/java/com/fjordtek/bookstore/web/dev/endpoint/StatsrefTest.java new file mode 100644 index 0000000..2f2fadd --- /dev/null +++ b/bookstore/src/test/java/com/fjordtek/bookstore/web/dev/endpoint/StatsrefTest.java @@ -0,0 +1,39 @@ +// Pekka Helenius , Fjordtek 2020 + +package com.fjordtek.bookstore.web.dev.endpoint; + +import org.junit.Test; +import org.springframework.test.context.ActiveProfiles; + +import com.fjordtek.bookstore.web.BookStoreTestWebContextBuilder; + +/** + * + * TODO: N/A + * + * @author Pekka Helenius + */ + +@ActiveProfiles( + profiles = { "dev" } + ) +public class StatsrefTest extends BookStoreTestWebContextBuilder { + + @Test + public void testA_GetStatsrefAsNologin() throws Exception { + loadPageGet(statsRefUrl, 200); + } +/* + @Test + @WithUserDetails("user") + public void testB_GetStatsrefAsNormalUser() throws Exception { + loadPageGet(statsRefUrl, 200); + } + + @Test + @WithUserDetails("admin") + public void testC_GetStatsrefAsAdminUser() throws Exception { + loadPageGet(statsRefUrl, 200); + } +*/ +} \ No newline at end of file