Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Adds integration tests for postgresql devservices #20640

Conversation

netodevel
Copy link
Contributor

Goal:
Ensure that the devservices feature for postgresql is working correctly;

@quarkus-bot
Copy link

quarkus-bot bot commented Oct 9, 2021

This workflow status is outdated as a new workflow run has been triggered.

Failing Jobs - Building ef35616

Status Name Step Failures Logs Raw logs
✔️ JVM Tests - JDK 11
JVM Tests - JDK 11 Windows Build Failures Logs Raw logs
✔️ JVM Tests - JDK 17

Full information is available in the Build summary check run.

Failures

⚙️ JVM Tests - JDK 11 Windows #

- Failing: integration-tests/postgresql-devservices 

📦 integration-tests/postgresql-devservices

com.example.postgresql.devservice.DevServicePostgresEnableITest.shouldStartPostgresContainer - More details - Source on GitHub

java.lang.RuntimeException: 
java.lang.RuntimeException: io.quarkus.builder.BuildException: Build failure: Build failed due to errors
	[error]: Build step io.quarkus.datasource.deployment.devservices.DevServicesDatasourceProcessor#launchDatabases threw an exception: java.lang.RuntimeException: java.lang.IllegalStateException: Previous attempts to find a Docker environment failed. Will not retry. Please see logs and check configuration

com.example.postgresql.devservice.PersonResourceTest.shouldReturnListPersons - More details - Source on GitHub

java.lang.RuntimeException: 
java.lang.RuntimeException: io.quarkus.builder.BuildException: Build failure: Build failed due to errors
	[error]: Build step io.quarkus.datasource.deployment.devservices.DevServicesDatasourceProcessor#launchDatabases threw an exception: java.lang.RuntimeException: java.lang.IllegalStateException: Previous attempts to find a Docker environment failed. Will not retry. Please see logs and check configuration

@quarkus-bot
Copy link

quarkus-bot bot commented Oct 10, 2021

This workflow status is outdated as a new workflow run has been triggered.

Failing Jobs - Building 3766b72

Status Name Step Failures Logs Raw logs
Devtools Tests - JDK 11 Windows Build Failures Logs Raw logs
✔️ JVM Tests - JDK 11
JVM Tests - JDK 11 Windows Build Failures Logs Raw logs
✔️ JVM Tests - JDK 17

Full information is available in the Build summary check run.

Failures

⚙️ Devtools Tests - JDK 11 Windows #

- Failing: integration-tests/devtools 

📦 integration-tests/devtools

io.quarkus.devtools.codestarts.quarkus.QuarkusCodestartBuildIT.testRunTogetherCodestartsJava line 60 - More details - Source on GitHub

org.opentest4j.AssertionFailedError: 

expected: 0

io.quarkus.devtools.codestarts.quarkus.QuarkusCodestartBuildIT.testRunTogetherCodestartsJava line 60 - More details - Source on GitHub

org.opentest4j.AssertionFailedError: 

expected: 0

⚙️ JVM Tests - JDK 11 Windows #

- Failing: integration-tests/postgresql-devservices 

📦 integration-tests/postgresql-devservices

com.example.postgresql.devservice.DevServicePostgresEnableITest.shouldStartPostgresContainer - More details - Source on GitHub

java.lang.RuntimeException: 
java.lang.RuntimeException: io.quarkus.builder.BuildException: Build failure: Build failed due to errors
	[error]: Build step io.quarkus.datasource.deployment.devservices.DevServicesDatasourceProcessor#launchDatabases threw an exception: java.lang.RuntimeException: java.lang.IllegalStateException: Previous attempts to find a Docker environment failed. Will not retry. Please see logs and check configuration

com.example.postgresql.devservice.PersonResourceTest.shouldReturnListPersons - More details - Source on GitHub

java.lang.RuntimeException: 
java.lang.RuntimeException: io.quarkus.builder.BuildException: Build failure: Build failed due to errors
	[error]: Build step io.quarkus.datasource.deployment.devservices.DevServicesDatasourceProcessor#launchDatabases threw an exception: java.lang.RuntimeException: java.lang.IllegalStateException: Previous attempts to find a Docker environment failed. Will not retry. Please see logs and check configuration

Copy link
Member

@gsmet gsmet left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

@stuartwdouglas I would be interested in your take on this. I think if we go this way, we need to be consistent but I'm not sure if we should just create a big module with all of them or having separate modules.

Let's try to decide how we want things before making further progress.

integration-tests/pom.xml Outdated Show resolved Hide resolved
integration-tests/pom.xml Outdated Show resolved Hide resolved
@netodevel
Copy link
Contributor Author

@gsmet
Thanks for the answer.
To help with your decision, I had already contributed an integrated test for redis devservices. (#17133)
as soon as you make the decision I adjust the code review points.

note:
if we decide to have multiple modules, we'll need somewhere for the SocketKit class to have no duplication;

</exclusions>
</dependency>
</dependencies>
<build>
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This module should be configured to skip tests unless -DstartContainers is present.

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

@stuartwdouglas, I googled how to configure maven to skip test from a conditional, but I didn't find anything, do you have any tips for me?

Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Like this: https://github.com/stuartwdouglas/quarkus/blob/f4525048cf1616a1c46cf74889f5c28d3739f589/integration-tests/hibernate-orm-tenancy/datasource/pom.xml#L152

Basically skip the tests by default, then have a profile that changes skip to false if start-containers is set. That example also manually starts the containers, which you don't need.

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

@stuartwdouglas, thanks for tip.

Done.

@quarkus-bot
Copy link

quarkus-bot bot commented Oct 12, 2021

This workflow status is outdated as a new workflow run has been triggered.

Failing Jobs - Building 6a7a774

Status Name Step Failures Logs Raw logs
✔️ JVM Tests - JDK 11
JVM Tests - JDK 11 Windows Build Failures Logs Raw logs
✔️ JVM Tests - JDK 17

Full information is available in the Build summary check run.

Failures

⚙️ JVM Tests - JDK 11 Windows #

- Failing: integration-tests/devservices-postgresql 

📦 integration-tests/devservices-postgresql

com.example.postgresql.devservice.DevServicePostgresEnableITest.shouldStartPostgresContainer - More details - Source on GitHub

java.lang.RuntimeException: 
java.lang.RuntimeException: io.quarkus.builder.BuildException: Build failure: Build failed due to errors
	[error]: Build step io.quarkus.datasource.deployment.devservices.DevServicesDatasourceProcessor#launchDatabases threw an exception: java.lang.RuntimeException: java.lang.IllegalStateException: Previous attempts to find a Docker environment failed. Will not retry. Please see logs and check configuration

com.example.postgresql.devservice.PersonResourceTest.shouldReturnListPersons - More details - Source on GitHub

java.lang.RuntimeException: 
java.lang.RuntimeException: io.quarkus.builder.BuildException: Build failure: Build failed due to errors
	[error]: Build step io.quarkus.datasource.deployment.devservices.DevServicesDatasourceProcessor#launchDatabases threw an exception: java.lang.RuntimeException: java.lang.IllegalStateException: Previous attempts to find a Docker environment failed. Will not retry. Please see logs and check configuration

* Fixs maven module to run tests
* Fixs formatting
* Fixs modules name
* Adds configuration to skip tests by default
@netodevel netodevel force-pushed the feature/netodevel-postgresql-devservices branch from 99e6c6e to 43eb305 Compare October 13, 2021 00:51
@netodevel
Copy link
Contributor Author

@gsmet, @stuartwdouglas,
Hi guys,
Any feedback about this PR?

@gsmet
Copy link
Member

gsmet commented Jan 12, 2022

Sorry, we haven't have the time to have a proper look at this. @stuartwdouglas is on PTO and I'd like to discuss this with him when he's back. Assigning it to me so that I can keep track of this thing.

@gsmet gsmet self-assigned this Jan 12, 2022
@gsmet gsmet added the triage/needs-rebase This PR needs to be rebased first because it has merge conflicts label Feb 4, 2023
@netodevel netodevel closed this Jul 28, 2024
@quarkus-bot quarkus-bot bot added the triage/invalid This doesn't seem right label Jul 28, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
triage/invalid This doesn't seem right triage/needs-rebase This PR needs to be rebased first because it has merge conflicts
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants