From c6a8728212d2bae62c5c965da0fbce3bcae28623 Mon Sep 17 00:00:00 2001 From: Christoph Pirkl Date: Thu, 5 Jun 2025 13:17:00 +0200 Subject: [PATCH 1/6] Upgrade dependencies --- .github/workflows/broken_links_checker.yml | 51 +++++++++++++--------- .github/workflows/dependencies_check.yml | 6 +-- dependencies.md | 2 +- doc/changes/changelog.md | 1 + doc/changes/changes_3.0.2.md | 32 ++++++++++++++ pk_generated_parent.pom | 10 ++--- pom.xml | 18 ++++---- 7 files changed, 81 insertions(+), 39 deletions(-) create mode 100644 doc/changes/changes_3.0.2.md diff --git a/.github/workflows/broken_links_checker.yml b/.github/workflows/broken_links_checker.yml index 90488ca..09e4bac 100644 --- a/.github/workflows/broken_links_checker.yml +++ b/.github/workflows/broken_links_checker.yml @@ -1,35 +1,44 @@ -# Generated by Project Keeper -# https://github.com/exasol/project-keeper/blob/main/project-keeper/src/main/resources/templates/.github/workflows/broken_links_checker.yml +# This file was generated by Project Keeper. name: Broken Links Checker - on: schedule: - - cron: "0 5 * * 0" - + - { + cron: 0 5 * * 0 + } + workflow_dispatch: null jobs: linkChecker: runs-on: ubuntu-latest - permissions: + permissions: { contents: read + } defaults: - run: - shell: "bash" - concurrency: - group: ${{ github.workflow }}-${{ github.ref }} + run: { + shell: bash + } + concurrency: { + group: '${{ github.workflow }}-${{ github.ref }}', cancel-in-progress: true + } steps: - - uses: actions/checkout@v4 - - name: Configure broken links checker + - { + id: checkout, + uses: actions/checkout@v4 + } + - id: configure-broken-links-checker + name: Configure broken links checker run: | mkdir -p ./target echo '{"aliveStatusCodes": [429, 200], "ignorePatterns": [' \ - '{"pattern": "^https?://(www|dev).mysql.com/"},' \ - '{"pattern": "^https?://(www.)?opensource.org"}' \ - '{"pattern": "^https?://(www.)?eclipse.org"}' \ - '{"pattern": "^https?://projects.eclipse.org"}' \ - ']}' > ./target/broken_links_checker.json - - uses: gaurav-nelson/github-action-markdown-link-check@v1 - with: - use-quiet-mode: "yes" - use-verbose-mode: "yes" + '{"pattern": "^https?://(www|dev).mysql.com/"},' \ + '{"pattern": "^https?://(www.)?opensource.org"}' \ + '{"pattern": "^https?://(www.)?eclipse.org"}' \ + '{"pattern": "^https?://projects.eclipse.org"}' \ + ']}' > ./target/broken_links_checker.json + - id: run-broken-links-checker + uses: gaurav-nelson/github-action-markdown-link-check@v1 + with: { + use-quiet-mode: yes, + use-verbose-mode: yes, config-file: ./target/broken_links_checker.json + } diff --git a/.github/workflows/dependencies_check.yml b/.github/workflows/dependencies_check.yml index 02c5aa0..0832e80 100644 --- a/.github/workflows/dependencies_check.yml +++ b/.github/workflows/dependencies_check.yml @@ -46,9 +46,9 @@ jobs: org.sonatype.ossindex.maven:ossindex-maven-plugin:audit-aggregate \ -Dossindex.reportFile=$(pwd)/ossindex-report.json \ -Dossindex.fail=false - - name: Report Security Issues - id: security-issues - uses: exasol/python-toolbox/.github/actions/security-issues@main + - name: Create GitHub Issues + id: create-security-issues + uses: exasol/python-toolbox/.github/actions/security-issues@1.1.0 with: { format: maven, command: cat ossindex-report.json, diff --git a/dependencies.md b/dependencies.md index 57044b6..1f3937d 100644 --- a/dependencies.md +++ b/dependencies.md @@ -82,7 +82,7 @@ [25]: https://maven.apache.org/plugins/maven-install-plugin/ [26]: https://maven.apache.org/plugins/maven-resources-plugin/ [27]: https://maven.apache.org/plugins/maven-site-plugin/ -[28]: http://docs.sonarqube.org/display/PLUG/Plugin+Library/sonar-maven-plugin +[28]: http://docs.sonarqube.org/display/PLUG/Plugin+Library/sonar-scanner-maven/sonar-maven-plugin [29]: http://www.gnu.org/licenses/lgpl.txt [30]: https://maven.apache.org/plugins/maven-toolchains-plugin/ [31]: https://maven.apache.org/plugins/maven-compiler-plugin/ diff --git a/doc/changes/changelog.md b/doc/changes/changelog.md index 81ee84d..0e41516 100644 --- a/doc/changes/changelog.md +++ b/doc/changes/changelog.md @@ -1,5 +1,6 @@ # Changes +* [3.0.2](changes_3.0.2.md) * [3.0.1](changes_3.0.1.md) * [3.0.0](changes_3.0.0.md) * [2.2.6](changes_2.2.6.md) diff --git a/doc/changes/changes_3.0.2.md b/doc/changes/changes_3.0.2.md new file mode 100644 index 0000000..823d1c4 --- /dev/null +++ b/doc/changes/changes_3.0.2.md @@ -0,0 +1,32 @@ +# Virtual Schema Shared Integration Tests 3.0.2, released 2025-??-?? + +Code name: + +## Summary + +## Features + +* ISSUE_NUMBER: description + +## Dependency Updates + +### Compile Dependency Updates + +* Updated `com.exasol:hamcrest-resultset-matcher:1.7.0` to `1.7.1` +* Updated `org.junit.jupiter:junit-jupiter-api:5.12.2` to `5.13.0` +* Updated `org.junit.jupiter:junit-jupiter-params:5.12.2` to `5.13.0` + +### Test Dependency Updates + +* Updated `com.exasol:exasol-testcontainers:7.1.4` to `7.1.5` +* Updated `com.exasol:test-db-builder-java:3.6.0` to `3.6.1` +* Updated `org.mockito:mockito-junit-jupiter:5.17.0` to `5.18.0` +* Updated `org.testcontainers:junit-jupiter:1.21.0` to `1.21.1` + +### Plugin Dependency Updates + +* Updated `com.exasol:project-keeper-maven-plugin:5.0.1` to `5.1.0` +* Updated `org.apache.maven.plugins:maven-failsafe-plugin:3.5.2` to `3.5.3` +* Updated `org.apache.maven.plugins:maven-surefire-plugin:3.5.2` to `3.5.3` +* Updated `org.jacoco:jacoco-maven-plugin:0.8.12` to `0.8.13` +* Updated `org.sonarsource.scanner.maven:sonar-maven-plugin:5.0.0.4389` to `5.1.0.4751` diff --git a/pk_generated_parent.pom b/pk_generated_parent.pom index fabe1ed..8007197 100644 --- a/pk_generated_parent.pom +++ b/pk_generated_parent.pom @@ -3,7 +3,7 @@ 4.0.0 com.exasol virtual-schema-shared-integration-tests-generated-parent - 3.0.1 + 3.0.2 pom UTF-8 @@ -71,7 +71,7 @@ org.sonarsource.scanner.maven sonar-maven-plugin - 5.0.0.4389 + 5.1.0.4751 org.apache.maven.plugins @@ -171,7 +171,7 @@ org.apache.maven.plugins maven-surefire-plugin - 3.5.2 + 3.5.3 @@ -338,7 +338,7 @@ org.apache.maven.plugins maven-failsafe-plugin - 3.5.2 + 3.5.3 -Djava.util.logging.config.file=src/test/resources/logging.properties ${argLine} @@ -358,7 +358,7 @@ org.jacoco jacoco-maven-plugin - 0.8.12 + 0.8.13 prepare-agent diff --git a/pom.xml b/pom.xml index a73eecb..ced8a9d 100644 --- a/pom.xml +++ b/pom.xml @@ -2,18 +2,18 @@ 4.0.0 virtual-schema-shared-integration-tests - 3.0.1 + 3.0.2 virtual-schema-shared-integration-tests Abstract integration tests for virtual schemas https://github.com/exasol/virtual-schema-shared-integration-tests/ - 5.12.2 + 5.13.0 com.exasol hamcrest-resultset-matcher - 1.7.0 + 1.7.1 org.yaml @@ -49,7 +49,7 @@ com.exasol exasol-testcontainers - 7.1.4 + 7.1.5 test @@ -62,19 +62,19 @@ org.testcontainers junit-jupiter - 1.21.0 + 1.21.1 test com.exasol test-db-builder-java - 3.6.0 + 3.6.1 test org.mockito mockito-junit-jupiter - 5.17.0 + 5.18.0 test @@ -100,7 +100,7 @@ com.exasol project-keeper-maven-plugin - 5.0.1 + 5.1.0 @@ -126,7 +126,7 @@ virtual-schema-shared-integration-tests-generated-parent com.exasol - 3.0.1 + 3.0.2 pk_generated_parent.pom From f678b10d0b32e480a7889229bd3c4bdbdc5d8b30 Mon Sep 17 00:00:00 2001 From: Christoph Pirkl Date: Thu, 5 Jun 2025 13:17:34 +0200 Subject: [PATCH 2/6] Improve error messages --- .../scalarfunction/VirtualSchemaRunVerifier.java | 6 ++++-- .../scalarfunction/ScalarFunctionProviderIT.java | 3 ++- .../scalarfunction/ScalarFunctionsTestBaseIT.java | 1 + .../scalarfunction/VirtualSchemaRunVerifierTest.java | 2 +- 4 files changed, 8 insertions(+), 4 deletions(-) diff --git a/src/main/java/com/exasol/adapter/commontests/scalarfunction/VirtualSchemaRunVerifier.java b/src/main/java/com/exasol/adapter/commontests/scalarfunction/VirtualSchemaRunVerifier.java index e37b8f3..97ec589 100644 --- a/src/main/java/com/exasol/adapter/commontests/scalarfunction/VirtualSchemaRunVerifier.java +++ b/src/main/java/com/exasol/adapter/commontests/scalarfunction/VirtualSchemaRunVerifier.java @@ -57,7 +57,9 @@ public List assertFunctionBehavesSameOnVirtualSchema(final String functi } if (hadMismatches) { throw new IllegalStateException(ExaError.messageBuilder("E-VSSIT-10") - .message("Some runs of this function had different output. See above log messages.").toString()); + .message("Some runs of function {{function name}} had different output. See above log messages.", + function) + .toString()); } if (successParameters.isEmpty()) { fail(ExaError.messageBuilder("E-VSSIT-5").message( @@ -133,7 +135,7 @@ boolean quickCheckIfFunctionBehavesSameOnVs(final String function, final List> CONTAINER = new ExasolContainer<>() .withReuse(true); @@ -26,4 +27,4 @@ void test() throws SQLException { assertThat(scalarFunctions, hasItem("abs")); } } -} \ No newline at end of file +} diff --git a/src/test/java/com/exasol/adapter/commontests/scalarfunction/ScalarFunctionsTestBaseIT.java b/src/test/java/com/exasol/adapter/commontests/scalarfunction/ScalarFunctionsTestBaseIT.java index e7e742b..b9c43a0 100644 --- a/src/test/java/com/exasol/adapter/commontests/scalarfunction/ScalarFunctionsTestBaseIT.java +++ b/src/test/java/com/exasol/adapter/commontests/scalarfunction/ScalarFunctionsTestBaseIT.java @@ -25,6 +25,7 @@ public class ScalarFunctionsTestBaseIT extends ScalarFunctionsTestBase implements TestSetup, VirtualSchemaTestSetupProvider { @Container + @SuppressWarnings("resource") // Will be closed by Testcontainers private static final ExasolContainer> CONTAINER = new ExasolContainer<>() .withReuse(true); diff --git a/src/test/java/com/exasol/adapter/commontests/scalarfunction/VirtualSchemaRunVerifierTest.java b/src/test/java/com/exasol/adapter/commontests/scalarfunction/VirtualSchemaRunVerifierTest.java index 7e0190c..7f7fd60 100644 --- a/src/test/java/com/exasol/adapter/commontests/scalarfunction/VirtualSchemaRunVerifierTest.java +++ b/src/test/java/com/exasol/adapter/commontests/scalarfunction/VirtualSchemaRunVerifierTest.java @@ -96,6 +96,6 @@ void testAssertFunctionBehavesSameOnVirtualSchemaWithDifferentResult() throws SQ () -> this.virtualSchemaRunVerifier.assertFunctionBehavesSameOnVirtualSchema("UPPER", runsOnExasol, this.statement)); assertThat(exception.getMessage(), - equalTo("E-VSSIT-10: Some runs of this function had different output. See above log messages.")); + equalTo("E-VSSIT-10: Some runs of function 'UPPER' had different output. See above log messages.")); } } From 7c9c81107a79c34fb72c1d09cc57949ed5405e42 Mon Sep 17 00:00:00 2001 From: Christoph Pirkl Date: Thu, 5 Jun 2025 14:54:11 +0200 Subject: [PATCH 3/6] Improve log messages --- .../ScalarFunctionParameterFinder.java | 14 +++++++++----- .../scalarfunction/VirtualSchemaRunVerifier.java | 4 ++-- 2 files changed, 11 insertions(+), 7 deletions(-) diff --git a/src/main/java/com/exasol/adapter/commontests/scalarfunction/ScalarFunctionParameterFinder.java b/src/main/java/com/exasol/adapter/commontests/scalarfunction/ScalarFunctionParameterFinder.java index 30a2156..66d50ea 100644 --- a/src/main/java/com/exasol/adapter/commontests/scalarfunction/ScalarFunctionParameterFinder.java +++ b/src/main/java/com/exasol/adapter/commontests/scalarfunction/ScalarFunctionParameterFinder.java @@ -3,7 +3,6 @@ import java.sql.*; import java.util.*; import java.util.function.Function; -import java.util.logging.Level; import java.util.logging.Logger; import java.util.stream.Collectors; import java.util.stream.Stream; @@ -85,12 +84,17 @@ private static String join(final String smallerCombination, final String literal */ public List findOrGetFittingParameters(final String function, final Statement statement) { if (this.parameterCache.hasParametersForFunction(function)) { - LOGGER.log(Level.FINE, "Using parameters from parameter cache for function {0}.", function); - return findFittingParameters(function, + final List fittingParameters = findFittingParameters(function, this.parameterCache.getFunctionsValidParameterCombinations(function).stream(), statement); + LOGGER.fine(() -> String.format("Using %d parameters from parameter cache for function '%s': %s", + fittingParameters.size(), function, fittingParameters)); + return fittingParameters; } else { - LOGGER.log(Level.FINE, "Using generated parameters for function {0}.", function); - return findFittingParameters(function, statement); + final List fittingParameters = findFittingParameters(function, statement); + LOGGER.fine( + () -> String.format("Using %d generated parameters for function '%s': %s", fittingParameters.size(), + function, fittingParameters)); + return fittingParameters; } } diff --git a/src/main/java/com/exasol/adapter/commontests/scalarfunction/VirtualSchemaRunVerifier.java b/src/main/java/com/exasol/adapter/commontests/scalarfunction/VirtualSchemaRunVerifier.java index 97ec589..a2ef556 100644 --- a/src/main/java/com/exasol/adapter/commontests/scalarfunction/VirtualSchemaRunVerifier.java +++ b/src/main/java/com/exasol/adapter/commontests/scalarfunction/VirtualSchemaRunVerifier.java @@ -130,12 +130,12 @@ boolean quickCheckIfFunctionBehavesSameOnVs(final String function, final List String.format("Quick check query for function '%s' was successful: %s", function, + virtualSchemaQuery)); } catch (final SQLException exception) { return false; } } - LOGGER.log(Level.FINE, "Quick check for {0} was successful", function); return true; } From 9a1cfa11627c5b89a24ac4e023b5f753d9bf82e5 Mon Sep 17 00:00:00 2001 From: Christoph Pirkl Date: Thu, 5 Jun 2025 14:58:56 +0200 Subject: [PATCH 4/6] Allow overriding tests --- .../ScalarFunctionsTestBase.java | 42 +++++++++---------- 1 file changed, 21 insertions(+), 21 deletions(-) diff --git a/src/main/java/com/exasol/adapter/commontests/scalarfunction/ScalarFunctionsTestBase.java b/src/main/java/com/exasol/adapter/commontests/scalarfunction/ScalarFunctionsTestBase.java index 840404d..33a2a87 100644 --- a/src/main/java/com/exasol/adapter/commontests/scalarfunction/ScalarFunctionsTestBase.java +++ b/src/main/java/com/exasol/adapter/commontests/scalarfunction/ScalarFunctionsTestBase.java @@ -162,7 +162,7 @@ private VirtualSchemaTestSetup buildVirtualSchemaTableWithColumnOfExasolType(fin */ @ParameterizedTest @MethodSource("getScalarFunctionWithNoParameters") - void testFunctionsWithNoParenthesis(final String function) throws SQLException { + public void testFunctionsWithNoParenthesis(final String function) throws SQLException { assumeTestNotSkipped(function); try (final VirtualSchemaTestSetup virtualSchema = getBooleanVirtualSchema(true)) { assertScalarFunctionQuery(virtualSchema, function, table().row(anyOf(instanceOf(Object.class), nullValue())) @@ -171,7 +171,7 @@ void testFunctionsWithNoParenthesis(final String function) throws SQLException { } @Test - void testSystimestamp() throws SQLException { + public void testSystimestamp() throws SQLException { assumeTestNotSkipped("SYSTIMESTAMP"); setSessionTimezone("UTC"); final Timestamp actualTimestamp = getActualSystimestamp(); @@ -198,7 +198,7 @@ private Timestamp getActualSystimestamp() throws SQLException { * reason we check here if it produces at least some different results. */ @Test - void testRand() throws SQLException { + public void testRand() throws SQLException { assumeTestNotSkipped("RAND"); try (final VirtualSchemaTestSetup virtualSchema = getBooleanVirtualSchema(true)) { assertScalarFunctionQuery(virtualSchema, "RAND()", @@ -207,7 +207,7 @@ void testRand() throws SQLException { } @Test - void testSysGUID() throws SQLException { + public void testSysGUID() throws SQLException { assumeTestNotSkipped("SYS_GUID"); try (final VirtualSchemaTestSetup virtualSchema = getBooleanVirtualSchema(true)) { assertScalarFunctionQuery(virtualSchema, "SYS_GUID()", @@ -237,7 +237,7 @@ private VirtualSchemaTestSetup getIntegerVirtualSchema(final int valueForSingleR @ParameterizedTest @CsvSource({ "ADD, +, 4", "SUB, -, 0", "MULT, *, 4", "FLOAT_DIV, /, 1" }) - void testSimpleArithmeticFunctions(final String function, final String operator, final int expectedResult) + public void testSimpleArithmeticFunctions(final String function, final String operator, final int expectedResult) throws SQLException { assumeTestNotSkipped(function); try (final VirtualSchemaTestSetup virtualSchema = getIntegerVirtualSchema(2)) { @@ -248,7 +248,7 @@ void testSimpleArithmeticFunctions(final String function, final String operator, } @Test - void testCast() throws SQLException { + public void testCast() throws SQLException { assumeTestNotSkipped("CAST"); try (final VirtualSchemaTestSetup virtualSchema = getIntegerVirtualSchema(2)) { final String scalarFunctionCall = "CAST(" + MY_COLUMN + " AS VARCHAR(254) UTF8)"; @@ -259,7 +259,7 @@ void testCast() throws SQLException { @ParameterizedTest @CsvSource({ "-2, 0", "2, 2" }) - void testGreatest(final int input, final int expectedOutput) throws SQLException { + public void testGreatest(final int input, final int expectedOutput) throws SQLException { assumeTestNotSkipped("GREATEST"); try (final VirtualSchemaTestSetup virtualSchema = getIntegerVirtualSchema(input)) { final String scalarFunctionCall = "GREATEST(" + MY_COLUMN + ", 0)"; @@ -274,7 +274,7 @@ private VirtualSchemaTestSetup getDoubleVirtualSchema(final double valueForSingl @ParameterizedTest @CsvSource({ "0.1, 0", "0.5, 1", "0.9, 1" }) - void testRound(final double input, final double expectedOutput) throws SQLException { + public void testRound(final double input, final double expectedOutput) throws SQLException { assumeTestNotSkipped("ROUND"); try (final VirtualSchemaTestSetup virtualSchema = getDoubleVirtualSchema(input)) { final String scalarFunctionCall = "ROUND(" + MY_COLUMN + ")"; @@ -289,7 +289,7 @@ private VirtualSchemaTestSetup getBooleanVirtualSchema(final boolean valueForSin @ParameterizedTest @ValueSource(booleans = { true, false }) - void testNeg(final boolean input) throws SQLException { + public void testNeg(final boolean input) throws SQLException { assumeTestNotSkipped("NEG"); try (final VirtualSchemaTestSetup virtualSchema = getBooleanVirtualSchema(input)) { final String scalarFunctionCall = "NOT " + MY_COLUMN; @@ -317,7 +317,7 @@ private VirtualSchemaTestSetup getStringVirtualSchema(final String valueForSingl "b, 2", // "c, 3" // }) - void testCase(final String input, final int expectedResult) throws SQLException { + public void testCase(final String input, final int expectedResult) throws SQLException { assumeTestNotSkipped("CASE"); try (final VirtualSchemaTestSetup virtualSchema = getStringVirtualSchema(input)) { final String scalarFunctionCall = "CASE " + MY_COLUMN + " WHEN 'a' THEN 1 WHEN 'b' THEN 2 ELSE 3 END"; @@ -327,7 +327,7 @@ void testCase(final String input, final int expectedResult) throws SQLException } @Test - void testConvertTz() throws SQLException, ParseException { + public void testConvertTz() throws SQLException, ParseException { assumeTestNotSkipped("CONVERT_TZ"); final Timestamp expected = new Timestamp( new SimpleDateFormat("yyyy-MM-dd HH:mm:ss").parse("2012-03-25 04:30:00").getTime()); @@ -340,7 +340,7 @@ void testConvertTz() throws SQLException, ParseException { } @Test - void testDateTrunc() throws SQLException, ParseException { + public void testDateTrunc() throws SQLException, ParseException { assumeTestNotSkipped("DATE_TRUNC"); final Timestamp expectedResult = new Timestamp( new SimpleDateFormat("yyyy-MM-dd HH:mm:ss").parse("2006-12-01 00:00:00.0").getTime()); @@ -352,7 +352,7 @@ void testDateTrunc() throws SQLException, ParseException { } @Test - void testNumToDsInterval() throws SQLException { + public void testNumToDsInterval() throws SQLException { assumeTestNotSkipped("NUMTODSINTERVAL"); try (final VirtualSchemaTestSetup virtualSchema = getStringVirtualSchema("HOUR")) { final String scalarFunctionCall = "NUMTODSINTERVAL(3.2, " + MY_COLUMN + ")"; @@ -362,7 +362,7 @@ void testNumToDsInterval() throws SQLException { } @Test - void testNumToYmInterval() throws SQLException { + public void testNumToYmInterval() throws SQLException { assumeTestNotSkipped("NUMTOYMINTERVAL"); try (final VirtualSchemaTestSetup virtualSchema = getStringVirtualSchema("YEAR")) { final String scalarFunctionCall = "NUMTOYMINTERVAL(3.5, " + MY_COLUMN + ")"; @@ -372,7 +372,7 @@ void testNumToYmInterval() throws SQLException { } @Test - void testToYmInterval() throws SQLException { + public void testToYmInterval() throws SQLException { assumeTestNotSkipped("TO_YMINTERVAL"); try (final VirtualSchemaTestSetup virtualSchema = getStringVirtualSchema("3-11")) { final String scalarFunctionCall = "TO_YMINTERVAL(" + MY_COLUMN + ")"; @@ -382,7 +382,7 @@ void testToYmInterval() throws SQLException { } @Test - void testToDsInterval() throws SQLException { + public void testToDsInterval() throws SQLException { assumeTestNotSkipped("TO_DSINTERVAL"); try (final VirtualSchemaTestSetup virtualSchema = getStringVirtualSchema("3 10:59:59.123")) { final String scalarFunctionCall = "TO_DSINTERVAL(" + MY_COLUMN + ")"; @@ -392,7 +392,7 @@ void testToDsInterval() throws SQLException { } @Test - void testJsonValue() throws SQLException { + public void testJsonValue() throws SQLException { assumeTestNotSkipped("JSON_VALUE"); try (final VirtualSchemaTestSetup virtualSchema = getStringVirtualSchema("{\"name\" : \"Test\"}")) { final String scalarFunctionCall = "JSON_VALUE(" + MY_COLUMN + ", '$.name')"; @@ -402,7 +402,7 @@ void testJsonValue() throws SQLException { } @Test - void testPosition() throws SQLException { + public void testPosition() throws SQLException { assumeTestNotSkipped("position"); try (final VirtualSchemaTestSetup virtualSchema = getStringVirtualSchema("my long string")) { final String scalarFunctionCall = "POSITION('long' IN " + MY_COLUMN + ")"; @@ -417,7 +417,7 @@ private VirtualSchemaTestSetup getTimestampVirtualSchema(final Timestamp valueFo } @Test - void testExtract() throws SQLException { + public void testExtract() throws SQLException { assumeTestNotSkipped("EXTRACT"); setSessionTimezone("UTC"); try (final VirtualSchemaTestSetup virtualSchema = getTimestampVirtualSchema(new Timestamp(1000))) { @@ -432,7 +432,7 @@ void testExtract() throws SQLException { "UTC, 1", // "Europe/Berlin, -3599",// }) - void testPosixTime(final String timeZone, final long expectedResult) { + public void testPosixTime(final String timeZone, final long expectedResult) { assumeTestNotSkipped("POSIX_TIME"); runOnExasol(statement -> { statement.executeUpdate("ALTER SESSION SET TIME_ZONE='" + timeZone + "';"); @@ -560,7 +560,7 @@ private List createColumns() { @Tag("WithAutomaticParameterDiscovery") @ParameterizedTest @MethodSource("getScalarFunctions") - void testScalarFunctions(final String function) { + public void testScalarFunctions(final String function) { runOnExasol(statement -> { final List successfulScalarFunctionLocalRuns = this.parameterFinder .findOrGetFittingParameters(function, statement); From 27d2e4f7c5558ecefd0627916489cc185451a28e Mon Sep 17 00:00:00 2001 From: Christoph Pirkl Date: Thu, 5 Jun 2025 14:59:28 +0200 Subject: [PATCH 5/6] Improve log messages --- .../scalarfunction/ScalarFunctionParameterFinder.java | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) diff --git a/src/main/java/com/exasol/adapter/commontests/scalarfunction/ScalarFunctionParameterFinder.java b/src/main/java/com/exasol/adapter/commontests/scalarfunction/ScalarFunctionParameterFinder.java index 66d50ea..b035fda 100644 --- a/src/main/java/com/exasol/adapter/commontests/scalarfunction/ScalarFunctionParameterFinder.java +++ b/src/main/java/com/exasol/adapter/commontests/scalarfunction/ScalarFunctionParameterFinder.java @@ -86,14 +86,14 @@ public List findOrGetFittingParameters(final String func if (this.parameterCache.hasParametersForFunction(function)) { final List fittingParameters = findFittingParameters(function, this.parameterCache.getFunctionsValidParameterCombinations(function).stream(), statement); - LOGGER.fine(() -> String.format("Using %d parameters from parameter cache for function '%s': %s", - fittingParameters.size(), function, fittingParameters)); + LOGGER.fine(() -> String.format("Using %d parameters from parameter cache for function '%s'", + fittingParameters.size(), function)); return fittingParameters; } else { final List fittingParameters = findFittingParameters(function, statement); LOGGER.fine( - () -> String.format("Using %d generated parameters for function '%s': %s", fittingParameters.size(), - function, fittingParameters)); + () -> String.format("Using %d generated parameters for function '%s'", fittingParameters.size(), + function)); return fittingParameters; } } From aaba9ed2285cd4caf3e9fc41bb1afb7b58551038 Mon Sep 17 00:00:00 2001 From: Christoph Pirkl Date: Thu, 5 Jun 2025 14:59:38 +0200 Subject: [PATCH 6/6] Configure default Exasol version --- .vscode/settings.json | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/.vscode/settings.json b/.vscode/settings.json index c845250..f1aa532 100644 --- a/.vscode/settings.json +++ b/.vscode/settings.json @@ -11,7 +11,8 @@ "java.sources.organizeImports.staticStarThreshold": 3, "java.test.config": { "vmArgs": [ - "-Djava.util.logging.config.file=src/test/resources/logging.properties" + "-Djava.util.logging.config.file=src/test/resources/logging.properties", + "-Dcom.exasol.dockerdb.image=8.34.0" ] }, "sonarlint.connectedMode.project": {