Skip to content

Conversation

@IdrissRio
Copy link
Contributor

@IdrissRio IdrissRio commented Oct 9, 2025

This PR adds 5 new integration tests:

  • Multi-module projects with mixed Java versions
  • Java 8 targets requiring Java 11+ dependencies
  • --add-exports module flag detection
  • Java 16 targets with Java 17+ JDK
  • Execution-specific compiler release selection

@IdrissRio IdrissRio added the depends on internal PR This PR should only be merged in sync with an internal Semmle PR label Oct 9, 2025
@github-actions github-actions bot added the Java label Oct 9, 2025
@IdrissRio IdrissRio force-pushed the idrissrio/java-jdk branch 7 times, most recently from 319cd47 to 2840662 Compare October 22, 2025 09:05
@IdrissRio IdrissRio force-pushed the idrissrio/java-jdk branch 3 times, most recently from 7595248 to f708313 Compare October 30, 2025 09:04
@IdrissRio IdrissRio marked this pull request as ready for review November 3, 2025 15:02
@IdrissRio IdrissRio requested a review from a team as a code owner November 3, 2025 15:02
Copilot AI review requested due to automatic review settings November 3, 2025 15:02
Copy link
Contributor

Copilot AI left a comment

Choose a reason for hiding this comment

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

Pull Request Overview

This PR introduces new integration tests for Maven-based Java projects that verify the handling of different Java version configurations and compilation scenarios. The tests ensure that CodeQL's database creation works correctly across various Java version setups.

Key changes:

  • Added four new Maven integration test projects to validate Java version handling
  • Created test cases for multimodule projects with different Java versions per module, module flags (--add-exports), execution-specific Java versions, and Java 8 projects with Java 11+ dependencies

Reviewed Changes

Copilot reviewed 25 out of 25 changed files in this pull request and generated 1 comment.

Show a summary per file
File Description
maven-multimodule-test-java-version/* Tests a Maven multimodule project where parent uses Java 17 and test-module uses Java 21 with pattern matching features
maven-java8-java11-dependency/* Tests a Java 8 project that depends on TestNG 7.7.0, which requires Java 11+
maven-java16-with-higher-jdk/* Tests a Java 16 project using records that should compile when only Java 17+ is available
maven-execution-specific-java-version/* Tests a project with different Java versions per execution (Java 11 for main, Java 17 for test code)
maven-add-exports-module-flags/* Tests a project using --add-exports flags to access JDK compiler internals

💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.

import java.util.List;

/**
* Simple class using Java 16 features (e.g.,records).
Copy link

Copilot AI Nov 3, 2025

Choose a reason for hiding this comment

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

Missing space after comma in 'e.g.,records'. Should be 'e.g., records' with a space after the comma.

Suggested change
* Simple class using Java 16 features (e.g.,records).
* Simple class using Java 16 features (e.g., records).

Copilot uses AI. Check for mistakes.
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

depends on internal PR This PR should only be merged in sync with an internal Semmle PR Java

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants