This is an automated email from the ASF dual-hosted git repository.
jamesnetherton pushed a commit to branch 3.8.x
in repository https://gitbox.apache.org/repos/asf/camel-quarkus.git
The following commit(s) were added to refs/heads/3.8.x by this push:
new 85456cac15 [Tests] FTP: Use restrictions to bypass cert setup issues
85456cac15 is described below
commit 85456cac15e80a90b6a4af319e02872cc204f819
Author: Andrej Vano <[email protected]>
AuthorDate: Tue Sep 3 11:44:45 2024 +0200
[Tests] FTP: Use restrictions to bypass cert setup issues
---
.../java/org/apache/camel/quarkus/component/ftp/it/FtpTest.java | 2 +-
.../java/org/apache/camel/quarkus/component/ftps/it/FtpsTest.java | 2 +-
.../apache/camel/quarkus/component/ftps/it/FtpsTestResource.java | 6 ------
3 files changed, 2 insertions(+), 8 deletions(-)
diff --git
a/integration-tests/ftp/src/test/java/org/apache/camel/quarkus/component/ftp/it/FtpTest.java
b/integration-tests/ftp/src/test/java/org/apache/camel/quarkus/component/ftp/it/FtpTest.java
index 88e4cd4083..c6a5b91d1d 100644
---
a/integration-tests/ftp/src/test/java/org/apache/camel/quarkus/component/ftp/it/FtpTest.java
+++
b/integration-tests/ftp/src/test/java/org/apache/camel/quarkus/component/ftp/it/FtpTest.java
@@ -25,7 +25,7 @@ import org.junit.jupiter.api.Test;
import static org.hamcrest.CoreMatchers.is;
@QuarkusTest
-@QuarkusTestResource(FtpTestResource.class)
+@QuarkusTestResource(value = FtpTestResource.class, restrictToAnnotatedClass =
true)
class FtpTest {
@Test
public void testFtpComponent() {
diff --git
a/integration-tests/ftp/src/test/java/org/apache/camel/quarkus/component/ftps/it/FtpsTest.java
b/integration-tests/ftp/src/test/java/org/apache/camel/quarkus/component/ftps/it/FtpsTest.java
index 753990d8fb..673aa66eed 100644
---
a/integration-tests/ftp/src/test/java/org/apache/camel/quarkus/component/ftps/it/FtpsTest.java
+++
b/integration-tests/ftp/src/test/java/org/apache/camel/quarkus/component/ftps/it/FtpsTest.java
@@ -34,7 +34,7 @@ import static org.hamcrest.CoreMatchers.is;
Format.PKCS12 }, password = "password") })
@Disabled //https://github.com/apache/camel-quarkus/issues/4089
@QuarkusTest
-@QuarkusTestResource(FtpsTestResource.class)
+@QuarkusTestResource(value = FtpsTestResource.class, restrictToAnnotatedClass
= true)
class FtpsTest {
static final String CERTIFICATE_KEYSTORE_FILE =
CertificatesUtil.keystoreFile("ftp", "p12");
diff --git
a/integration-tests/ftp/src/test/java/org/apache/camel/quarkus/component/ftps/it/FtpsTestResource.java
b/integration-tests/ftp/src/test/java/org/apache/camel/quarkus/component/ftps/it/FtpsTestResource.java
index 9181cb736d..ac4a4be318 100644
---
a/integration-tests/ftp/src/test/java/org/apache/camel/quarkus/component/ftps/it/FtpsTestResource.java
+++
b/integration-tests/ftp/src/test/java/org/apache/camel/quarkus/component/ftps/it/FtpsTestResource.java
@@ -30,12 +30,6 @@ public class FtpsTestResource extends FtpTestResource {
@Override
protected ListenerFactory createListenerFactory(int port) {
- //do not create a factory if keystore file does not exists
- //because the test is disabled, but the test resource is "activated",
this condition prevents the failure
- //for the FtpTest
- if (!Path.of(FtpsTest.CERTIFICATE_KEYSTORE_FILE).toFile().exists()) {
- return null;
- }
SslConfigurationFactory sslConfigFactory = new
SslConfigurationFactory();
sslConfigFactory.setKeystoreFile(Path.of(FtpsTest.CERTIFICATE_KEYSTORE_FILE).toFile());