Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

test: modify tests to use correct quote escaping #909

Merged
merged 1 commit into from
Jul 18, 2022
Merged

Conversation

olavloite
Copy link
Collaborator

Some tests used invalid escaping of quotes in PostgreSQL queries. They
assumed that a quote in a quoted string could be escaped by prefixing
it with a backslash. This is however not allowed in PostgreSQL, and
instead the quote must be escaped by including the same quote twice in
the string.
The Spanner Java client library contained a bug that allowed the
backslash-escaped quotes to be accepted. This bug has been fixed in
6.25.7 and these tests therefore need to be modified to be able to
update to that version.

Fixes the build error in #898

Some tests used invalid escaping of quotes in PostgreSQL queries. They
assumed that a quote in a quoted string could be escaped by prefixing
it with a backslash. This is however not allowed in PostgreSQL, and
instead the quote must be escaped by including the same quote twice in
the string.
The Spanner Java client library contained a bug that allowed the
backslash-escaped quotes to be accepted. This bug has been fixed in
6.25.7 and these tests therefore need to be modified to be able to
update to that version.

Fixes the build error in #898
@olavloite olavloite requested a review from a team as a code owner July 14, 2022 05:42
@product-auto-label product-auto-label bot added size: s Pull request size is small. api: spanner Issues related to the googleapis/java-spanner-jdbc API. labels Jul 14, 2022
@alicejli alicejli added the kokoro:force-run Add this label to force Kokoro to re-run the tests. label Jul 18, 2022
@yoshi-kokoro yoshi-kokoro removed the kokoro:force-run Add this label to force Kokoro to re-run the tests. label Jul 18, 2022
@alicejli
Copy link
Contributor

@rajatbhatta Do you mind taking a look and approving? Thank you!

@rajatbhatta rajatbhatta merged commit 57a0c7c into main Jul 18, 2022
@rajatbhatta rajatbhatta deleted the fix-quote-tests branch July 18, 2022 23:24
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
api: spanner Issues related to the googleapis/java-spanner-jdbc API. size: s Pull request size is small.
Projects
None yet
Development

Successfully merging this pull request may close these issues.

4 participants