Skip to content

Conversation

@MaxGekk
Copy link
Member

@MaxGekk MaxGekk commented Oct 15, 2022

What changes were proposed in this pull request?

In the PR, I propose to port the following tests suites onto checkError to check valuable error parts instead of error messages:

  • JDBCWriteSuite
  • JDBCTableCatalogSuite
  • JdbcUtilsSuite
  • CreateTableAsSelectSuite
  • SparkScriptTransformationSuite
  • SQLViewSuite
  • InsertSuite

Why are the changes needed?

Migration on checkError() will make the tests independent from the text of error messages.

Does this PR introduce any user-facing change?

No.

How was this patch tested?

By running the modified test suites:

$ build/sbt "test:testOnly *SQLViewSuite"
$ build/sbt -Phive-2.3 -Phive-thriftserver "test:testOnly org.apache.spark.sql.execution.datasources.v2.jdbc.JDBCTableCatalogSuite"
$ build/sbt "test:testOnly *JdbcUtilsSuite"
$ build/sbt -Phive-2.3 -Phive-thriftserver "test:testOnly *SparkScriptTransformationSuite"

@github-actions github-actions bot added the SQL label Oct 15, 2022
@MaxGekk MaxGekk changed the title [WIP][SQL] Use checkError() to intercept ParseException [SPARK-40811][SQL][TESTS] Use checkError() to intercept ParseException Oct 16, 2022
@MaxGekk MaxGekk marked this pull request as ready for review October 16, 2022 17:35
@MaxGekk
Copy link
Member Author

MaxGekk commented Oct 16, 2022

@panbingkun FYI

Copy link
Contributor

@amaliujia amaliujia left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM!

@MaxGekk
Copy link
Member Author

MaxGekk commented Oct 17, 2022

@cloud-fan Could you approve this PR, please.

@MaxGekk
Copy link
Member Author

MaxGekk commented Oct 19, 2022

Merging to master. Thank you, @amaliujia and @cloud-fan for review.

@MaxGekk MaxGekk closed this in af6aa15 Oct 19, 2022
SandishKumarHN pushed a commit to SandishKumarHN/spark that referenced this pull request Dec 12, 2022
…tion`

### What changes were proposed in this pull request?
In the PR, I propose to port the following tests suites onto `checkError` to check valuable error parts instead of error messages:
- JDBCWriteSuite
- JDBCTableCatalogSuite
- JdbcUtilsSuite
- CreateTableAsSelectSuite
- SparkScriptTransformationSuite
- SQLViewSuite
- InsertSuite

### Why are the changes needed?
Migration on `checkError()` will make the tests independent from the text of error messages.

### Does this PR introduce _any_ user-facing change?
No.

### How was this patch tested?
By running the modified test suites:
```
$ build/sbt "test:testOnly *SQLViewSuite"
$ build/sbt -Phive-2.3 -Phive-thriftserver "test:testOnly org.apache.spark.sql.execution.datasources.v2.jdbc.JDBCTableCatalogSuite"
$ build/sbt "test:testOnly *JdbcUtilsSuite"
$ build/sbt -Phive-2.3 -Phive-thriftserver "test:testOnly *SparkScriptTransformationSuite"
```

Closes apache#38267 from MaxGekk/parseexception-checkError.

Authored-by: Max Gekk <[email protected]>
Signed-off-by: Max Gekk <[email protected]>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants