Skip to content

Commit

Permalink
Fix TUs
Browse files Browse the repository at this point in the history
  • Loading branch information
Thierry Boileau committed Jan 28, 2025
1 parent d0b3159 commit 0886bf4
Showing 1 changed file with 4 additions and 0 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -14,6 +14,7 @@
import org.junit.jupiter.api.Test;
import org.restlet.data.MediaType;
import org.restlet.data.Protocol;
import org.restlet.engine.Engine;
import org.restlet.representation.Representation;
import org.restlet.resource.ClientResource;
import org.restlet.resource.Get;
Expand Down Expand Up @@ -69,6 +70,8 @@ public String hello() {

@BeforeEach
protected void setUpEach() throws Exception {
Engine.register();
Engine.clearThreadLocalVariables();
this.component = new Component();
this.component.getServers().add(Protocol.HTTP, TEST_PORT);
this.component.getDefaultHost().attach("/api", new WebApiApplication());
Expand All @@ -78,6 +81,7 @@ protected void setUpEach() throws Exception {

@AfterEach
protected void tearDownEach() throws Exception {
Engine.clearThreadLocalVariables();
this.component.stop();
}

Expand Down

0 comments on commit 0886bf4

Please sign in to comment.