Made wepAppContex commont

This commit is contained in:
BuildTools
2020-10-30 16:53:41 +01:00
parent 4267fadf62
commit 1327a239e8
8 changed files with 17 additions and 37 deletions

View File

@ -3,13 +3,11 @@ package com.plannaplan.controllers;
import org.junit.Ignore;
import org.junit.Test;
import org.junit.runner.RunWith;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.boot.test.context.SpringBootTest;
import org.springframework.test.context.ContextConfiguration;
import org.springframework.test.context.junit4.SpringRunner;
import org.springframework.test.web.servlet.MockMvc;
import org.springframework.test.web.servlet.setup.MockMvcBuilders;
import org.springframework.web.context.WebApplicationContext;
import static org.springframework.test.web.servlet.request.MockMvcRequestBuilders.get;
import static org.springframework.test.web.servlet.result.MockMvcResultMatchers.status;
@ -17,10 +15,8 @@ import static org.springframework.test.web.servlet.result.MockMvcResultMatchers.
@RunWith(SpringRunner.class)
@SpringBootTest
@ContextConfiguration
public class TokenControllerTest {
public class TokenControllerTest extends AbstractControllerTest {
private final String TOKEN_ENDPOINT = "/token";
@Autowired
private WebApplicationContext webApplicationContext;
@Test
public void shouldFailWithNoParameter() throws Exception {