Pankraz76 commented on code in PR #2373:
URL: https://github.com/apache/maven/pull/2373#discussion_r2107764271


##########
impl/maven-impl/src/test/java/org/apache/maven/impl/model/DefaultModelInterpolatorTest.java:
##########
@@ -592,4 +611,376 @@ public Path findMandatoryRoot(Path basedir) {
             }
         };
     }
+
+    @Test
+    @DisabledOnOs(WINDOWS)

Review Comment:
   testProjectPropertyExtractionOnWindows



##########
impl/maven-impl/src/test/java/org/apache/maven/impl/model/DefaultModelInterpolatorTest.java:
##########
@@ -592,4 +611,376 @@ public Path findMandatoryRoot(Path basedir) {
             }
         };
     }
+
+    @Test
+    @DisabledOnOs(WINDOWS)
+    @EnabledOnOs({ LINUX, MAC }) // TODO: tryout removal after happy CI
+    void testProjectPropertyExtraction() throws Exception {
+        Path projectDir = Paths.get("/test/path");
+        Model model = Model.newBuilder().build();
+        DefaultModelInterpolator interpolator = new DefaultModelInterpolator(
+                new DefaultPathTranslator(),
+                new DefaultUrlNormalizer(),
+                new DefaultRootLocator(),
+                new DefaultInterpolator());
+        assertEquals("/test/path", interpolator.projectProperty(model, 
projectDir, "basedir", false));
+        assertNull(interpolator.projectProperty(model, projectDir, 
"nonexistent.property", false));
+    }
+
+    @Test
+    void testWindowsPathHandling() {
+        FileSystem fs = Jimfs.newFileSystem(Configuration.windows());

Review Comment:
   yes should give checkstyle method pattern for this:
   
   <img width="1120" alt="image" 
src="https://github.com/user-attachments/assets/0f16a8ec-2fbf-4cc0-bdac-7cc922f3165b";
 />
   



-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: issues-unsubscr...@maven.apache.org

For queries about this service, please contact Infrastructure at:
us...@infra.apache.org

Reply via email to