Skip to content

Commit

Permalink
Raise OpenShiftTodoDemoIT startup timetous to fix flakiness
Browse files Browse the repository at this point in the history
  • Loading branch information
michalvavrik authored and rsvoboda committed Dec 18, 2024
1 parent 995fa34 commit c2081ad
Show file tree
Hide file tree
Showing 2 changed files with 11 additions and 6 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -31,29 +31,29 @@ public class TodoDemoIT {
.withProperty("PGDATA", "/tmp/psql");

@GitRepositoryQuarkusApplication(repo = REPO, mavenArgs = DEFAULT_ARGS + UBER)
static final RestService app = new RestService()
static final RestService todoApp = new RestService()
.withProperty("quarkus.datasource.username", database.getUser())
.withProperty("quarkus.datasource.password", database.getPassword())
.withProperty("quarkus.datasource.jdbc.url", database::getJdbcUrl);

@GitRepositoryQuarkusApplication(repo = REPO, artifact = "todo-backend-1.0-SNAPSHOT-runner.jar", mavenArgs = DEFAULT_ARGS
+ UBER)
static final RestService explicit = new RestService()
static final RestService todoExplicitApp = new RestService()
.withProperty("quarkus.datasource.username", database.getUser())
.withProperty("quarkus.datasource.password", database.getPassword())
.withProperty("quarkus.datasource.jdbc.url", database::getJdbcUrl);

@GitRepositoryQuarkusApplication(repo = REPO, artifact = "todo-backend-1.0-SNAPSHOT.jar", mavenArgs = DEFAULT_ARGS + UBER
+ NO_SUFFIX)
static final RestService unsuffixed = new RestService()
static final RestService todoUnsuffixedApp = new RestService()
.withProperty("quarkus.datasource.username", database.getUser())
.withProperty("quarkus.datasource.password", database.getPassword())
.withProperty("quarkus.datasource.jdbc.url", database::getJdbcUrl);

@Test
@Order(1)
public void verify() {
app.given()
todoApp.given()
.contentType(ContentType.JSON)
.body("{\"title\": \"Use Quarkus\", \"order\": 1, \"url\": \"https://quarkus.io\"}")
.post("/api")
Expand All @@ -64,7 +64,7 @@ public void verify() {
@Test
@Order(2)
public void verifyExplicitArtifact() {
explicit.given()
todoExplicitApp.given()
.accept(ContentType.JSON)
.get("/api/1")
.then()
Expand All @@ -75,7 +75,7 @@ public void verifyExplicitArtifact() {
@Test
@Order(3)
public void verifyNoSuffix() {
unsuffixed.given()
todoUnsuffixedApp.given()
.pathParam("id", 1)
.delete("/api/{id}")
.then()
Expand Down
Original file line number Diff line number Diff line change
@@ -1,2 +1,7 @@
ts.appuberjar.openshift.template=/uber-jar-quarkus-s2i-source-build-template.yml
ts.database.openshift.use-internal-service-as-url=true

# extend TodoDemoIT startup timeouts because the test was flaky with 5 minutes timeout
ts.todoApp.startup.timeout=9m
ts.todoExplicitApp.startup.timeout=9m
ts.todoUnsuffixedApp.startup.timeout=9m

0 comments on commit c2081ad

Please sign in to comment.