davidm-db commented on code in PR #47462:
URL: https://github.com/apache/spark/pull/47462#discussion_r1706775236
##########
sql/core/src/test/scala/org/apache/spark/sql/scripting/SqlScriptingExecutionNodeSuite.scala:
##########
@@ -40,10 +41,38 @@ class SqlScriptingExecutionNodeSuite extends SparkFunSuite
with SharedSparkSessi
Origin(startIndex = Some(0), stopIndex = Some(description.length)),
isInternal = false)
+ case class TestWhileCondition(description: String)
+ extends SingleStatementExec(
+ parsedPlan = Project(Seq(Alias(Literal(true), description)()),
OneRowRelation()),
+ Origin(startIndex = Some(0), stopIndex = Some(description.length)),
+ isInternal = false)
+
+ case class TestWhile(
+ condition: SingleStatementExec,
+ body: CompoundBodyExec,
+ reps: Int)
+ extends WhileStatementExec(condition, body, spark) {
+
+ private var callCount: Int = 0
+
+ override def evaluateBooleanCondition(
+ session: SparkSession,
Review Comment:
nit: the indentation should be the other way around - parameters are
indented 4 spaces compared to the function, whereas the function code is
indented 2 spaces.
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
To unsubscribe, e-mail: [email protected]
For queries about this service, please contact Infrastructure at:
[email protected]
---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]