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

Croway pushed a commit to branch camel-4.18.6-recipes
in repository https://gitbox.apache.org/repos/asf/camel-upgrade-recipes.git


The following commit(s) were added to refs/heads/camel-4.18.6-recipes by this 
push:
     new c58bb02  Enable the semantic artifact tests now that Camel 4.24.0 is 
released
c58bb02 is described below

commit c58bb02b323a1cef85e252004a2f4c73aacc06f8
Author: croway <[email protected]>
AuthorDate: Thu Dec 3 14:48:04 2026 +0100

    Enable the semantic artifact tests now that Camel 4.24.0 is released
    
    camel-semantic-wolf-defender and camel-semantic-typesafe-ai are on Maven
    Central, so the two tests disabled while the vote was open can run, and
    the release note saying so goes.
    
    addSemanticTypesafeAiWhenAdapterIsUsed had never run and did not pass:
    with onlyIfUsing, AddDependency only counts Java files that are in a
    source set, as every file of a real Maven project is, and the fixture used
    a bare java() source. The fixture now uses srcMainJava, and the expected
    pom lists the new dependency first, where AddDependency sorts it.
    semanticTypesafeAiNotAddedWithoutAdapter had the same bare source, so it
    passed whatever the recipe did; it uses srcMainJava too.
---
 .../apache/camel/upgrade/CamelUpdate424Test.java    | 21 ++++++++++-----------
 release_notes.adoc                                  |  2 --
 2 files changed, 10 insertions(+), 13 deletions(-)

diff --git 
a/camel-upgrade-recipes/src/test/java/org/apache/camel/upgrade/CamelUpdate424Test.java
 
b/camel-upgrade-recipes/src/test/java/org/apache/camel/upgrade/CamelUpdate424Test.java
index ecfcd03..4b2c492 100644
--- 
a/camel-upgrade-recipes/src/test/java/org/apache/camel/upgrade/CamelUpdate424Test.java
+++ 
b/camel-upgrade-recipes/src/test/java/org/apache/camel/upgrade/CamelUpdate424Test.java
@@ -16,7 +16,6 @@
  */
 package org.apache.camel.upgrade;
 
-import org.junit.jupiter.api.Disabled;
 import org.junit.jupiter.api.Test;
 import org.openrewrite.DocumentExample;
 import org.openrewrite.java.JavaParser;
@@ -27,6 +26,7 @@ import org.openrewrite.test.TypeValidation;
 
 import static org.openrewrite.java.Assertions.java;
 import static org.openrewrite.java.Assertions.mavenProject;
+import static org.openrewrite.java.Assertions.srcMainJava;
 import static org.openrewrite.maven.Assertions.pomXml;
 import static org.openrewrite.properties.Assertions.properties;
 import static org.openrewrite.xml.Assertions.xml;
@@ -541,7 +541,6 @@ public class CamelUpdate424Test implements RewriteTest {
         );
     }
 
-    @Disabled("needs the Camel 4.24.0 artifacts on Maven Central or the 4.24.0 
staging repository")
     @Test
     void migrateWolfDefenderArtifact() {
         //language=xml
@@ -585,7 +584,6 @@ public class CamelUpdate424Test implements RewriteTest {
         );
     }
 
-    @Disabled("needs the Camel 4.24.0 artifacts on Maven Central or the 4.24.0 
staging repository")
     @Test
     void addSemanticTypesafeAiWhenAdapterIsUsed() {
         rewriteRun(
@@ -620,20 +618,21 @@ public class CamelUpdate424Test implements RewriteTest {
                                     <dependencies>
                                         <dependency>
                                             <groupId>org.apache.camel</groupId>
-                                            
<artifactId>camel-typesafe-ai</artifactId>
-                                            <version>4.23.0</version>
+                                            
<artifactId>camel-semantic-typesafe-ai</artifactId>
+                                            <version>4.24.0</version>
                                         </dependency>
                                         <dependency>
                                             <groupId>org.apache.camel</groupId>
-                                            
<artifactId>camel-semantic-typesafe-ai</artifactId>
-                                            <version>4.24.0</version>
+                                            
<artifactId>camel-typesafe-ai</artifactId>
+                                            <version>4.23.0</version>
                                         </dependency>
                                     </dependencies>
                                 </project>
                                 """
                         ),
+                        // AddDependency's onlyIfUsing only counts Java files 
in a source set, as in a real Maven project
                         //language=java
-                        java(
+                        srcMainJava(java(
                                 """
                                 import 
org.apache.camel.component.typesafeai.TypeSafeAiSemanticAdapter;
 
@@ -641,7 +640,7 @@ public class CamelUpdate424Test implements RewriteTest {
                                     TypeSafeAiSemanticAdapter adapter;
                                 }
                                 """
-                        )
+                        ))
                 )
         );
     }
@@ -672,12 +671,12 @@ public class CamelUpdate424Test implements RewriteTest {
                                 """
                         ),
                         //language=java
-                        java(
+                        srcMainJava(java(
                                 """
                                 public class NoExperts {
                                 }
                                 """
-                        )
+                        ))
                 )
         );
     }
diff --git a/release_notes.adoc b/release_notes.adoc
index bfb3fe0..f6e44d1 100644
--- a/release_notes.adoc
+++ b/release_notes.adoc
@@ -57,8 +57,6 @@ The 10 most important items of the guide.
 
 Also automated (see `4.24.yaml`): Undertow EE servlet, Bouncy Castle 1.87 
`LMSigParameters` / `LMOtsParameters` and the `LMSParameterSpec` getters (the 
rest of the removed `org.bouncycastle.pqc.crypto.lms` / `.xmss` low-level API 
and the deprecated LMS and XMSS JCE classes are left to the application, 
following the Bouncy Castle release notes), rocketmq headers, toon 
`lengthMarker`, semantic expert artifacts and audit `decision` calls, backlog 
tracer activity options, Kubernetes client e [...]
 
-NOTE: Camel 4.24.0 was not released yet when these recipes were written (the 
vote was open). `CamelUpdateLatestTestSuite`, which needs the 4.24.0 artifacts, 
was run against the staging repositories of the vote (`orgapachecamel-2096`, 
`orgapachecamel-2097`); the two tests of the semantic artifacts are disabled 
until 4.24.0 is on Maven Central.
-
 === Camel 4.22 LTS migration recipes
 
 New aggregates for the Camel 4.22 LTS line 
(https://github.com/apache/camel-upgrade-recipes/issues/129[#129]), following 
the 4.18 LTS ones: `Camel422LTSMigrationRecipe` (`4.22LTS.yaml` in 
`camel-upgrade-recipes`) and `CamelSpringBoot422LTSMigrationRecipe` 
(`4.22LTS.yaml` in `camel-spring-boot-upgrade-recipes`). They chain every 
version recipe up to `camel422`, then the 4.22.1, 4.22.2 and 4.22.3 patch 
recipes, without the 4.23 changes, and set the Camel and Camel Spring Boot 
versions to 4 [...]

Reply via email to