Skip to content

Commit 3b1785c

Browse files
author
YIHAODIAN\wangshuangshuang
committed
Spark-19726: modify unit tests tablename same with jdbc
1 parent 588ccad commit 3b1785c

File tree

1 file changed

+3
-3
lines changed

1 file changed

+3
-3
lines changed

sql/core/src/test/scala/org/apache/spark/sql/sources/JdbcInsertSuite.scala

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -53,7 +53,7 @@ class JdbcInsertSuite extends DataSourceTest with BeforeAndAfter with SharedSQLC
5353

5454
sql(
5555
s"""
56-
|CREATE OR REPLACE TEMPORARY VIEW jdbcTable
56+
|CREATE OR REPLACE TEMPORARY VIEW timestamp_test
5757
|USING org.apache.spark.sql.jdbc
5858
|OPTIONS (url '$url', dbtable 'test.timestamp_test', user 'testUser', password 'testPass')
5959
""".stripMargin.replaceAll("\n", " "))
@@ -74,13 +74,13 @@ class JdbcInsertSuite extends DataSourceTest with BeforeAndAfter with SharedSQLC
7474
val message = intercept[Exception] {
7575
sql(
7676
s"""
77-
|INSERT INTO jdbcTable values(222, null)
77+
|INSERT INTO timestamp_test values(111, null)
7878
""".stripMargin)
7979
}.getMessage
8080

8181
assert(
8282
message.contains("NULL not allowed for column \"TIME_STAMP\""),
83-
"It is not allowed to insert into null into timestamp column which is defined not null."
83+
"It is not allowed to insert null into timestamp column which is defined not null."
8484
)
8585
}
8686
}

0 commit comments

Comments
 (0)