Fixed the Integration Build Pipeline

This commit is contained in:
Bhaskara Navuluri
2022-06-06 20:35:38 +05:30
parent 2c1aeb932e
commit 7f659e5609
5 changed files with 11 additions and 129 deletions

View File

@@ -52,8 +52,8 @@ public class SecurityConfiguration {
//@formatter:off
return http
.authorizeHttpRequests(authorizeRequests -> authorizeRequests
.antMatchers("/api/auth/**", "/swagger-ui.html", "/swagger-ui/**", "/v3/api-docs/**", "/webjars/**",
"/swagger-ui/index.html")
.antMatchers("/api/auth/**", "/swagger-ui-custom.html" ,"/swagger-ui.html", "/swagger-ui/**", "/v3/api-docs/**", "/webjars/**",
"/swagger-ui/index.html","/api-docs/**")
.permitAll()
.anyRequest()
.authenticated())

View File

@@ -11,7 +11,7 @@ public class SecurityTokenApplication {
* @param args
*/
public static void main(String[] args) {
SpringApplication.run(SecurityTokenApplication.class, args);
SpringApplication.run(SecurityTokenApplication.class);
}
}

View File

@@ -30,7 +30,7 @@ class OpenApiJwtIntegrationTest
{
assertNotNull(authenticationApi);
String response = this.restTemplate.getForObject("http://localhost:" + port + "/swagger-ui.html", String.class);
String response = this.restTemplate.getForObject("http://localhost:" + port + "/swagger-ui/index.html", String.class);
assertNotNull(response);
assertTrue(response.contains("Swagger UI"));
@@ -43,7 +43,7 @@ class OpenApiJwtIntegrationTest
{
assertNotNull(authenticationApi);
ResponseEntity<String> response = this.restTemplate.getForEntity("http://localhost:" + port + "/v3/api-docs",
ResponseEntity<String> response = this.restTemplate.getForEntity("http://localhost:" + port + "/api-docs",
String.class);
assertNotNull(response);
@@ -59,7 +59,7 @@ class OpenApiJwtIntegrationTest
{
assertNotNull(authenticationApi);
ResponseEntity<String> response = this.restTemplate.getForEntity("http://localhost:" + port + "/v3/api-docs",
ResponseEntity<String> response = this.restTemplate.getForEntity("http://localhost:" + port + "/api-docs",
String.class);
assertNotNull(response);
@@ -75,7 +75,7 @@ class OpenApiJwtIntegrationTest
{
assertNotNull(authenticationApi);
ResponseEntity<String> response = this.restTemplate.getForEntity("http://localhost:" + port + "/v3/api-docs",
ResponseEntity<String> response = this.restTemplate.getForEntity("http://localhost:" + port + "/api-docs",
String.class);
assertNotNull(response);