Skip to content
Snippets Groups Projects
Commit 0abbc2c5 authored by Jiman Kim's avatar Jiman Kim
Browse files

unit tests back up

parent f06da6d9
No related branches found
No related tags found
1 merge request!324Sonar unit test
Pipeline #229907 failed
......@@ -104,13 +104,14 @@
<groupId>org.mockito</groupId>
<artifactId>mockito-all</artifactId>
</exclusion>
<exclusion>
<groupId>org.junit.vintage</groupId>
<artifactId>junit-vintage-engine</artifactId>
</exclusion>
</exclusions>
</dependency>
<dependency>
<groupId>javax.servlet</groupId>
<artifactId>javax.servlet-api</artifactId>
<version>4.0.1</version>
<scope>provided</scope>
</dependency>
<dependency>
<groupId>org.springframework</groupId>
<artifactId>spring-webmvc</artifactId>
......@@ -125,6 +126,11 @@
</exclusion>
</exclusions>
</dependency>
<dependency>
<groupId>org.junit.vintage</groupId>
<artifactId>junit-vintage-engine</artifactId>
<scope>test</scope>
</dependency>
</dependencies>
<build>
......@@ -187,7 +193,7 @@
<plugin>
<groupId>org.jacoco</groupId>
<artifactId>jacoco-maven-plugin</artifactId>
<version>0.8.3</version>
<version>0.8.10</version>
<executions>
<execution>
<goals>
......
......@@ -14,9 +14,8 @@ limitations under the License. */
package org.opengroup.osdu.unitservice.security;
import org.junit.Before;
import org.junit.Test;
import org.junit.runner.RunWith;
import org.junit.jupiter.api.BeforeEach;
import org.junit.jupiter.api.Test;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.boot.test.context.SpringBootTest;
import org.springframework.boot.test.mock.mockito.MockBean;
......@@ -33,7 +32,6 @@ import org.opengroup.osdu.unitservice.api.UnitApiV3;
import org.opengroup.osdu.unitservice.middleware.AuthenticationRequestFilter;
@RunWith(SpringRunner.class)
@SpringBootTest(classes = {
UnitApiV3.class,
AuthenticationRequestFilter.class,
......@@ -52,8 +50,8 @@ public class AuthSecurityConfigTest {
@Autowired
private WebApplicationContext context;
@Before
public void setup() {
@BeforeEach
public void setUp() {
mockMvc = MockMvcBuilders.webAppContextSetup(context).build();
}
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment