Skip to content

Commit

Permalink
try fix ci
Browse files Browse the repository at this point in the history
  • Loading branch information
izhangzhihao committed Dec 24, 2023
1 parent e48a6d2 commit c818033
Show file tree
Hide file tree
Showing 2 changed files with 1 addition and 6 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -3,11 +3,7 @@ package com.github.sharpdata.sharpetl.core.quality
final case class QualityCheckRule(dataCheckType: String, rule: String, errorType: String) {
def withColumn(column: String): DataQualityConfig = {
if (rule.contains("$")) {
if (column.startsWith("`") && column.endsWith("`")) {
DataQualityConfig(column, dataCheckType, rule.replace("$column", column), errorType)
} else {
DataQualityConfig(column, dataCheckType, rule.replace("$column", s"`$column`"), errorType)
}
DataQualityConfig(column, dataCheckType, rule.replace("$column", s"`$column`").replaceAll("``", "`"), errorType)
} else {
DataQualityConfig(column, dataCheckType, rule, errorType)
}
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,6 @@ import com.github.sharpdata.sharpetl.core.datasource.config.DBDataSourceConfig
import com.github.sharpdata.sharpetl.core.quality.{DataQualityCheckResult, ErrorType, QualityCheckRule}
import com.github.sharpdata.sharpetl.core.repository.mysql.QualityCheckAccessor
import com.github.sharpdata.sharpetl.core.syntax.WorkflowStep
import com.github.sharpdata.sharpetl.spark.job.{SparkSessionTestWrapper, SparkWorkflowInterpreter}
import org.apache.spark.sql.{Row, SparkSession}
import org.apache.spark.sql.types._
import org.scalatest.flatspec.AnyFlatSpec
Expand Down

0 comments on commit c818033

Please sign in to comment.