Fix wrong imports
This commit is contained in:
parent
6a2d8b85ef
commit
c3c4dc627a
@ -1,12 +1,11 @@
|
|||||||
package com.baeldung.boot.jersey.controllers;
|
package com.baeldung.boot.jersey.controllers;
|
||||||
|
|
||||||
import java.awt.PageAttributes.MediaType;
|
|
||||||
|
|
||||||
import javax.ws.rs.GET;
|
import javax.ws.rs.GET;
|
||||||
import javax.ws.rs.Path;
|
import javax.ws.rs.Path;
|
||||||
import javax.ws.rs.PathParam;
|
import javax.ws.rs.PathParam;
|
||||||
import javax.ws.rs.Produces;
|
import javax.ws.rs.Produces;
|
||||||
import javax.xml.ws.Response;
|
import javax.ws.rs.core.MediaType;
|
||||||
|
import javax.ws.rs.core.Response;
|
||||||
|
|
||||||
@Path("/hello")
|
@Path("/hello")
|
||||||
public class HelloController {
|
public class HelloController {
|
||||||
@ -15,8 +14,7 @@ public class HelloController {
|
|||||||
@Path("/{name}")
|
@Path("/{name}")
|
||||||
@Produces(MediaType.TEXT_PLAIN)
|
@Produces(MediaType.TEXT_PLAIN)
|
||||||
public Response hello(@PathParam("name") String name) {
|
public Response hello(@PathParam("name") String name) {
|
||||||
return Response.ok("Hello, " + name)
|
return Response.ok("Hello, " + name).build();
|
||||||
.build();
|
|
||||||
}
|
}
|
||||||
|
|
||||||
}
|
}
|
||||||
|
@ -1,8 +1,8 @@
|
|||||||
package com.baeldung.boot.jersey.controllers;
|
package com.baeldung.boot.jersey.controllers;
|
||||||
|
|
||||||
import static org.assertj.core.api.AssertionsForClassTypes.assertThat;
|
import javax.ws.rs.core.Response;
|
||||||
|
|
||||||
import javax.xml.ws.Response;
|
import static org.assertj.core.api.AssertionsForClassTypes.assertThat;
|
||||||
|
|
||||||
import org.junit.jupiter.api.Test;
|
import org.junit.jupiter.api.Test;
|
||||||
import org.junit.jupiter.api.extension.ExtendWith;
|
import org.junit.jupiter.api.extension.ExtendWith;
|
||||||
|
Loading…
x
Reference in New Issue
Block a user