Skip to content

Commit

Permalink
[SPARK-13401][SQL][TESTS] Fix SQL test warnings.
Browse files Browse the repository at this point in the history
## What changes were proposed in this pull request?

This fix tries to fix several SQL test warnings under the sql/core/src/test directory. The fixed warnings includes "[unchecked]", "[rawtypes]", and "[varargs]".

## How was this patch tested?

All existing tests passed.

Author: Yong Tang <[email protected]>

Closes apache#11857 from yongtang/SPARK-13401.
  • Loading branch information
yongtang authored and rxin committed Mar 23, 2016
1 parent 0d51b60 commit 75dc296
Show file tree
Hide file tree
Showing 6 changed files with 6 additions and 0 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -129,6 +129,7 @@ public org.apache.spark.sql.execution.datasources.parquet.test.avro.AvroArrayOfA
}

@Override
@SuppressWarnings(value="unchecked")
public AvroArrayOfArray build() {
try {
AvroArrayOfArray record = new AvroArrayOfArray();
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -129,6 +129,7 @@ public org.apache.spark.sql.execution.datasources.parquet.test.avro.AvroMapOfArr
}

@Override
@SuppressWarnings(value="unchecked")
public AvroMapOfArray build() {
try {
AvroMapOfArray record = new AvroMapOfArray();
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -182,6 +182,7 @@ public org.apache.spark.sql.execution.datasources.parquet.test.avro.AvroNonNulla
}

@Override
@SuppressWarnings(value="unchecked")
public AvroNonNullableArrays build() {
try {
AvroNonNullableArrays record = new AvroNonNullableArrays();
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -182,6 +182,7 @@ public org.apache.spark.sql.execution.datasources.parquet.test.avro.Nested.Build
}

@Override
@SuppressWarnings(value="unchecked")
public Nested build() {
try {
Nested record = new Nested();
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -235,6 +235,7 @@ public org.apache.spark.sql.execution.datasources.parquet.test.avro.ParquetAvroC
}

@Override
@SuppressWarnings(value="unchecked")
public ParquetAvroCompat build() {
try {
ParquetAvroCompat record = new ParquetAvroCompat();
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -309,6 +309,7 @@ private static <T> Set<T> toSet(List<T> records) {
}

@SafeVarargs
@SuppressWarnings("varargs")
private static <T> Set<T> asSet(T... records) {
return toSet(Arrays.asList(records));
}
Expand Down

0 comments on commit 75dc296

Please sign in to comment.