scylla-rust-driver
scylla-rust-driver copied to clipboard
tests: add integration tests for batch statements
Test cases/ideas are inspired by Java driver batch statements tests.
Pre-review checklist
- [ ] I have split my patch into logically separate commits.
- [ ] All commit messages clearly explain what they change and why.
- [ ] I added relevant tests for new features and bug fixes.
- [ ] All commits compile, pass static checks and pass test.
- [ ] PR description sums up the changes and reasons why they should be introduced.
- [ ] I have provided docstrings for the public items that I want to introduce.
- [ ] I have adjusted the documentation in
./docs/source/. - [ ] I added appropriate
Fixes:annotations to PR description.
cargo semver-checks found no API-breaking changes in this PR! 🎉🥳
Checked commit: fc9def4a1908e16df077d59e08dbf8f8317a565a
I intended to open a PR instead of pushing to your branch directly, sorry @dimakr...
@wprzytula I've made the changes as per the comments above
Turned out that we have a few batch tests in scylla/tests/integration/session.rs test suite.
Moved them to the dedicated batch.rs test suite, for which we are creating new test cases in this PR.
@wprzytula @Lorak-mmk addressed the last comments.
@wprzytula @Lorak-mmk addressed the last comments.
In commit "tests: add integration tests for batch statements" some tests are still marked with #[ignore] instead of disabling tablets. Maybe you forgot to fix that?
In commit "tests: add integration tests for batch statements" some tests are still marked with
#[ignore]instead of disabling tablets. Maybe you forgot to fix that?
@Lorak-mmk the tablets disabling was done as part of "tests: move batch statements tests to batch.rs module" commit. I've adjusted that commit message to clearly mention this.
@Lorak-mmk the tablets disabling was done as part of "tests: move batch statements tests to batch.rs module" commit. I've adjusted that commit message to clearly mention this.
Is there a reason for doing it in the commit that moves tests, instead of doing it that way from the beginning?
Is there a reason for doing it in the commit that moves tests, instead of doing it that way from the beginning?
There was a bit of mess in the series of commits in this PR from the beginning after a commit from another person was accidentally pushed in (that one is squashed eventually). But to avoid further issues I've made 'disable tablets'-change in the subsequent commit.
Two things:
- I don't think you fixed all tests in regards to tablets. In the "Files changed view" I see that
test_cas_batch,test_counter_batch,test_fail_logged_batch_with_counter_increment,test_fail_counter_batch_with_non_counter_incrementinbatch_statement.rsare still ignored. - I see that after this PR we have 2 files: batch.rs and batch_statement.rs. Why? What future tests should go into the latter, and what into the former?
Two things:
It was OK, but due to this number of nit related changes one of recent rebases went wrong. Will correct it
Two things:
It was OK, but due to this number of nit related changes one of recent rebases went wrong. Will correct it
@Lorak-mmk This time should be ok - got rid of batch_statement.rs as per comment https://github.com/scylladb/scylla-rust-driver/pull/1226#discussion_r1951070923