diff --git a/src/main/java/com/covas/ApplicationScoped/ApplicationRoot.java b/src/main/java/com/covas/ApplicationScoped/ApplicationRoot.java new file mode 100644 index 0000000..732f414 --- /dev/null +++ b/src/main/java/com/covas/ApplicationScoped/ApplicationRoot.java @@ -0,0 +1,9 @@ +package com.covas.ApplicationScoped; + +import javax.ws.rs.ApplicationPath; +import javax.ws.rs.core.Application; + +@ApplicationPath("/api") +public class ApplicationRoot extends Application { + +} diff --git a/src/main/java/com/covas/Resources/UsersRessources.java b/src/main/java/com/covas/Resources/UsersRessources.java index d41be90..9c4f889 100644 --- a/src/main/java/com/covas/Resources/UsersRessources.java +++ b/src/main/java/com/covas/Resources/UsersRessources.java @@ -13,7 +13,7 @@ import org.jboss.logging.Logger; @Produces(MediaType.APPLICATION_JSON) -@Path("/api/users") +@Path("users") public class UsersRessources { private static final Logger LOGGER = Logger.getLogger(UsersRessources.class); @GET diff --git a/src/test/java/com/covas/GreetingResourceTest.java b/src/test/java/com/covas/GreetingResourceTest.java index 7fb3ed3..6ee0982 100644 --- a/src/test/java/com/covas/GreetingResourceTest.java +++ b/src/test/java/com/covas/GreetingResourceTest.java @@ -12,7 +12,7 @@ public class GreetingResourceTest { @Test public void testHelloEndpoint() { given() - .when().get("/hello") + .when().get("/api/hello") .then() .statusCode(200) .body(is("Hello RESTEasy"));