This is an automated email from the ASF dual-hosted git repository.

fmariani pushed a commit to branch main
in repository https://gitbox.apache.org/repos/asf/camel.git


The following commit(s) were added to refs/heads/main by this push:
     new 5ef071b08c18 Speed up tests on the CI
5ef071b08c18 is described below

commit 5ef071b08c18d8d13f6b224cf88e00095cdb5e2f
Author: Croway <[email protected]>
AuthorDate: Mon Feb 9 11:07:42 2026 +0100

    Speed up tests on the CI
---
 Jenkinsfile                                        |   2 +-
 Jenkinsfile.jbangtest                              |   1 +
 .../component/kserve/it/KServeEndpointIT.java      |   3 +
 .../camel/component/as2/api/AS2MessageTest.java    | 160 ++-------------------
 .../apache/camel/service/lra/LRAFailuresIT.java    |   4 +-
 test-infra/camel-test-infra-cli/pom.xml            |  31 +++-
 .../camel/test/infra/cli/it/CliConfigITCase.java   |   9 --
 7 files changed, 47 insertions(+), 163 deletions(-)

diff --git a/Jenkinsfile b/Jenkinsfile
index 1f735db94b1f..93625d81be1c 100644
--- a/Jenkinsfile
+++ b/Jenkinsfile
@@ -135,7 +135,7 @@ pipeline {
                         steps {
                             echo "Do Build and test for 
${PLATFORM}-${JDK_NAME}"
                             sh 'java -version'
-                            timeout(unit: 'HOURS', time: 7) {
+                            timeout(unit: 'MINUTES', time: 450) {
                                 script {
                                     if ("${PLATFORM}" == "ubuntu-avx") {
                                         if ("${JDK_NAME}" == "jdk_21_latest") {
diff --git a/Jenkinsfile.jbangtest b/Jenkinsfile.jbangtest
index c59f45827f75..0bd01d50f7e1 100644
--- a/Jenkinsfile.jbangtest
+++ b/Jenkinsfile.jbangtest
@@ -65,6 +65,7 @@ pipeline {
             }
             steps {
                 sh "./mvnw $MAVEN_PARAMS -Pdeploy,apache-snapshots -Dquickly 
clean"
+                sh "./mvnw $MAVEN_PARAMS -f 
test-infra/camel-test-infra-cli/pom.xml -Pjbang-it-test"
                 sh "./mvnw $MAVEN_PARAMS -f 
dsl/camel-jbang/camel-jbang-it/pom.xml -Pjbang-it-test"
             }
             post {
diff --git 
a/components/camel-ai/camel-kserve/src/test/java/org/apache/camel/component/kserve/it/KServeEndpointIT.java
 
b/components/camel-ai/camel-kserve/src/test/java/org/apache/camel/component/kserve/it/KServeEndpointIT.java
index 4bfde3610873..d46521548d3a 100644
--- 
a/components/camel-ai/camel-kserve/src/test/java/org/apache/camel/component/kserve/it/KServeEndpointIT.java
+++ 
b/components/camel-ai/camel-kserve/src/test/java/org/apache/camel/component/kserve/it/KServeEndpointIT.java
@@ -29,9 +29,12 @@ import org.apache.camel.RoutesBuilder;
 import org.apache.camel.builder.RouteBuilder;
 import org.apache.camel.component.kserve.KServeConstants;
 import org.junit.jupiter.api.Test;
+import org.junit.jupiter.api.condition.DisabledIfSystemProperty;
 
 import static org.junit.jupiter.api.Assertions.assertEquals;
 
+@DisabledIfSystemProperty(named = "ci.env.name", matches = ".*",
+                          disabledReason = "Requires too much network 
resources (15GB Docker image!!!)")
 class KServeEndpointIT extends KServeITSupport {
 
     private static final String TEST_MODEL = "simple";
diff --git 
a/components/camel-as2/camel-as2-api/src/test/java/org/apache/camel/component/as2/api/AS2MessageTest.java
 
b/components/camel-as2/camel-as2-api/src/test/java/org/apache/camel/component/as2/api/AS2MessageTest.java
index 7e68bd233fe1..535843106e59 100644
--- 
a/components/camel-as2/camel-as2-api/src/test/java/org/apache/camel/component/as2/api/AS2MessageTest.java
+++ 
b/components/camel-as2/camel-as2-api/src/test/java/org/apache/camel/component/as2/api/AS2MessageTest.java
@@ -21,12 +21,12 @@ import java.io.IOException;
 import java.io.InputStream;
 import java.net.URISyntaxException;
 import java.nio.charset.StandardCharsets;
-import java.security.Security;
 import java.security.cert.Certificate;
 import java.security.cert.X509Certificate;
 import java.util.Arrays;
 import java.util.HashMap;
 import java.util.Map;
+import java.util.stream.Stream;
 
 import org.apache.camel.component.as2.api.entity.AS2DispositionModifier;
 import org.apache.camel.component.as2.api.entity.AS2DispositionType;
@@ -61,23 +61,12 @@ import 
org.apache.hc.core5.http.message.BasicClassicHttpRequest;
 import org.apache.hc.core5.http.message.BasicHttpResponse;
 import org.apache.hc.core5.http.protocol.HttpContext;
 import org.apache.hc.core5.http.protocol.HttpCoreContext;
-import org.bouncycastle.asn1.ASN1EncodableVector;
-import org.bouncycastle.asn1.cms.AttributeTable;
-import org.bouncycastle.asn1.cms.IssuerAndSerialNumber;
-import org.bouncycastle.asn1.smime.SMIMECapabilitiesAttribute;
-import org.bouncycastle.asn1.smime.SMIMECapability;
-import org.bouncycastle.asn1.smime.SMIMECapabilityVector;
-import org.bouncycastle.asn1.smime.SMIMEEncryptionKeyPreferenceAttribute;
-import org.bouncycastle.asn1.x500.X500Name;
-import org.bouncycastle.cert.jcajce.JcaCertStore;
-import org.bouncycastle.cms.jcajce.JcaSimpleSignerInfoGeneratorBuilder;
 import org.bouncycastle.cms.jcajce.ZlibExpanderProvider;
-import org.bouncycastle.jce.provider.BouncyCastleProvider;
 import org.junit.jupiter.api.BeforeAll;
-import org.junit.jupiter.api.BeforeEach;
 import org.junit.jupiter.api.Test;
 import org.junit.jupiter.params.ParameterizedTest;
 import org.junit.jupiter.params.provider.CsvSource;
+import org.junit.jupiter.params.provider.MethodSource;
 import org.slf4j.Logger;
 import org.slf4j.LoggerFactory;
 
@@ -117,46 +106,6 @@ public class AS2MessageTest extends AS2MessageTestBase {
         });
     }
 
-    @BeforeEach
-    public void setUp() throws Exception {
-        Security.addProvider(new BouncyCastleProvider());
-
-        // Create and populate certificate store.
-        JcaCertStore certs = new JcaCertStore(certList);
-
-        // Create capabilities vector
-        SMIMECapabilityVector capabilities = new SMIMECapabilityVector();
-        capabilities.addCapability(SMIMECapability.dES_EDE3_CBC);
-        capabilities.addCapability(SMIMECapability.rC2_CBC, 128);
-        capabilities.addCapability(SMIMECapability.dES_CBC);
-
-        // Create signing attributes
-        ASN1EncodableVector attributes = new ASN1EncodableVector();
-        attributes.add(new SMIMEEncryptionKeyPreferenceAttribute(
-                new IssuerAndSerialNumber(
-                        new X500Name(signingCert.getIssuerDN().getName()), 
signingCert.getSerialNumber())));
-        attributes.add(new SMIMECapabilitiesAttribute(capabilities));
-
-        for (String signingAlgorithmName : AS2SignedDataGenerator
-                
.getSupportedSignatureAlgorithmNamesForKey(signingKP.getPrivate())) {
-            try {
-                this.gen = new AS2SignedDataGenerator();
-                this.gen.addSignerInfoGenerator(new 
JcaSimpleSignerInfoGeneratorBuilder().setProvider("BC")
-                        .setSignedAttributeGenerator(new 
AttributeTable(attributes))
-                        .build(signingAlgorithmName, signingKP.getPrivate(), 
signingCert));
-                this.gen.addCertificates(certs);
-                break;
-            } catch (Exception e) {
-                this.gen = null;
-                continue;
-            }
-        }
-
-        if (this.gen == null) {
-            throw new Exception("failed to create signing generator");
-        }
-    }
-
     @ParameterizedTest
     @CsvSource({
             "true,false,false", "true,false,true", "true,true,false", 
"true,true,true" })
@@ -217,104 +166,17 @@ public class AS2MessageTest extends AS2MessageTestBase {
         assertFalse(signatureEntity.isMainBody(), "First mime type set as main 
body of request");
     }
 
-    @Test
-    public void aes128CbcEnvelopedMessageTest() throws Exception {
-        envelopedMessageTest(AS2EncryptionAlgorithm.AES128_CBC);
-    }
-
-    @Test
-    public void aes192CbcEnvelopedMessageTest() throws Exception {
-        envelopedMessageTest(AS2EncryptionAlgorithm.AES192_CBC);
-    }
-
-    @Test
-    public void aes256CbcEnvelopedMessageTest() throws Exception {
-        envelopedMessageTest(AS2EncryptionAlgorithm.AES256_CBC);
-    }
-
-    @Test
-    public void aes128CcmEnvelopedMessageTest() throws Exception {
-        envelopedMessageTest(AS2EncryptionAlgorithm.AES128_CCM);
+    static Stream<AS2EncryptionAlgorithm> encryptionAlgorithms() {
+        return Stream.of(
+                AS2EncryptionAlgorithm.AES128_CBC,
+                AS2EncryptionAlgorithm.AES256_GCM,
+                AS2EncryptionAlgorithm.DES_EDE3_CBC);
     }
 
-    @Test
-    public void aes192CcmEnvelopedMessageTest() throws Exception {
-        envelopedMessageTest(AS2EncryptionAlgorithm.AES192_CCM);
-    }
-
-    @Test
-    public void aes256CcmEnvelopedMessageTest() throws Exception {
-        envelopedMessageTest(AS2EncryptionAlgorithm.AES256_CCM);
-    }
-
-    @Test
-    public void aes128GcmEnvelopedMessageTest() throws Exception {
-        envelopedMessageTest(AS2EncryptionAlgorithm.AES128_GCM);
-    }
-
-    @Test
-    public void aes192GcmEnvelopedMessageTest() throws Exception {
-        envelopedMessageTest(AS2EncryptionAlgorithm.AES192_GCM);
-    }
-
-    @Test
-    public void aes256GcmEnvelopedMessageTest() throws Exception {
-        envelopedMessageTest(AS2EncryptionAlgorithm.AES256_GCM);
-    }
-
-    @Test
-    public void camellia128CbcEnvelopedMessageTest() throws Exception {
-        envelopedMessageTest(AS2EncryptionAlgorithm.CAMELLIA128_CBC);
-    }
-
-    @Test
-    public void camellia192CbcEnvelopedMessageTest() throws Exception {
-        envelopedMessageTest(AS2EncryptionAlgorithm.CAMELLIA192_CBC);
-    }
-
-    @Test
-    public void camellia256CbcEnvelopedMessageTest() throws Exception {
-        envelopedMessageTest(AS2EncryptionAlgorithm.CAMELLIA256_CBC);
-    }
-
-    @Test
-    public void cast5CbcEnvelopedMessageTest() throws Exception {
-        envelopedMessageTest(AS2EncryptionAlgorithm.CAST5_CBC);
-    }
-
-    @Test
-    public void desCbcEnvelopedMessageTest() throws Exception {
-        envelopedMessageTest(AS2EncryptionAlgorithm.DES_CBC);
-    }
-
-    @Test
-    public void desEde3CbcEnvelopedMessageTest() throws Exception {
-        envelopedMessageTest(AS2EncryptionAlgorithm.DES_EDE3_CBC);
-    }
-
-    @Test
-    public void cost28147GcfbEnvelopedMessageTest() throws Exception {
-        envelopedMessageTest(AS2EncryptionAlgorithm.GOST28147_GCFB);
-    }
-
-    @Test
-    public void ideaCbcEnvelopedMessageTest() throws Exception {
-        envelopedMessageTest(AS2EncryptionAlgorithm.IDEA_CBC);
-    }
-
-    @Test
-    public void rc2CbcEnvelopedMessageTest() throws Exception {
-        envelopedMessageTest(AS2EncryptionAlgorithm.RC2_CBC);
-    }
-
-    @Test
-    public void rc4EnvelopedMessageTest() throws Exception {
-        envelopedMessageTest(AS2EncryptionAlgorithm.RC4);
-    }
-
-    @Test
-    public void seedCbcEnvelopedMessageTest() throws Exception {
-        envelopedMessageTest(AS2EncryptionAlgorithm.SEED_CBC);
+    @ParameterizedTest
+    @MethodSource("encryptionAlgorithms")
+    public void envelopedMessageEncryptionTest(AS2EncryptionAlgorithm 
algorithm) throws Exception {
+        envelopedMessageTest(algorithm);
     }
 
     public void envelopedMessageTest(AS2EncryptionAlgorithm 
encryptionAlgorithm) throws Exception {
diff --git 
a/components/camel-lra/src/test/java/org/apache/camel/service/lra/LRAFailuresIT.java
 
b/components/camel-lra/src/test/java/org/apache/camel/service/lra/LRAFailuresIT.java
index 69b792aa9170..d54e663b7300 100644
--- 
a/components/camel-lra/src/test/java/org/apache/camel/service/lra/LRAFailuresIT.java
+++ 
b/components/camel-lra/src/test/java/org/apache/camel/service/lra/LRAFailuresIT.java
@@ -33,7 +33,7 @@ public class LRAFailuresIT extends AbstractLRATestSupport {
 
         MockEndpoint compensate = getMockEndpoint("mock:compensate");
         compensate.expectedMessageCount(1);
-        compensate.setResultWaitTime(300000);
+        compensate.setResultWaitTime(20000);
 
         sendBody("direct:saga-compensate", "hello");
 
@@ -46,7 +46,7 @@ public class LRAFailuresIT extends AbstractLRATestSupport {
 
         MockEndpoint complete = getMockEndpoint("mock:complete");
         complete.expectedMessageCount(1);
-        complete.setResultWaitTime(300000);
+        complete.setResultWaitTime(20000);
 
         MockEndpoint end = getMockEndpoint("mock:end");
         end.expectedBodiesReceived("hello");
diff --git a/test-infra/camel-test-infra-cli/pom.xml 
b/test-infra/camel-test-infra-cli/pom.xml
index 7f77376b8e63..6c6d26e15679 100644
--- a/test-infra/camel-test-infra-cli/pom.xml
+++ b/test-infra/camel-test-infra-cli/pom.xml
@@ -31,7 +31,7 @@
     <name>Camel :: Test Infra :: Cli (Camel JBang)</name>
 
     <properties>
-        <maven.test.skip>false</maven.test.skip>
+        <skipTests>true</skipTests>
     </properties>
 
     <dependencies>
@@ -87,8 +87,8 @@
             <version>${logback-version}</version>
             <scope>test</scope>
         </dependency>
-
     </dependencies>
+
     <build>
         <plugins>
             <plugin>
@@ -153,5 +153,32 @@
                 </plugins>
             </build>
         </profile>
+        <profile>
+            <id>jbang-it-test</id>
+            <activation>
+                <activeByDefault>false</activeByDefault>
+                <property>
+                    <name>jbang-it-test</name>
+                </property>
+            </activation>
+            <properties>
+                <skipTests>false</skipTests>
+            </properties>
+            <build>
+                <plugins>
+                    <plugin>
+                        <groupId>org.apache.maven.plugins</groupId>
+                        <artifactId>maven-failsafe-plugin</artifactId>
+                        <executions>
+                            <execution>
+                                <goals>
+                                    <goal>integration-test</goal>
+                                </goals>
+                            </execution>
+                        </executions>
+                    </plugin>
+                </plugins>
+            </build>
+        </profile>
     </profiles>
 </project>
diff --git 
a/test-infra/camel-test-infra-cli/src/test/java/org/apache/camel/test/infra/cli/it/CliConfigITCase.java
 
b/test-infra/camel-test-infra-cli/src/test/java/org/apache/camel/test/infra/cli/it/CliConfigITCase.java
index cc0d6cb0bfc3..01a727feca69 100644
--- 
a/test-infra/camel-test-infra-cli/src/test/java/org/apache/camel/test/infra/cli/it/CliConfigITCase.java
+++ 
b/test-infra/camel-test-infra-cli/src/test/java/org/apache/camel/test/infra/cli/it/CliConfigITCase.java
@@ -48,15 +48,6 @@ public class CliConfigITCase extends AbstractTestSupport {
         });
     }
 
-    @Test
-    @SetSystemProperty(key = "cli.service.execute.version", value = "4.14.2")
-    public void setJBangAndCamelVersionTest() {
-        execute(cliService -> {
-            String version = cliService.version();
-            Assertions.assertEquals("4.14.2", version, "Check specific Camel 
JBang and Camel version");
-        });
-    }
-
     @Test
     @SetSystemProperty(key = "cli.service.branch", value = "camel-4.4.x")
     public void setBranchTest() {

Reply via email to