Skip to content

Commit f65cf26

Browse files
laurentgolriggs
authored andcommitted
Remove ReflectiveOperationException from method declaration
1 parent 9d1277b commit f65cf26

File tree

1 file changed

+7
-4
lines changed

1 file changed

+7
-4
lines changed

java/flight/flight-sql-jdbc-driver/src/test/java/org/apache/arrow/driver/jdbc/ITDriverJarValidation.java

Lines changed: 7 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -62,9 +62,12 @@ public class ITDriverJarValidation {
6262
"properties/flight.properties");
6363

6464
// This method is designed to work with Maven failsafe plugin and expects the
65-
// JDBC driver
66-
// jar to be present in the test classpath (instead of the individual classes)
67-
private static JarFile getJdbcJarFile() throws ReflectiveOperationException, IOException {
65+
// JDBC driver jar to be present in the test classpath (instead of the individual classes)
66+
private static JarFile getJdbcJarFile() throws IOException {
67+
// Check if an override has been set
68+
if (JDBC_DRIVER_PATH_OVERRIDE != null) {
69+
return new JarFile(new File(JDBC_DRIVER_PATH_OVERRIDE));
70+
}
6871

6972
//
7073
URL driverClassURL = ITDriverJarValidation.class.getClassLoader()
@@ -83,7 +86,7 @@ private static JarFile getJdbcJarFile() throws ReflectiveOperationException, IOE
8386
public ErrorCollector collector = new ErrorCollector();
8487

8588
@Test
86-
public void validateShadedJar() throws ReflectiveOperationException, IOException {
89+
public void validateShadedJar() throws IOException {
8790
// Validate the content of the jar to enforce all 3rd party dependencies have
8891
// been shaded
8992
try (JarFile jar = getJdbcJarFile()) {

0 commit comments

Comments
 (0)