diff --git a/plugin/trino-bigquery/src/test/java/io/trino/plugin/bigquery/BigQueryTestView.java b/plugin/trino-bigquery/src/test/java/io/trino/plugin/bigquery/BigQueryTestView.java index eef2577741a5..7ffbf0818197 100644 --- a/plugin/trino-bigquery/src/test/java/io/trino/plugin/bigquery/BigQueryTestView.java +++ b/plugin/trino-bigquery/src/test/java/io/trino/plugin/bigquery/BigQueryTestView.java @@ -24,14 +24,12 @@ public class BigQueryTestView extends TestTable { - private final SqlExecutor sqlExecutor; private final TestTable table; private final String viewName; public BigQueryTestView(SqlExecutor sqlExecutor, TestTable table) { super(sqlExecutor, table.getName(), null); - this.sqlExecutor = requireNonNull(sqlExecutor, "sqlExecutor is null"); this.table = requireNonNull(table, "table is null"); this.viewName = table.getName() + "_view"; } diff --git a/plugin/trino-iceberg/src/test/java/io/trino/plugin/iceberg/BaseSharedMetastoreTest.java b/plugin/trino-iceberg/src/test/java/io/trino/plugin/iceberg/BaseSharedMetastoreTest.java index 1f3ee382e608..0037de7eb54a 100644 --- a/plugin/trino-iceberg/src/test/java/io/trino/plugin/iceberg/BaseSharedMetastoreTest.java +++ b/plugin/trino-iceberg/src/test/java/io/trino/plugin/iceberg/BaseSharedMetastoreTest.java @@ -16,8 +16,6 @@ import io.trino.testing.AbstractTestQueryFramework; import org.testng.annotations.Test; -import java.nio.file.Path; - import static io.trino.testing.sql.TestTable.randomTableSuffix; import static org.assertj.core.api.Assertions.assertThat; import static org.assertj.core.api.Assertions.assertThatThrownBy; @@ -27,7 +25,6 @@ public abstract class BaseSharedMetastoreTest extends AbstractTestQueryFramework { protected final String schema = "test_shared_schema_" + randomTableSuffix(); - protected Path dataDirectory; protected abstract String getExpectedHiveCreateSchema(String catalogName); diff --git a/plugin/trino-iceberg/src/test/java/io/trino/plugin/iceberg/TestSharedHiveMetastore.java b/plugin/trino-iceberg/src/test/java/io/trino/plugin/iceberg/TestSharedHiveMetastore.java index c646834f4d22..376728854835 100644 --- a/plugin/trino-iceberg/src/test/java/io/trino/plugin/iceberg/TestSharedHiveMetastore.java +++ b/plugin/trino-iceberg/src/test/java/io/trino/plugin/iceberg/TestSharedHiveMetastore.java @@ -34,6 +34,8 @@ import io.trino.tpch.TpchTable; import org.testng.annotations.AfterClass; +import java.nio.file.Path; + import static io.trino.plugin.iceberg.IcebergQueryRunner.ICEBERG_CATALOG; import static io.trino.plugin.tpch.TpchMetadata.TINY_SCHEMA_NAME; import static io.trino.testing.QueryAssertions.copyTpchTables; @@ -44,6 +46,7 @@ public class TestSharedHiveMetastore extends BaseSharedMetastoreTest { private static final String HIVE_CATALOG = "hive"; + private Path dataDirectory; @Override protected QueryRunner createQueryRunner() diff --git a/pom.xml b/pom.xml index d2a4505ac7a0..5c646807a972 100644 --- a/pom.xml +++ b/pom.xml @@ -1898,6 +1898,7 @@ -Xep:EqualsIncompatibleType:ERROR \ -Xep:FallThrough:ERROR \ -Xep:GuardedBy:OFF \ + -Xep:HidingField:ERROR \ -Xep:ImmutableEnumChecker:OFF \ -Xep:ImmutableSetForContains:ERROR \ -Xep:InconsistentCapitalization:ERROR \