Skip to content

Commit

Permalink
Fix scalastyle
Browse files Browse the repository at this point in the history
  • Loading branch information
miland-db committed Aug 12, 2024
1 parent cbe2f0f commit 564f584
Show file tree
Hide file tree
Showing 3 changed files with 13 additions and 12 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -21,14 +21,15 @@ import org.apache.spark.sql.AnalysisException
import org.apache.spark.sql.catalyst.SQLConfHelper
import org.apache.spark.sql.catalyst.expressions._
import org.apache.spark.sql.catalyst.rules.{RuleId, UnknownRuleId}
import org.apache.spark.sql.catalyst.trees.TreePattern.{OUTER_REFERENCE, PLAN_EXPRESSION}
import org.apache.spark.sql.catalyst.trees.{AlwaysProcess, CurrentOrigin, TreeNode, TreeNodeTag, TreePatternBits}
import org.apache.spark.sql.catalyst.trees.TreePattern.{OUTER_REFERENCE, PLAN_EXPRESSION}
import org.apache.spark.sql.catalyst.types.DataTypeUtils
import org.apache.spark.sql.internal.SQLConf
import org.apache.spark.sql.types.{DataType, StructType}
import org.apache.spark.util.collection.BitSet

import java.util.IdentityHashMap

import scala.collection.mutable

/**
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -139,7 +139,7 @@ class SqlScriptingExecutionNodeSuite extends SparkFunSuite with SharedSparkSessi
}

test("if else if - enter body of the ELSE IF clause") {
val iter = new TestBody(Seq(
val iter = TestBody(Seq(
new IfElseStatementExec(
conditions = Seq(
TestIfElseCondition(condVal = false, description = "con1"),
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -131,7 +131,7 @@ class SqlScriptingInterpreterSuite extends SparkFunSuite with SharedSparkSession
val expected = Seq(
Array.empty[Row], // declare var
Array.empty[Row], // set var
Array(Row(2)), // select
Array(Row(2)) // select
)
verifySqlScriptResult(sqlScript, expected)
}
Expand All @@ -148,7 +148,7 @@ class SqlScriptingInterpreterSuite extends SparkFunSuite with SharedSparkSession
val expected = Seq(
Array.empty[Row], // declare var
Array.empty[Row], // set var
Array(Row(2)), // select
Array(Row(2)) // select
)
verifySqlScriptResult(sqlScript, expected)
}
Expand Down Expand Up @@ -179,7 +179,7 @@ class SqlScriptingInterpreterSuite extends SparkFunSuite with SharedSparkSession
Array(Row(2)), // select
Array.empty[Row], // declare var
Array.empty[Row], // set var
Array(Row(4)), // select
Array(Row(4)) // select
)
verifySqlScriptResult(sqlScript, expected)
}
Expand Down Expand Up @@ -225,7 +225,7 @@ class SqlScriptingInterpreterSuite extends SparkFunSuite with SharedSparkSession
Array.empty[Row], // declare var
Array.empty[Row], // set var
Array(Row(2)), // select
Array.empty[Row], // drop var - explicit
Array.empty[Row] // drop var - explicit
)
verifySqlScriptResult(sqlScript, expected)
}
Expand Down Expand Up @@ -281,7 +281,7 @@ class SqlScriptingInterpreterSuite extends SparkFunSuite with SharedSparkSession
Array(Row(-1)), // select flag
Array.empty[Row], // set flag
Array(Row(4)), // select
Array(Row(1)), // select
Array(Row(1)) // select
)
verifySqlScriptResult(sqlScript, expected)
}
Expand Down Expand Up @@ -321,7 +321,7 @@ class SqlScriptingInterpreterSuite extends SparkFunSuite with SharedSparkSession
Array(Row(5)), // select
Array(Row(6)), // select
Array(Row(7)), // select
Array(Row(1)), // select
Array(Row(1)) // select
)
verifySqlScriptResult(sqlScript, expected)
}
Expand Down Expand Up @@ -361,7 +361,7 @@ class SqlScriptingInterpreterSuite extends SparkFunSuite with SharedSparkSession
Array(Row(5)), // select
Array(Row(6)), // select
Array(Row(7)), // select
Array(Row(1)), // select
Array(Row(1)) // select
)
verifySqlScriptResult(sqlScript, expected)
}
Expand Down Expand Up @@ -392,7 +392,7 @@ class SqlScriptingInterpreterSuite extends SparkFunSuite with SharedSparkSession
Array(Row(3)), // select
Array(Row(-1)), // select flag
Array.empty[Row], // set flag
Array(Row(1)), // select flag from the outer body
Array(Row(1)) // select flag from the outer body
)
verifySqlScriptResult(sqlScript, expected)
}
Expand Down Expand Up @@ -430,7 +430,7 @@ class SqlScriptingInterpreterSuite extends SparkFunSuite with SharedSparkSession
Array.empty[Row], // set flag
// skip select 5
// skip select 6
Array(Row(1)), // select flag from the outer body
Array(Row(1)) // select flag from the outer body
)
verifySqlScriptResult(sqlScript, expected)
}
Expand All @@ -457,7 +457,7 @@ class SqlScriptingInterpreterSuite extends SparkFunSuite with SharedSparkSession
Array(Row(-1)), // select flag
Array.empty[Row], // set flag
Array(Row(3)), // select
Array(Row(1)), // select
Array(Row(1)) // select
)
verifySqlScriptResult(sqlScript, expected)
}
Expand Down

0 comments on commit 564f584

Please sign in to comment.