Skip to content

Commit 72fdbbf

Browse files
authored
chore: add copyright header to expected query in test (#1348)
Fixes the build error in #1345 This test failure is caused by the recent update that ensures that PostgreSQL-dialect queries also send all comments to Cloud Spanner, which means that the expected query in this test has changed.
1 parent 893f61a commit 72fdbbf

File tree

1 file changed

+17
-1
lines changed

1 file changed

+17
-1
lines changed

src/test/java/com/google/cloud/spanner/jdbc/PartitionedQueryMockServerTest.java

Lines changed: 17 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -411,7 +411,23 @@ public void testAutoPartitionMode() throws SQLException {
411411
mockSpanner.putPartialStatementResult(
412412
StatementResult.query(
413413
Statement.of(
414-
"SELECT TABLE_CATALOG AS \"TABLE_CAT\", TABLE_SCHEMA AS \"TABLE_SCHEM\", TABLE_NAME AS \"TABLE_NAME\",\n"
414+
"/*\n"
415+
+ " * Copyright 2022 Google LLC\n"
416+
+ " *\n"
417+
+ " * Licensed under the Apache License, Version 2.0 (the \"License\");\n"
418+
+ " * you may not use this file except in compliance with the License.\n"
419+
+ " * You may obtain a copy of the License at\n"
420+
+ " *\n"
421+
+ " * http://www.apache.org/licenses/LICENSE-2.0\n"
422+
+ " *\n"
423+
+ " * Unless required by applicable law or agreed to in writing, software\n"
424+
+ " * distributed under the License is distributed on an \"AS IS\" BASIS,\n"
425+
+ " * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\n"
426+
+ " * See the License for the specific language governing permissions and\n"
427+
+ " * limitations under the License.\n"
428+
+ " */\n"
429+
+ "\n"
430+
+ "SELECT TABLE_CATALOG AS \"TABLE_CAT\", TABLE_SCHEMA AS \"TABLE_SCHEM\", TABLE_NAME AS \"TABLE_NAME\",\n"
415431
+ " CASE WHEN TABLE_TYPE = 'BASE TABLE' THEN 'TABLE' ELSE TABLE_TYPE END AS \"TABLE_TYPE\",\n"
416432
+ " NULL AS \"REMARKS\", NULL AS \"TYPE_CAT\", NULL AS \"TYPE_SCHEM\", NULL AS \"TYPE_NAME\",\n"
417433
+ " NULL AS \"SELF_REFERENCING_COL_NAME\", NULL AS \"REF_GENERATION\"\n"

0 commit comments

Comments
 (0)