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

feat(spanner/spannertest): support Not Null constraint #3491

Merged
merged 6 commits into from Jan 5, 2021

Conversation

sryoya
Copy link
Contributor

@sryoya sryoya commented Dec 25, 2020

About

Fixes #3490

Note

  • This PR doesn't include a test for the newly-added logics because it seems there are no test for unhappy paths in the related functions. Let me know if I need to cover them by test.
  • The "alterColumn" function also should have some checks using Not Null, but, I've not done that in this PR. Assuming how the library users use this library, I suppose the check in writing a record is more prioritized.

@sryoya sryoya requested review from skuruppu and a team as code owners Dec 25, 2020
@google-cla google-cla bot added the cla: yes This human has signed the Contributor License Agreement. label Dec 25, 2020
@product-auto-label product-auto-label bot added the api: spanner Issues related to the Cloud Spanner API. label Dec 25, 2020
@skuruppu skuruppu requested review from dsymonds and removed request for skuruppu Dec 31, 2020
Copy link
Contributor

@dsymonds dsymonds left a comment

Looks good for the most part. A couple of extra bits that should be done in this same change.

No need to worry about a test; I assume you've exercised this with your own code already?

spanner/spannertest/db.go Outdated Show resolved Hide resolved
spanner/spannertest/db.go Show resolved Hide resolved
spanner/spannertest/db.go Outdated Show resolved Hide resolved
@sryoya
Copy link
Contributor Author

sryoya commented Jan 4, 2021

Thank you for the review!

I assume you've exercised this with your own code already?

Sure, I confirmed that inserting null into Not Null column was declined.

@sryoya sryoya requested review from dsymonds and removed request for a team Jan 4, 2021
@dsymonds dsymonds added automerge Merge the pull request once unit tests and other checks pass. kokoro:run Add this label to force Kokoro to re-run the tests. labels Jan 5, 2021
@kokoro-team kokoro-team removed the kokoro:run Add this label to force Kokoro to re-run the tests. label Jan 5, 2021
@dsymonds dsymonds merged commit c36aa07 into googleapis:master Jan 5, 2021
2 checks passed
@sryoya sryoya deleted the add_not_null_constraints branch Jan 5, 2021
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 Cloud Spanner API. automerge Merge the pull request once unit tests and other checks pass. cla: yes This human has signed the Contributor License Agreement.
Projects
None yet
Development

Successfully merging this pull request may close these issues.

spannertest: Support Not Null constraint
3 participants